-
Notifications
You must be signed in to change notification settings - Fork 329
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
default fonts get loaded (twice) #1348
Comments
I just pushed a commit that fixes the double issue. (4b580b6)
Isn't this the same question as on #1297?
Can you please elaborate? How do you create them? Do you mean that you have something implemented that writes the compiled CSS to a file and then that file is enqueued? If so, then you don't even need to do that... You can simply add this: add_filter( 'kirki/dynamic_css/method', function() {
return 'file';
}); This will tell kirki to write its styles to a CSS file and then that will be enqueued - including the googlefonts styles, all minimized and ready for production - which also get reset when you save the customizer.
The file does exist, and it's empty. The reason it's enqueued is because all extra styles are added using But if you switch to |
That's exactly what I do. I remember I wasn't as flexible as i wanted to be using kirkis output method. Oh yes, the file does exist - was looking at the wrong folder. I was trying to switch to the file method as suggested above and figured that the new stylesheet that got enqueued (wp-content/uploads/kirki-css/styles.css) is empty too. |
Well... version 3.0 adds a lot more versatility to the output arguments so hopefully you'll be able to use the output arguments if you want, and stylesheets will be auto-created. 'output' => array(
array(
'element' => array(
'#main-navigation',
'#main-navigation a',
'#main-navigation a:hover',
),
'property' => 'background',
'media_query' => '@media (min-width: 600px)'
'value_pattern' => 'linear-gradient(to right, $ 0%,{value2} 100%)',
'pattern_replace' => array(
'{value2}' => 'nav_color1',
),
),
), the |
Perhaps you've disabled css output? |
If you're still having an issue with the stylesheet in |
Since we fixed this one, every time I change a font in the customizer - then go to the front end and hit refresh - no fonts are loaded. I need to refresh the browser one more time to get the google fonts loaded. |
It should be ok now, fixed in 3053069 |
Issue description:
I've specified Roboto as a default font in the customizer. Now, on a fresh installation, not having saved the customizer yet it loads Roboto twice.
Is there a way not to load default fonts if they weren't specified?
I have a bunch of typography fields with roboto as the default font, not sure why they get loaded twice.
Also, I've noticed that the kirky-styles-global-css gets enqueued. In my case I create my own stylesheet from the kirki controls. Also the file CSS file it links to doesn't exist. How can i get rid of it? By just dequeuing it?
Version used:
Latest Dev
The text was updated successfully, but these errors were encountered: