Astra_Customizer_Footer_Small_Spacing_Configs::register_configuration( Array $configurations, WP_Customize_Manager $wp_customize )
Register Footer Spacing 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: addons/spacing/classes/sections/class-astra-customizer-footer-small-spacing-configs.php
public function register_configuration( $configurations, $wp_customize ) {
$_configs = array(
/**
* Option - Footer Space
*/
array(
'name' => ASTRA_THEME_SETTINGS . '[footer-sml-spacing]',
'default' => astra_get_option( 'footer-sml-spacing' ),
'type' => 'control',
'transport' => 'postMessage',
'control' => 'ast-responsive-spacing',
'sanitize_callback' => array( 'Astra_Customizer_Sanitizes', 'sanitize_responsive_spacing' ),
'section' => 'section-footer-small',
'priority' => 90,
'title' => __( 'Footer Space', 'astra-addon' ),
'context' => array(
astra_addon_builder_helper()->general_tab_config,
array(
'setting' => ASTRA_THEME_SETTINGS . '[footer-sml-layout]',
'operator' => '!=',
'value' => 'disabled',
),
),
'linked_choices' => true,
'unit_choices' => array( 'px', 'em', '%' ),
'choices' => array(
'top' => __( 'Top', 'astra-addon' ),
'right' => __( 'Right', 'astra-addon' ),
'bottom' => __( 'Bottom', 'astra-addon' ),
'left' => __( 'Left', 'astra-addon' ),
),
),
/**
* Option - Footer Menu Space
*/
array(
'name' => ASTRA_THEME_SETTINGS . '[footer-menu-spacing]',
'default' => astra_get_option( 'footer-menu-spacing' ),
'type' => 'control',
'transport' => 'postMessage',
'control' => 'ast-responsive-spacing',
'sanitize_callback' => array( 'Astra_Customizer_Sanitizes', 'sanitize_responsive_spacing' ),
'section' => 'section-footer-small',
'priority' => 90,
'title' => __( 'Menu Space', 'astra-addon' ),
'divider' => array( 'ast_class' => 'ast-bottom-divider' ),
'context' => array(
'relation' => 'AND',
astra_addon_builder_helper()->general_tab_config,
array(
'relation' => 'OR',
array(
'setting' => ASTRA_THEME_SETTINGS . '[footer-sml-section-1]',
'operator' => '==',
'value' => 'menu',
),
array(
'setting' => ASTRA_THEME_SETTINGS . '[footer-sml-section-2]',
'operator' => '==',
'value' => 'menu',
),
),
),
'linked_choices' => true,
'unit_choices' => array( 'px', 'em', '%' ),
'choices' => array(
'top' => __( 'Top', 'astra-addon' ),
'right' => __( 'Right', 'astra-addon' ),
'bottom' => __( 'Bottom', 'astra-addon' ),
'left' => __( 'Left', 'astra-addon' ),
),
),
);
return array_merge( $configurations, $_configs );
}
Expand full source code Collapse full source code View on Trac
Changelog
| Version | Description |
|---|---|
| 1.4.3 | Introduced. |