diff --git a/client-mu-plugins/goodbids/src/classes/Frontend/Patterns.php b/client-mu-plugins/goodbids/src/classes/Frontend/Patterns.php index 3b8180201..ab9ad8663 100644 --- a/client-mu-plugins/goodbids/src/classes/Frontend/Patterns.php +++ b/client-mu-plugins/goodbids/src/classes/Frontend/Patterns.php @@ -108,6 +108,17 @@ function (): void { 'inserter' => true, ]; + $nonprofit_navigation = [ + 'name' => 'nonprofit-navigation', + 'path' => goodbids()->get_view_path( 'patterns/nonprofit-navigation.php' ), + 'title' => __( 'Nonprofit Navigation', 'goodbids' ), + 'description' => _x( 'Default Nonprofit Navigation', 'Block pattern description', 'goodbids' ), + 'categories' => [ 'goodbids' ], + 'keywords' => [ 'navigation' ], + 'source' => 'plugin', + 'inserter' => true, + ]; + $section_sidebar_chapters = [ 'name' => 'section-sidebar-chapters', 'path' => goodbids()->get_view_path( 'patterns/section-sidebar-chapters.php' ), @@ -167,6 +178,7 @@ function (): void { $hero_banner, $logo_grid, $nonprofit_interest_form, + $nonprofit_navigation, $section_sidebar_chapters, $template_about, $template_auction, @@ -212,7 +224,7 @@ public function register_pattern( array $pattern ): bool { if ( empty( $pattern['slug'] ) ) { list( $namespace, $slug ) = explode( '/', $name ); - $pattern['slug'] = $slug; + $pattern['slug'] = $slug; } if ( empty( $pattern['categories'] ) ) { diff --git a/client-mu-plugins/goodbids/src/classes/Network/Sites.php b/client-mu-plugins/goodbids/src/classes/Network/Sites.php index 1ecbe2560..378d2a102 100644 --- a/client-mu-plugins/goodbids/src/classes/Network/Sites.php +++ b/client-mu-plugins/goodbids/src/classes/Network/Sites.php @@ -1038,4 +1038,27 @@ private function get_page_path( string $path ): ?WP_Post { return get_page_by_path( $path ); // phpcs:ignore } + + + /** + * Return the nonprofit navigation + * + * @return array + * + * @since 1.0.0 + */ + public function get_nonprofit_navigation(): array { + return [ + [ + 'label' => 'Explore Auctions', + 'ID' => 4, + 'url' => '/explore-auctions', + ], + [ + 'label' => 'About GOODBIDS', + 'ID' => 3, + 'url' => '/about', + ], + ]; + } } diff --git a/client-mu-plugins/goodbids/views/patterns/nonprofit-navigation.php b/client-mu-plugins/goodbids/views/patterns/nonprofit-navigation.php new file mode 100644 index 000000000..ceaf0408e --- /dev/null +++ b/client-mu-plugins/goodbids/views/patterns/nonprofit-navigation.php @@ -0,0 +1,17 @@ +sites->get_nonprofit_navigation(); +?> + + + + + + + diff --git a/themes/goodbids-nonprofit/patterns/header-nonprofit.php b/themes/goodbids-nonprofit/patterns/header-nonprofit.php index 1c07944b3..60cfb564e 100644 --- a/themes/goodbids-nonprofit/patterns/header-nonprofit.php +++ b/themes/goodbids-nonprofit/patterns/header-nonprofit.php @@ -21,13 +21,7 @@
- - - - - - - +