0.cs01,S=3770,W=38680]1770406710.M922765P160386.cs01,S=3777,W=3876x]1770408212.M584306P166895.cs01,S=3946,W=4048]1770408236.M862996P167038.cs01,S=3941,W=4043]1770408777.M57948P169310.cs01,S=3963,W=4066P]1770410371.M659482P176064.cs01,S=3963,W=4066]1770410429.M624345P176422.cs01,S=3958,W=4061]1770410510.M672430P176841.cs01,S=3743,W=3842(]1770410513.M644812P176887.cs01,S=3742,W=3841p]1770410737.M868105P177830.cs01,S=3742,W=3841]1770410740.M879773P177877.cs01,S=3727,W=3825]1770410750.M406669P177940.cs01,S=3734,W=3832H]1770412039.M329626P183123.cs01,S=3774,W=3873]1770412081.M543860P183249.cs01,S=3769,W=3868]1770414544.M494597P194667.cs01,S=3783,W=3882 ]1770414851.M130322P195921.cs01,S=4011,W=4115h]1770414853.M898925P195950.cs01,S=4011,W=4115 ]1770414900.M151039P196123.cs01,S=3735,W=3833!]1770417780.M980946P208933.cs01,S=3998,W=4102"@]1770417815.M101967P209115.cs01,S=3993,W=4097#]1770418956.M565538P215169.cs01,S=3704,W=3802$]1770420794.M323474P223032.cs01,S=3699,W=3797%]1770423217.M609104P230805.cs01,S=3929,W=4031&`]1770423238.M946174P231005.cs01,S=3925,W=4027']1770425427.M606679P242900.cs01,S=3745,W=3844(]1770425641.M967016P243573.cs01,S=3741,W=3840)8]1770435534.M586970P279619.cs01,S=3753,W=3852*]1770435562.M417070P279756.cs01,S=3750,W=3849+]1770437296.M477739P285385.cs01,S=3803,W=3902,]1770437321.M787132P285485.cs01,S=3799,W=3898-X]1770439903.M742211P293158.cs01,S=3767,W=3866.]1770440000.M166978P293425.cs01,S=3757,W=3855/]1770447607.M442603P1101464.cs01,S=3669,W=376700]1770447608.M539994P1101650.cs01,S=3676,W=37741x]1770450754.M710357P1342911.cs01,S=4272,W=43792]1770450807.M957548P1343150.cs01,S=4268,W=43753]1770452760.M560665P1350823.cs01,S=3990,W=40914P]1770452889.M90884P1351311.cs01,S=4001,W=41035]1770465169.M855504P1390493.cs01,S=3675,W=37736]1770467373.M764099P1397035.cs01,S=3953,W=40567(]1770467375.M116083P1397043.cs01,S=3954,W=40578p]1770467594.M877164P1397757.cs01,S=3959,W=40629]1770468757.M681327P1401462.cs01,S=3817,W=3919:]1770468758.M990222P1401496.cs01,S=3817,W=3919;H]1770469251.M38929P1403108.cs01,S=3702,W=3800<]1770469252.M563074P1403117.cs01,S=3703,W=3801=]1770469287.M952328P1403282.cs01,S=3708,W=3806> ]1770471016.M66957P1408715.cs01,S=3759,W=3857?h]1770471146.M601768P1409063.cs01,S=3758,W=3856@]1770471155.M482676P1409147.cs01,S=3812,W=3912A]1770471157.M22099P1409156.cs01,S=3813,W=3913B@]1770471193.M795913P1409356.cs01,S=3818,W=3918C]1770471360.M687537P1409900.cs01,S=3754,W=3852D]1770482450.M199926P1447547.cs01,S=3813,W=3912E]1770482527.M352147P1447930.cs01,S=3813,W=3912F`]1770482546.M129851P1448001.cs01,S=3809,W=3908G]1770491144.M701989P1482625.cs01,S=3750,W=3848H]1770491180.M7394ic' => __( '900 Italic', 'inspiro' ), ); } return apply_filters( 'inspiro/font-weight', self::$font_weight ); } /** * Get font weight for selected Font Family passed by setting key * * @param string $setting_key The setting key name for Font Family control. * @param WP_Customize_Manager $wp_customize instance of WP_Customize_Manager. * @return array */ public static function get_font_family_weight( $setting_key, $wp_customize ) { $font_family_weight = array( '' => __( 'Inherit', 'inspiro' ), ); if ( ! is_object( $wp_customize->get_setting( $setting_key ) ) ) { return $font_family_weight; } $default = $wp_customize->get_setting( $setting_key )->default; $select_font_family = get_theme_mod( $setting_key, $default ); $font_family = self::clean_google_fonts( $select_font_family ); $all_font_weight = self::get_all_font_weight(); if ( isset( self::$google_fonts[ $font_family ][0] ) && is_array( self::$google_fonts[ $font_family ][0] ) ) { foreach ( self::$google_fonts[ $font_family ][0] as $font_weight ) { // Skip font variants (italic, i). if ( strpos( $font_weight, 'italic' ) === false || strpos( $font_weight, 'i' ) === false ) { $font_family_weight[ $font_weight ] = $all_font_weight[ $font_weight ]; } } } return $font_family_weight; } /** * Get font presets * * @return array Array of all font presets for Inspiro theme */ public static function get_font_presets() { if ( empty( self::$font_presets ) ) { self::$font_presets = array( array( 'name' => 'Default', 'image' => 'system.png', 'mods' => array( 'body-font-family' => '', 'body-font-size' => '16', 'body-font-weight' => '400', 'body-text-transform' => '', 'body-line-height' => '1.8', // TODO: add all settings here. ), ), ); // TODO: add font presets. } return apply_filters( 'inspiro/font-presets', self::$font_presets ); } /** * Clean font name. * * Google Fonts are saved as {'Font Name', Category}. This function cleanes this up to retreive only the {Font Name}. * * @since 1.3.0 * @param string $font_value Name of the font. * * @return string Font name where commas and inverted commas are removed if the font is a Google Font. */ public static function clean_google_fonts( $font_value ) { // Bail if fontVAlue does not contain a comma. if ( strpos( $font_value, ',' ) === false ) { return $font_value; } $split_font = explode( ',', $font_value ); $google_font_value = str_replace( "'", '', $split_font[0] ); // Check if the cleaned font exists in the Google fonts array. $google_fonts = self::get_google_fonts(); if ( isset( $google_fonts[ $google_font_value ] ) ) { $font_value = $google_font_value; } return $font_value; } } }