Custom Fonts - Version 1.3.1

Version Description

  • Fix: Font not rendered properly when multiple font format files are added for a single font.
Download this release

Release Info

Developer brainstormworg
Plugin Icon 128x128 Custom Fonts
Version 1.3.1
Comparing to
See all releases

Code changes from version 1.3.0 to 1.3.1

classes/class-bsf-custom-fonts-render.php CHANGED
@@ -356,9 +356,13 @@ if ( ! class_exists( 'Bsf_Custom_Fonts_Render' ) ) :
356
  $font_face_css .= 'font-display: ' . self::$font_display . ';';
357
  $font_face_css .= 'font-fallback: ' . self::$font_fallback . ';';
358
  $font_face_css .= 'font-weight: ' . $key . ';';
 
359
  foreach ( $value as $font_file ) {
360
- $font_face_css .= 'src: ' . $font_file . '; ';
361
  }
 
 
 
362
  $font_face_css .= '} ';
363
  }
364
  $this->font_css .= $font_face_css;
356
  $font_face_css .= 'font-display: ' . self::$font_display . ';';
357
  $font_face_css .= 'font-fallback: ' . self::$font_fallback . ';';
358
  $font_face_css .= 'font-weight: ' . $key . ';';
359
+ $font_src_array = array();
360
  foreach ( $value as $font_file ) {
361
+ array_push( $font_src_array, $font_file );
362
  }
363
+
364
+ $font_face_css .= 'src: ' . implode( ', ', $font_src_array ) . ';';
365
+
366
  $font_face_css .= '} ';
367
  }
368
  $this->font_css .= $font_face_css;
custom-fonts.php CHANGED
@@ -6,7 +6,7 @@
6
  * Author: Brainstorm Force
7
  * Author URI: http://www.brainstormforce.com
8
  * Text Domain: custom-fonts
9
- * Version: 1.3.0
10
  *
11
  * @package Bsf_Custom_Fonts
12
  */
@@ -25,7 +25,7 @@ define( 'BSF_CUSTOM_FONTS_FILE', __FILE__ );
25
  define( 'BSF_CUSTOM_FONTS_BASE', plugin_basename( BSF_CUSTOM_FONTS_FILE ) );
26
  define( 'BSF_CUSTOM_FONTS_DIR', plugin_dir_path( BSF_CUSTOM_FONTS_FILE ) );
27
  define( 'BSF_CUSTOM_FONTS_URI', plugins_url( '/', BSF_CUSTOM_FONTS_FILE ) );
28
- define( 'BSF_CUSTOM_FONTS_VER', '1.3.0' );
29
 
30
  /**
31
  * BSF Custom Fonts
6
  * Author: Brainstorm Force
7
  * Author URI: http://www.brainstormforce.com
8
  * Text Domain: custom-fonts
9
+ * Version: 1.3.1
10
  *
11
  * @package Bsf_Custom_Fonts
12
  */
25
  define( 'BSF_CUSTOM_FONTS_BASE', plugin_basename( BSF_CUSTOM_FONTS_FILE ) );
26
  define( 'BSF_CUSTOM_FONTS_DIR', plugin_dir_path( BSF_CUSTOM_FONTS_FILE ) );
27
  define( 'BSF_CUSTOM_FONTS_URI', plugins_url( '/', BSF_CUSTOM_FONTS_FILE ) );
28
+ define( 'BSF_CUSTOM_FONTS_VER', '1.3.1' );
29
 
30
  /**
31
  * BSF Custom Fonts
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.me/BrainstormForce
4
  Tags: Beaver Builder, Elementor, Astra, woff2, woff, ttf, svg, eot, otf, Custom Fonts, Font, Typography
5
  Requires at least: 4.4
6
  Tested up to: 5.7
7
- Stable tag: 1.3.0
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -43,6 +43,9 @@ If you're not using any of the supported plugins and theme, you can write the cu
43
 
44
  == Changelog ==
45
 
 
 
 
46
  = 1.3.0 =
47
  - New: Add multiple font weight to the Custom Fonts.
48
 
4
  Tags: Beaver Builder, Elementor, Astra, woff2, woff, ttf, svg, eot, otf, Custom Fonts, Font, Typography
5
  Requires at least: 4.4
6
  Tested up to: 5.7
7
+ Stable tag: 1.3.1
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
43
 
44
  == Changelog ==
45
 
46
+ = 1.3.1 =
47
+ - Fix: Font not rendered properly when multiple font format files are added for a single font.
48
+
49
  = 1.3.0 =
50
  - New: Add multiple font weight to the Custom Fonts.
51