array( "{$prefix}section" => array( 'title' => Translations::get( 'title' ), 'panel' => 'footer_panel', 'type' => 'colibri_section', 'hidden' => true, ), ), 'settings' => array( "{$prefix}pen" => array( 'control' => array( 'type' => 'pen', 'section' => 'footer', ), ), "{$prefix}props.useFooterParallax" => array( 'default' => Defaults::get( "{$prefix}props.useFooterParallax" ), 'transport' => 'refresh', 'control' => array( 'focus_alias' => 'footer', 'label' => Translations::get( 'footer_parallax' ), 'type' => 'switch', 'show_toggle' => true, 'section' => 'footer', 'colibri_tab' => 'content', ), 'js_output' => array( array( 'selector' => '.page-footer', 'action' => 'colibri-set-attr', 'value' => 'data-enabled', ), array( 'selector' => '.page-footer', 'action' => 'colibri-component-toggle', 'value' => 'footerParallax', 'delay' => 30, ), ), ), ), ); } public function printParalaxJsToggle() { $prefix = static::$settings_prefix; $parallax = $this->mod( "{$prefix}props.useFooterParallax", false ); if ( $parallax === false || $parallax === '' ) { AssetsManager::addInlineScriptCallback( 'kubio-theme', function () { ?> $this, ) ); } }