diff --git a/assets/css/src/blocks/_navigation.scss b/assets/css/src/blocks/_navigation.scss index 9155a05..4b1821f 100644 --- a/assets/css/src/blocks/_navigation.scss +++ b/assets/css/src/blocks/_navigation.scss @@ -24,4 +24,35 @@ .wp-block-navigation__submenu-container { gap: 24px !important; } + + .wp-block-navigation__responsive-container-content { + + .wp-block-navigation-item { + display: flex; + justify-content: space-between; + flex-direction: row; + flex-wrap: wrap; + align-items: center; + padding: 0 24px; + width: 100vw; + box-sizing: border-box; + + .wp-block-navigation__submenu-container { + display: none; + } + + .wp-block-navigation__submenu-icon { + display: inline-block; + cursor: pointer; + } + + &.is-submenu-open > .wp-block-navigation__submenu-container { + display: block; + width: 100%; + padding: 0; + padding-top: var(--wp--style--block-gap, 2em); + } + } + } + } diff --git a/assets/js/src/script.js b/assets/js/src/script.js new file mode 100644 index 0000000..5acf5a6 --- /dev/null +++ b/assets/js/src/script.js @@ -0,0 +1,7 @@ +/* global jQuery */ + +jQuery( document ).ready( ( $ ) => { + $( '.wp-block-navigation-submenu__toggle' ).on( 'click', function () { + $( this ).parent( 'li' ).toggleClass( 'is-submenu-open' ); + } ); +} ); diff --git a/composer.lock b/composer.lock index 41a938d..129a6b0 100644 --- a/composer.lock +++ b/composer.lock @@ -8,21 +8,21 @@ "packages": [ { "name": "codeinwp/themeisle-sdk", - "version": "3.3.48", + "version": "3.3.51", "source": { "type": "git", "url": "https://github.com/Codeinwp/themeisle-sdk.git", - "reference": "0727d2cf2fc9bfb81b42968aeaf2bf4e340f021e" + "reference": "bb2a8414b0418b18c68c9ff1df3d7fb10467928d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Codeinwp/themeisle-sdk/zipball/0727d2cf2fc9bfb81b42968aeaf2bf4e340f021e", - "reference": "0727d2cf2fc9bfb81b42968aeaf2bf4e340f021e", + "url": "https://api.github.com/repos/Codeinwp/themeisle-sdk/zipball/bb2a8414b0418b18c68c9ff1df3d7fb10467928d", + "reference": "bb2a8414b0418b18c68c9ff1df3d7fb10467928d", "shasum": "" }, "require-dev": { "codeinwp/phpcs-ruleset": "dev-main", - "yoast/phpunit-polyfills": "^2.0" + "yoast/phpunit-polyfills": "^4.0" }, "type": "library", "notification-url": "https://packagist.org/downloads/", @@ -36,16 +36,16 @@ "homepage": "https://themeisle.com" } ], - "description": "ThemeIsle SDK", + "description": "Themeisle SDK.", "homepage": "https://github.com/Codeinwp/themeisle-sdk", "keywords": [ "wordpress" ], "support": { "issues": "https://github.com/Codeinwp/themeisle-sdk/issues", - "source": "https://github.com/Codeinwp/themeisle-sdk/tree/v3.3.48" + "source": "https://github.com/Codeinwp/themeisle-sdk/tree/v3.3.51" }, - "time": "2025-08-11T16:47:24+00:00" + "time": "2026-03-30T07:58:49+00:00" } ], "packages-dev": [ @@ -2418,5 +2418,5 @@ "platform-overrides": { "php": "7.0" }, - "plugin-api-version": "2.6.0" + "plugin-api-version": "2.9.0" } diff --git a/inc/Assets_Manager.php b/inc/Assets_Manager.php index 77542ec..bda65cc 100644 --- a/inc/Assets_Manager.php +++ b/inc/Assets_Manager.php @@ -20,6 +20,7 @@ class Assets_Manager { 'editor-css' => 'riverbank-editor', 'welcome-notice' => 'riverbank-welcome-notice', 'design-pack-notice' => 'riverbank-design-pack-notice', + 'frontend-js' => 'riverbank-script', ); /** diff --git a/inc/Core.php b/inc/Core.php index 7dc0c36..4a2328d 100644 --- a/inc/Core.php +++ b/inc/Core.php @@ -97,6 +97,7 @@ public function setup() { */ public function enqueue() { Assets_Manager::enqueue_style( Assets_Manager::ASSETS_SLUGS['frontend-css'], 'style' ); + Assets_Manager::enqueue_script( Assets_Manager::ASSETS_SLUGS['frontend-js'], 'script', true, array( 'jquery' ) ); } /**