field = new Kirki_Field(); $kirki->font_registry = new Kirki_Fonts_Font_Registry(); $kirki->scripts = new Kirki_Scripts_Registry(); $kirki->settings = new Kirki_Settings(); $kirki->api = new Kirki(); $kirki->back_styles = new Kirki_Styles_Customizer(); $kirki->front_styles = new Kirki_Styles_Frontend(); return $kirki; } global $kirki; $kirki = Kirki(); if ( defined( 'KIRKI_REDUX_COMPATIBILITY' ) && KIRKI_REDUX_COMPATIBILITY ) { include_once( KIRKI_PATH . '/includes/redux-compatibility.php' ); } /** * Load plugin textdomain. * * @since 0.8.0 */ function kirki_load_textdomain() { $textdomain = 'kirki'; // Look for WP_LANG_DIR/{$domain}-{$locale}.mo if ( file_exists( WP_LANG_DIR . '/' . $textdomain . '-' . get_locale() . '.mo' ) ) { $file = WP_LANG_DIR . '/' . $textdomain . '-' . get_locale() . '.mo'; } // Look for KIRKI_PATH/languages/{$domain}-{$locale}.mo if ( ! isset( $file ) && file_exists( KIRKI_PATH . '/languages/' . $textdomain . '-' . get_locale() . '.mo' ) ) { $file = KIRKI_PATH . '/languages/' . $textdomain . '-' . get_locale() . '.mo'; } if ( isset( $file ) ) { load_textdomain( $textdomain, $file ); } load_plugin_textdomain( $textdomain, false, KIRKI_PATH . '/languages' ); } add_action( 'plugins_loaded', 'kirki_load_textdomain' ); // Add an empty config for global fields Kirki::add_config( '' );