get_all(); $root = ( '' != $config['url_path'] ) ? $config['url_path'] : KIRKI_URL; wp_enqueue_style( 'kirki-customizer-css', trailingslashit( $root ) . 'assets/css/customizer.css', NULL, '0.5' ); } /** * Add custom CSS rules to the head, applying our custom styles */ function custom_css() { $color = $this->get_admin_colors(); $config = Kirki::config(); $color_font = false; $color_accent = $config->get( 'color_accent', $color['icon_colors']['focus']); $color_back = $config->get( 'color_back', '#ffffff' ); $color_font = ( 170 > \Kirki_Color::get_brightness( $color_back ) ) ? '#f2f2f2' : '#222'; $styles = ''; echo $styles; } /** * Get the admin color theme */ function get_admin_colors() { // Get the active admin theme global $_wp_admin_css_colors; // Get the user's admin colors $color = get_user_option( 'admin_color' ); // If no theme is active set it to 'fresh' if ( empty( $color ) || ! isset( $_wp_admin_css_colors[$color] ) ) { $color = 'fresh'; } $color = (array) $_wp_admin_css_colors[$color]; return $color; } }