Astra_Breadcrumbs_Typo_Configs::register_configuration( Array $configurations, WP_Customize_Manager $wp_customize )
Register Colors and Background – Breadcrumbs Options Customizer Configurations.
Description
Parameters
- $configurations
-
(Array) (Required) Astra Customizer Configurations.
- $wp_customize
-
(WP_Customize_Manager) (Required) instance of WP_Customize_Manager.
Return
(Array) Astra Customizer Configurations with updated configurations.
Source
File: inc/addons/breadcrumbs/customizer/class-astra-breadcrumbs-typo-configs.php
public function register_configuration( $configurations, $wp_customize ) {
$_configs = array(
/*
* Breadcrumb Typography
*/
array(
'name' => ASTRA_THEME_SETTINGS . '[section-breadcrumb-typo]',
'default' => astra_get_option( 'section-breadcrumb-typo' ),
'type' => 'control',
'control' => 'ast-settings-group',
'title' => __( 'Content Font', 'astra' ),
'section' => 'section-breadcrumb',
'transport' => 'postMessage',
'priority' => 73,
'context' => array(
array(
'setting' => ASTRA_THEME_SETTINGS . '[breadcrumb-position]',
'operator' => '!=',
'value' => 'none',
),
( true === Astra_Builder_Helper::$is_header_footer_builder_active ) ?
Astra_Builder_Helper::$design_tab_config : Astra_Builder_Helper::$general_tab_config,
),
'divider' => array( 'ast_class' => 'ast-bottom-divider' ),
),
/**
* Option: Font Family
*/
array(
'name' => 'breadcrumb-font-family',
'default' => astra_get_option( 'breadcrumb-font-family' ),
'type' => 'sub-control',
'parent' => ASTRA_THEME_SETTINGS . '[section-breadcrumb-typo]',
'section' => 'section-breadcrumb',
'control' => 'ast-font',
'font_type' => 'ast-font-family',
'title' => __( 'Family', 'astra' ),
'connect' => 'breadcrumb-font-weight',
'priority' => 5,
),
/**
* Option: Font Size
*/
array(
'name' => 'breadcrumb-font-size',
'control' => 'ast-responsive',
'type' => 'sub-control',
'parent' => ASTRA_THEME_SETTINGS . '[section-breadcrumb-typo]',
'section' => 'section-breadcrumb',
'default' => astra_get_option( 'breadcrumb-font-size' ),
'transport' => 'postMessage',
'title' => __( 'Size', 'astra' ),
'priority' => 10,
'input_attrs' => array(
'min' => 0,
),
'units' => array(
'px' => 'px',
'em' => 'em',
),
),
/**
* Option: Font Weight
*/
array(
'name' => 'breadcrumb-font-weight',
'control' => 'ast-font',
'type' => 'sub-control',
'parent' => ASTRA_THEME_SETTINGS . '[section-breadcrumb-typo]',
'section' => 'section-breadcrumb',
'font_type' => 'ast-font-weight',
'sanitize_callback' => array( 'Astra_Customizer_Sanitizes', 'sanitize_font_weight' ),
'default' => astra_get_option( 'breadcrumb-font-weight' ),
'title' => __( 'Weight', 'astra' ),
'connect' => 'breadcrumb-font-family',
'priority' => 15,
),
/**
* Option: Text Transform
*/
array(
'name' => 'breadcrumb-text-transform',
'control' => 'ast-select',
'type' => 'sub-control',
'parent' => ASTRA_THEME_SETTINGS . '[section-breadcrumb-typo]',
'section' => 'section-breadcrumb',
'default' => astra_get_option( 'breadcrumb-text-transform' ),
'title' => __( 'Text Transform', 'astra' ),
'transport' => 'postMessage',
'priority' => 20,
'choices' => array(
'' => __( 'Inherit', 'astra' ),
'none' => __( 'None', 'astra' ),
'capitalize' => __( 'Capitalize', 'astra' ),
'uppercase' => __( 'Uppercase', 'astra' ),
'lowercase' => __( 'Lowercase', 'astra' ),
),
),
/**
* Option: Line Height
*/
array(
'name' => 'breadcrumb-line-height',
'control' => 'ast-slider',
'transport' => 'postMessage',
'type' => 'sub-control',
'default' => astra_get_option( 'breadcrumb-line-height' ),
'parent' => ASTRA_THEME_SETTINGS . '[section-breadcrumb-typo]',
'section' => 'section-breadcrumb',
'sanitize_callback' => array( 'Astra_Customizer_Sanitizes', 'sanitize_number_n_blank' ),
'title' => __( 'Line Height', 'astra' ),
'suffix' => 'em',
'priority' => 25,
'input_attrs' => array(
'min' => 1,
'step' => 0.01,
'max' => 5,
),
),
);
return array_merge( $configurations, $_configs );
}
Expand full source code Collapse full source code View on Trac
Changelog
| Version | Description |
|---|---|
| 1.7.0 | Introduced. |