Skip to content
This repository has been archived by the owner on Mar 13, 2024. It is now read-only.

Fix WP 5.9 stylesheet name collision #166

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion gulp/tasks/styles.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ transforms.push(postcssBanner({ banner: `
Theme Name: Benenson
Theme URI: https://benenson.co
Description: Named after the founder of the human rights group, Amnesty International, Benenson is an open-source WordPress theme built using Gutenberg
Version: 1.1.0
Version: 1.1.1
Requires at least: WordPress 4.9.8
Author: Big Bite Creative
Author URI: https://bigbitecreative.com
Expand Down
16 changes: 8 additions & 8 deletions includes/scripts-and-styles.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ function array_reverse_polyfill() {
return;
}

wp_enqueue_script( 'benenson-array-reverse', get_theme_file_uri( '/array-reverse-polyfill.js' ), [], '1.1.0', false );
wp_enqueue_script( 'benenson-array-reverse', get_theme_file_uri( '/array-reverse-polyfill.js' ), [], '1.1.1', false );
}

add_action( 'admin_enqueue_scripts', 'array_reverse_polyfill' );
Expand All @@ -50,11 +50,11 @@ function array_reverse_polyfill() {
*/
if ( ! function_exists( 'benenson_styles' ) ) {
function benenson_styles() {
wp_enqueue_style( 'global-styles', get_theme_file_uri( '/style.css' ), [], '1.1.0', 'all' );
wp_enqueue_style( 'google-fonts', 'https://fonts.googleapis.com/css?family=Lato:300,400,700|Playfair+Display:400,600,700,700i,900,900i', [], '1.1.0' );
wp_enqueue_style( 'theme-styles', get_theme_file_uri( '/style.css' ), [], '1.1.1', 'all' );
wp_enqueue_style( 'google-fonts', 'https://fonts.googleapis.com/css?family=Lato:300,400,700|Playfair+Display:400,600,700,700i,900,900i', [], '1.1.1' );

if ( is_singular( 'post' ) || ! is_page_template( 'templates/without-sidebar' ) ) {
wp_enqueue_style( 'print-styles', get_theme_file_uri( '/print.css' ), [], '1.1.0', 'print' );
wp_enqueue_style( 'print-styles', get_theme_file_uri( '/print.css' ), [], '1.1.1', 'print' );
}
}
}
Expand All @@ -63,7 +63,7 @@ function benenson_styles() {

if ( ! function_exists( 'benenson_editor_styles' ) ) {
function benenson_editor_styles() {
wp_enqueue_style( 'benenson-blocks-css', get_theme_file_uri( '/style-editor.css' ), [], '1.1.0', 'all' );
wp_enqueue_style( 'benenson-blocks-css', get_theme_file_uri( '/style-editor.css' ), [], '1.1.1', 'all' );
}
}

Expand All @@ -78,7 +78,7 @@ function benenson_editor_styles() {
*/
if ( ! function_exists( 'benenson_scripts' ) ) {
function benenson_scripts() {
wp_enqueue_script( 'global-scripts', get_theme_file_uri( '/bundle.js' ), [], '1.1.0', true );
wp_enqueue_script( 'global-scripts', get_theme_file_uri( '/bundle.js' ), [], '1.1.1', true );

if ( is_singular() && comments_open() && get_option( 'thread_comments' ) && true === apply_filters( 'benenson_comments_enabled', false ) ) {
wp_enqueue_script( 'comment-reply' );
Expand Down Expand Up @@ -111,11 +111,11 @@ function benenson_gutenberg_assets() {
'wp-edit-post',
'wp-data',
'wp-date',
], '1.1.0', false );
], '1.1.1', false );

wp_enqueue_script( 'benenson-blocks-js', get_theme_file_uri( '/blocks.js' ), [
'benenson-packages-js',
], '1.1.0', false );
], '1.1.1', false );

if ( function_exists( 'gutenberg_get_jed_locale_data' ) ) {
// gutenberg plugin
Expand Down