is there a way to do this?
because i uploaded a Cormorant Infant Font – but Enfold set it for only sans serif fonts ( Helvetica, Arial, sans-serif)
do i have to go manually over my quick css by:
body.open-sans {
font-family:'open-sans',Helvetica,Arial,sans-serif;
}
h1, h2, h3, h4, h5, h6,
#top .title_container .main-title,
#top .portfolio-title,
.callout .content-area,
.avia-big-box .avia-innerbox,
.av-special-font,
.av-current-sort-title,
.html_elegant-blog #top .minor-meta,
tr.pricing-row td,
#av-burger-menu-ul li {
font-family:'cormorant-infant',Times New Roman, Georgia, serif;
}
Hey Guenter,
Thank you for the inquiry.
You can use the avf_fallback_fonts_array filter to define your own fallback fonts, defaults to 'Helvetica', 'Arial', 'sans-serif'
.
add_filter('avf_fallback_fonts_array', function($fallback, $selected_font_family) {
$default_font = avia_get_option( 'default_font' );
$google_font = avia_get_option( 'google_webfont' );
return array(
'Helvetica',
'Arial',
'sans-serif'
);
}, 10, 2);
Defined on enfold/framework/php/class-style-generator.php file.
Best regards,
Ismael
Thats cool – but how to differ if i had for headings a serif font and for body a sans-serif?
Hi!’
You can create a few conditions based on the $selected_font_family, $google_font (‘Heading Font’) and $default_font (‘Body Font’).
Example:
$stroke = $google_font == 'Open Sans' ? 'sans-serif' : 'serif';
return array(
'Helvetica',
'Arial',
$stroke
);
Regards,
Ismael
yes – can be closed -thanks