<?php

/**
 * elevate-construction: Block Patterns
 *
 * @since elevate-construction 1.0.0
 */

/**
 * Registers pattern categories for elevate-construction
 *
 * @since elevate-construction 1.0.0
 *
 * @return void
 */
function elevate_construction_register_pattern_category() {
	$block_pattern_categories = array(
		'elevate-construction'                => array( 'label' => __( 'elevate-construction Extra', 'elevate-construction' ) ),
		'elevate-construction-header'         => array( 'label' => __( 'Header Layout', 'elevate-construction' ) ),
		'elevate-construction-footer'         => array( 'label' => __( 'Footer Layout', 'elevate-construction' ) ),
		'elevate-construction-about-us'       => array( 'label' => __( 'About Us', 'elevate-construction' ) ),
		'elevate-construction-hero'           => array( 'label' => __( 'Hero Section', 'elevate-construction' ) ),
		'elevate-construction-how-we-work'    => array( 'label' => __( 'How We Work', 'elevate-construction' ) ),
		'elevate-construction-services'       => array( 'label' => __( 'Services', 'elevate-construction' ) ),
		'elevate-construction-testimonial'    => array( 'label' => __( 'Testimonials & Reviews', 'elevate-construction' ) ),
		'elevate-construction-faqs'           => array( 'label' => __( 'FAQS', 'elevate-construction' ) ),
		'elevate-construction-post'           => array( 'label' => __( 'Posts / Blog', 'elevate-construction' ) ),
		'elevate-construction-cta'            => array( 'label' => __( 'CTA: Call To Action', 'elevate-construction' ) ),
		'elevate-construction-brand-showcase' => array( 'label' => __( 'Logo Showcase', 'elevate-construction' ) ),
	);

	$block_pattern_categories = apply_filters( 'elevate_construction_block_pattern_categories', $block_pattern_categories );

	foreach ( $block_pattern_categories as $name => $properties ) {
		if ( ! WP_Block_Pattern_Categories_Registry::get_instance()->is_registered( $name ) ) {
			register_block_pattern_category( $name, $properties ); // phpcs:ignore WPThemeReview.PluginTerritory.ForbiddenFunctions.editor_blocks_register_block_pattern_category
		}
	}
}
add_action( 'init', 'elevate_construction_register_pattern_category', 9 );
