label . ' ' . esc_html__( 'Archive', 'elementor-pro' ); $post_type_taxonomies = get_object_taxonomies( $post_type, 'objects' ); $post_type_taxonomies = wp_filter_object_list( $post_type_taxonomies, [ 'public' => true, 'show_in_nav_menus' => true, ] ); foreach ( $post_type_taxonomies as $slug => $object ) { $taxonomies[ 'taxonomy/' . $slug ] = $object->label . ' ' . esc_html__( 'Archive', 'elementor-pro' ); } $options = [ 'search' => esc_html__( 'Search Results', 'elementor-pro' ), ]; $options += $taxonomies + $post_type_archives; return [ 'archive' => [ 'label' => esc_html__( 'Archive', 'elementor-pro' ), 'options' => $options, ], ]; } protected static function get_editor_panel_categories() { $categories = [ 'docs-archive' => [ 'title' => __('Docs Archive', 'betterdocs'), ], ]; $categories += parent::get_editor_panel_categories(); unset($categories['theme-elements-archive']); return $categories; } public static function get_editor_panel_config() { $config = parent::get_editor_panel_config(); $config['widgets_settings']['theme-archive-title']['categories'][] = 'docs-archive'; return $config; } protected function register_controls() { parent::register_controls(); $this->update_control( 'preview_type', [ 'default' => 'post_type_archive/docs', ] ); } protected function get_remote_library_config() { $config = parent::get_remote_library_config(); $config['category'] = 'Docs Archive'; return $config; } }