Add option to change the 'All items in repository' title.

This commit is contained in:
mateuswetah 2024-05-17 17:10:48 -03:00
parent 89af5eaced
commit 16223f4ee5
2 changed files with 9 additions and 1 deletions

View File

@ -83,6 +83,14 @@ $options = [
'h6' => 'H6',
]
)
],
'repository_items_title' => [
'label' => __( 'Repository items page title', 'tainacan-blocksy' ),
'type' => 'text',
'value' => __( 'All items in repository', 'tainacan' ),
'sync' => [
'id' => $prefix . 'hero_elements_heading_tag',
]
]
],

View File

@ -62,7 +62,7 @@ $hero_elements = get_theme_mod(
$elements = [];
foreach ($hero_elements as $index => $single_hero_element) {
if ( isset($single_hero_element['id']) && $single_hero_element['id'] == 'custom_title' && $single_hero_element['enabled']) {
$title = wp_strip_all_tags(get_the_archive_title());
$title = wp_strip_all_tags(blocksy_akg('repository_items_title', $single_hero_element, __( 'All items in repository', 'tainacan' )));
if (! empty($title)) {
$title = blocksy_html_tag(