Tribe__Customizer::get_styles_scripts()
Builds and returns the Customizer CSS template contents.
The method DOES NOT check if the current context is the one where the Customizer template should be printed or not; that care is left to the code calling this method.
Return
(string) The CSS template contents.
Source
File: src/Tribe/Customizer.php
public function get_styles_scripts() { /** * Use this filter to add more CSS, using Underscore Template style. * * @since 4.4 * * @param string $template The Customizer template. * * @link http://underscorejs.org/#template */ $css_template = trim( apply_filters( 'tribe_customizer_css_template', '' ) ); // If we don't have anything on the Customizer, then don't print empty styles. if ( empty( $css_template ) ) { return ''; } // Prepare the customizer scripts. $result = '<script type="text/css" id="' . esc_attr( 'tmpl-' . $this->ID . '_css' ) . '">'; $result .= $css_template; $result .= '</script>'; // Prepare the customizer styles. $result .= '<style type="text/css" id="' . esc_attr( $this->ID . '_css' ) . '">'; $result .= $this->parse_css_template( $css_template ); $result .= '</style>'; return $result; }
Changelog
Version | Description |
---|---|
4.12.6 | Introduced. |