Skip to content

Commit bc1e85d

Browse files
author
Johnnie Gomez Alzaga
committed
Update brand-body-scripts.js
Added effect to resize subnav's background.
1 parent 299b2b5 commit bc1e85d

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

global-brand-code/brand-body-scripts.js

+5-5
Original file line numberDiff line numberDiff line change
@@ -139,19 +139,19 @@ $(document).ready(function () {
139139
};
140140
});
141141

142-
// Global nav - Experiment. Changes subnav height and width in a very flowy way
142+
// Global nav - Changes subnav height and width in a very flowy way
143143
$(document).ready(function () {
144-
$('[class$="g-nav_menu-dropdown_toggle"]').on('click', function () {
144+
$('.brand-boilerplate-components--g-nav_menu-dropdown_toggle').on('click', function () {
145145

146-
const containerElement = $(this).next().find('[class$="g-nav_menu_container"]');
146+
const containerElement = $(this).next().find('.brand-boilerplate-components--g-nav_menu_container');
147147

148148
setTimeout(function () {
149149

150150
const containerWidth = containerElement.outerWidth();
151-
$('[class$="g-nav_menu-container-bg"]').width(containerWidth);
151+
$('.brand-boilerplate-components--g-nav_menu-container-bg').width(containerWidth);
152152

153153
const containerHeight = containerElement.outerHeight();
154-
$('[class$="g-nav_menu-container-bg"]').height(containerHeight);
154+
$('.brand-boilerplate-components--g-nav_menu-container-bg').height(containerHeight);
155155

156156
}, 50);
157157
});

0 commit comments

Comments
 (0)