Skip to content

Fix: Update minified stellarnav script for navbar redirection#2617

Open
sm-28601 wants to merge 2 commits intomeshery:masterfrom
sm-28601:fix-stellarnav-min
Open

Fix: Update minified stellarnav script for navbar redirection#2617
sm-28601 wants to merge 2 commits intomeshery:masterfrom
sm-28601:fix-stellarnav-min

Conversation

@sm-28601
Copy link
Contributor

Description

This PR acts as a follow-up to #2613.

While the previous PR successfully fixed the desktop navbar redirection issue in the source js/stellarnav.js file, the production site (meshery.io) serves the minified version (js/stellarnav.min.js). This resulted in the fix working in the Netlify preview but not reflecting on the live site.

Why this happened:
During debugging, I noticed the live site's Network tab loads stellarnav.min.js, whereas local development uses the raw stellarnav.js file. This PR syncs the exact same conditional logic from PR #2613 into the h(e) function within stellarnav.min.js so the fix can take effect in production.

Untitled design

Notes for Reviewers

  • Verified that stellarnav.min.js executes the correct conditional bypass for desktop sub-list links.
  • Confirmed mobile dropdown functionality remains untouched.

Signed commits

  • Yes, I signed my commits.

Signed-off-by: Sahil Maurya <sahilmaurya5611@gmail.com>
Copilot AI review requested due to automatic review settings February 26, 2026 19:34
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@netlify
Copy link

netlify bot commented Feb 26, 2026

Deploy Preview for mesheryio-preview ready!

Name Link
🔨 Latest commit 02b819d
🔍 Latest deploy log https://app.netlify.com/projects/mesheryio-preview/deploys/69a1183e21868f0008ff5cf5
😎 Deploy Preview https://deploy-preview-2617--mesheryio-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @sm-28601, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request addresses a production issue where a previously implemented fix for desktop navbar redirection was not active on the live site. The core change involves updating the minified JavaScript file, js/stellarnav.min.js, to include the necessary conditional logic, ensuring that desktop sub-list links redirect correctly without triggering dropdown toggles, while preserving mobile navigation functionality.

Highlights

  • Production Fix for Navbar Redirection: The fix for desktop navbar redirection, previously applied only to the source js/stellarnav.js, has now been propagated to the minified js/stellarnav.min.js to ensure it takes effect on the production site.
  • Conditional Logic Implementation: The h(e) function in stellarnav.min.js was updated with conditional logic to prevent sub-list toggling on desktop, allowing direct navigation for sub-list links.
Changelog
  • js/stellarnav.min.js
    • Implemented conditional logic within the h(e) function to prevent sub-list toggling on desktop, resolving a navbar redirection issue.
Activity
  • The pull request was created by sm-28601 to address a production issue identified after a previous fix.
  • The author has verified the fix in the minified script and confirmed mobile functionality is unaffected.
  • The author has signed their commits.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request addresses a navbar redirection bug by updating the minified stellarnav.min.js file. The fix itself seems correct, however, modifying minified files directly is a significant maintainability risk. My review comment highlights this process issue, as any future minification from the source file will overwrite this fix and reintroduce the bug. It is strongly recommended to implement a build process that generates minified files from their sources.

@@ -1 +1 @@
!function(i){i.fn.stellarNav=function(e,s,n){nav=i(this),s=i(window).width();var t=i.extend({theme:"plain",breakpoint:768,menuLabel:"",sticky:!1,position:"static",openingSpeed:80,closingDelay:80,showArrows:!0,phoneBtn:"",phoneLabel:"Call Us",locationBtn:"",locationLabel:"Location",closeBtn:!1,closeLabel:"Close",mobileMode:!1,scrollbarFix:!1},e);return this.each(function(){if(("light"==t.theme||"dark"==t.theme)&&nav.addClass(t.theme),t.breakpoint&&(n=t.breakpoint),menuLabel=t.menuLabel?t.menuLabel:"",phoneLabel=t.phoneLabel?t.phoneLabel:"",locationLabel=t.locationLabel?t.locationLabel:"",closeLabel=t.closeLabel?t.closeLabel:"",t.phoneBtn&&t.locationBtn)var e="third";else if(t.phoneBtn||t.locationBtn)var e="half";else var e="full";if("right"==t.position||"left"==t.position?nav.prepend('<a href="#" class="menu-toggle"><span class="bars"><span></span><span></span><span></span></span></a>'):nav.prepend('<a href="#" class="menu-toggle '+e+'"><span class="bars"><span></span><span></span><span></span></span></a>'),t.phoneBtn&&!("right"==t.position||"left"==t.position)){var l='<a href="tel:'+t.phoneBtn+'" class="call-btn-mobile '+e+'"><svg id="icon-phone"></svg> <span>'+phoneLabel+"</span></a>";nav.find("a.menu-toggle").after(l)}if(t.locationBtn&&!("right"==t.position||"left"==t.position)){var l='<a href="'+t.locationBtn+'" class="location-btn-mobile '+e+'" target="_blank"><svg id="icon-location"></svg> <span>'+locationLabel+"</span></a>";nav.find("a.menu-toggle").after(l)}if(t.sticky&&(navPos=nav.offset().top,s>=n&&i(window).on("scroll",function(){i(window).scrollTop()>navPos?nav.addClass("fixed"):nav.removeClass("fixed")})),"top"==t.position&&nav.addClass("top"),"left"==t.position||"right"==t.position){var o='<a href="#" class="close-menu '+e+'"><span class="icon-close"></span>'+closeLabel+"</a>",a='<a href="tel:'+t.phoneBtn+'" class="call-btn-mobile '+e+'"><svg id="icon-phone"></svg></a>',_='<a href="'+t.locationBtn+'" class="location-btn-mobile '+e+'" target="_blank"><svg id="icon-location"></svg></i></a>';nav.find("ul:first").prepend(o),t.locationBtn&&nav.find("ul:first").prepend(_),t.phoneBtn&&nav.find("ul:first").prepend(a)}"right"==t.position&&nav.addClass("right"),"left"==t.position&&nav.addClass("left"),t.showArrows||nav.addClass("hide-arrows"),t.closeBtn&&!("right"==t.position||"left"==t.position)&&nav.find("ul:first").append('<li><a href="#" class="close-menu"><span class="icon-close"></span> '+closeLabel+"</a></li>"),t.scrollbarFix&&i("body").addClass("stellarnav-noscroll-x");var c=document.getElementById("icon-phone");if(c){c.setAttribute("viewBox","0 0 480 480");var d=document.createElementNS("http://www.w3.org/2000/svg","path");d.setAttribute("d","M340.273,275.083l-53.755-53.761c-10.707-10.664-28.438-10.34-39.518,0.744l-27.082,27.076 c-1.711-0.943-3.482-1.928-5.344-2.973c-17.102-9.476-40.509-22.464-65.14-47.113c-24.704-24.701-37.704-48.144-47.209-65.257 c-1.003-1.813-1.964-3.561-2.913-5.221l18.176-18.149l8.936-8.947c11.097-11.1,11.403-28.826,0.721-39.521L73.39,8.194 C62.708-2.486,44.969-2.162,33.872,8.938l-15.15,15.237l0.414,0.411c-5.08,6.482-9.325,13.958-12.484,22.02 C3.74,54.28,1.927,61.603,1.098,68.941C-6,127.785,20.89,181.564,93.866,254.541c100.875,100.868,182.167,93.248,185.674,92.876 c7.638-0.913,14.958-2.738,22.397-5.627c7.992-3.122,15.463-7.361,21.941-12.43l0.331,0.294l15.348-15.029 C350.631,303.527,350.95,285.795,340.273,275.083z"),c.appendChild(d)}var p=document.getElementById("icon-location");if(p){p.setAttribute("viewBox","0 0 480 480");var r=document.createElementNS("http://www.w3.org/2000/svg","path");r.setAttribute("d","M322.621,42.825C294.073,14.272,259.619,0,219.268,0c-40.353,0-74.803,14.275-103.353,42.825 c-28.549,28.549-42.825,63-42.825,103.353c0,20.749,3.14,37.782,9.419,51.106l104.21,220.986 c2.856,6.276,7.283,11.225,13.278,14.838c5.996,3.617,12.419,5.428,19.273,5.428c6.852,0,13.278-1.811,19.273-5.428 c5.996-3.613,10.513-8.562,13.559-14.838l103.918-220.986c6.282-13.324,9.424-30.358,9.424-51.106 C365.449,105.825,351.176,71.378,322.621,42.825z M270.942,197.855c-14.273,14.272-31.497,21.411-51.674,21.411 s-37.401-7.139-51.678-21.411c-14.275-14.277-21.414-31.501-21.414-51.678c0-20.175,7.139-37.402,21.414-51.675 c14.277-14.275,31.504-21.414,51.678-21.414c20.177,0,37.401,7.139,51.674,21.414c14.274,14.272,21.413,31.5,21.413,51.675 C292.355,166.352,285.217,183.575,270.942,197.855z"),p.appendChild(r)}function h(e){e.preventDefault(),i(this).parent("li").children("ul").stop(!0,!0).slideToggle(t.openingSpeed),i(this).parent("li").toggleClass("open")}i(".menu-toggle, .stellarnav-open").on("click",function(e){e.preventDefault(),"left"==t.position||"right"==t.position?(nav.find("ul:first").stop(!0,!0).fadeToggle(t.openingSpeed),nav.toggleClass("active"),nav.hasClass("active")&&nav.hasClass("mobile")&&i(document).on("click",function(e){nav.hasClass("mobile")&&!i(e.target).closest(nav).length&&(nav.find("ul:first").stop(!0,!0).fadeOut(t.openingSpeed),nav.removeClass("active"))})):(nav.find("ul:first").stop(!0,!0).slideToggle(t.openingSpeed),nav.toggleClass("active"))}),i(".close-menu, .stellarnav-close").on("click",function(){nav.removeClass("active"),"left"==t.position||"right"==t.position?nav.find("ul:first").stop(!0,!0).fadeToggle(t.openingSpeed):nav.find("ul:first").stop(!0,!0).slideUp(t.openingSpeed).toggleClass("active")}),nav.find("li a").each(function(){i(this).next().length>0&&(i(this).addClass("sub-list"),i(this).parent("li").addClass("has-sub").append('<a class="dd-toggle" href="#"><span class="icon-plus"></span></a>'))}),nav.find("li .dd-toggle").on("click",h),nav.find("li .sub-list").on("click",h);var f=function(){nav.find("li").off("mouseenter"),nav.find("li").off("mouseleave")};parentItems=nav.find("> ul > li");var $=function(){i(parentItems).each(function(){i(this).hasClass("mega")?(i(this).on("mouseenter",function(){i(this).find("ul").first().stop(!0,!0).slideDown(t.openingSpeed)}),i(this).on("mouseleave",function(){i(this).find("ul").first().stop(!0,!0).slideUp(t.openingSpeed)})):(i(this).on("mouseenter",function(){i(this).children("ul").stop(!0,!0).slideDown(t.openingSpeed)}),i(this).on("mouseleave",function(){i(this).children("ul").stop(!0,!0).delay(t.closingDelay).slideUp(t.openingSpeed)}),i(this).find("li.has-sub").on("mouseenter",function(){i(this).children("ul").stop(!0,!0).slideDown(t.openingSpeed)}),i(this).find("li.has-sub").on("mouseleave",function(){i(this).children("ul").stop(!0,!0).delay(t.closingDelay).slideUp(t.openingSpeed)}))})};function u(){window.innerWidth<=n||t.mobileMode?(f(),nav.addClass("mobile"),nav.removeClass("desktop"),!nav.hasClass("active")&&nav.find("ul:first").is(":visible")&&nav.find("ul:first").hide(),nav.find("li.mega").each(function(){i(this).find("ul").first().removeAttr("style"),i(this).find("ul").first().children().removeAttr("style")})):(nav.addClass("desktop"),nav.removeClass("mobile"),nav.hasClass("active")&&nav.removeClass("active"),!nav.hasClass("active")&&nav.find("ul:first").is(":hidden")&&nav.find("ul:first").show(),i("li.open").removeClass("open").find("ul:visible").hide(),f(),$(),navWidth=0,i(parentItems).each(function(){navWidth+=i(this)[0].getBoundingClientRect().width,navWidth=Math.round(navWidth),i(this).hasClass("mega")&&(i(this).find("ul").first().css({left:0,right:0,margin:"0px auto"}),2==(numCols=i(this).attr("data-columns"))?i(this).find("li.has-sub").width("50%"):3==numCols?i(this).find("ul").first().children().width("33.33%"):4==numCols?i(this).find("ul").first().children().width("25%"):5==numCols?i(this).find("ul").first().children().width("20%"):6==numCols?i(this).find("ul").first().children().width("16.66%"):7==numCols?i(this).find("ul").first().children().width("14.28%"):8==numCols?i(this).find("ul").first().children().width("12.5%"):i(this).find("ul").first().children().width("25%"))}),parentItems.hasClass("mega")&&nav.find("li.mega > ul").css({"max-width":navWidth}))}u(),i(window).on("resize",function(){u()})})}}(jQuery); No newline at end of file
!function(i){i.fn.stellarNav=function(e,s,n){nav=i(this),s=i(window).width();var t=i.extend({theme:"plain",breakpoint:768,menuLabel:"",sticky:!1,position:"static",openingSpeed:80,closingDelay:80,showArrows:!0,phoneBtn:"",phoneLabel:"Call Us",locationBtn:"",locationLabel:"Location",closeBtn:!1,closeLabel:"Close",mobileMode:!1,scrollbarFix:!1},e);return this.each(function(){if(("light"==t.theme||"dark"==t.theme)&&nav.addClass(t.theme),t.breakpoint&&(n=t.breakpoint),menuLabel=t.menuLabel?t.menuLabel:"",phoneLabel=t.phoneLabel?t.phoneLabel:"",locationLabel=t.locationLabel?t.locationLabel:"",closeLabel=t.closeLabel?t.closeLabel:"",t.phoneBtn&&t.locationBtn)var e="third";else if(t.phoneBtn||t.locationBtn)var e="half";else var e="full";if("right"==t.position||"left"==t.position?nav.prepend('<a href="#" class="menu-toggle"><span class="bars"><span></span><span></span><span></span></span></a>'):nav.prepend('<a href="#" class="menu-toggle '+e+'"><span class="bars"><span></span><span></span><span></span></span></a>'),t.phoneBtn&&!("right"==t.position||"left"==t.position)){var l='<a href="tel:'+t.phoneBtn+'" class="call-btn-mobile '+e+'"><svg id="icon-phone"></svg> <span>'+phoneLabel+"</span></a>";nav.find("a.menu-toggle").after(l)}if(t.locationBtn&&!("right"==t.position||"left"==t.position)){var l='<a href="'+t.locationBtn+'" class="location-btn-mobile '+e+'" target="_blank"><svg id="icon-location"></svg> <span>'+locationLabel+"</span></a>";nav.find("a.menu-toggle").after(l)}if(t.sticky&&(navPos=nav.offset().top,s>=n&&i(window).on("scroll",function(){i(window).scrollTop()>navPos?nav.addClass("fixed"):nav.removeClass("fixed")})),"top"==t.position&&nav.addClass("top"),"left"==t.position||"right"==t.position){var o='<a href="#" class="close-menu '+e+'"><span class="icon-close"></span>'+closeLabel+"</a>",a='<a href="tel:'+t.phoneBtn+'" class="call-btn-mobile '+e+'"><svg id="icon-phone"></svg></a>',_='<a href="'+t.locationBtn+'" class="location-btn-mobile '+e+'" target="_blank"><svg id="icon-location"></svg></i></a>';nav.find("ul:first").prepend(o),t.locationBtn&&nav.find("ul:first").prepend(_),t.phoneBtn&&nav.find("ul:first").prepend(a)}"right"==t.position&&nav.addClass("right"),"left"==t.position&&nav.addClass("left"),t.showArrows||nav.addClass("hide-arrows"),t.closeBtn&&!("right"==t.position||"left"==t.position)&&nav.find("ul:first").append('<li><a href="#" class="close-menu"><span class="icon-close"></span> '+closeLabel+"</a></li>"),t.scrollbarFix&&i("body").addClass("stellarnav-noscroll-x");var c=document.getElementById("icon-phone");if(c){c.setAttribute("viewBox","0 0 480 480");var d=document.createElementNS("http://www.w3.org/2000/svg","path");d.setAttribute("d","M340.273,275.083l-53.755-53.761c-10.707-10.664-28.438-10.34-39.518,0.744l-27.082,27.076 c-1.711-0.943-3.482-1.928-5.344-2.973c-17.102-9.476-40.509-22.464-65.14-47.113c-24.704-24.701-37.704-48.144-47.209-65.257 c-1.003-1.813-1.964-3.561-2.913-5.221l18.176-18.149l8.936-8.947c11.097-11.1,11.403-28.826,0.721-39.521L73.39,8.194 C62.708-2.486,44.969-2.162,33.872,8.938l-15.15,15.237l0.414,0.411c-5.08,6.482-9.325,13.958-12.484,22.02 C3.74,54.28,1.927,61.603,1.098,68.941C-6,127.785,20.89,181.564,93.866,254.541c100.875,100.868,182.167,93.248,185.674,92.876 c7.638-0.913,14.958-2.738,22.397-5.627c7.992-3.122,15.463-7.361,21.941-12.43l0.331,0.294l15.348-15.029 C350.631,303.527,350.95,285.795,340.273,275.083z"),c.appendChild(d)}var p=document.getElementById("icon-location");if(p){p.setAttribute("viewBox","0 0 480 480");var r=document.createElementNS("http://www.w3.org/2000/svg","path");r.setAttribute("d","M322.621,42.825C294.073,14.272,259.619,0,219.268,0c-40.353,0-74.803,14.275-103.353,42.825 c-28.549,28.549-42.825,63-42.825,103.353c0,20.749,3.14,37.782,9.419,51.106l104.21,220.986 c2.856,6.276,7.283,11.225,13.278,14.838c5.996,3.617,12.419,5.428,19.273,5.428c6.852,0,13.278-1.811,19.273-5.428 c5.996-3.613,10.513-8.562,13.559-14.838l103.918-220.986c6.282-13.324,9.424-30.358,9.424-51.106 C365.449,105.825,351.176,71.378,322.621,42.825z M270.942,197.855c-14.273,14.272-31.497,21.411-51.674,21.411 s-37.401-7.139-51.678-21.411c-14.275-14.277-21.414-31.501-21.414-51.678c0-20.175,7.139-37.402,21.414-51.675 c14.277-14.275,31.504-21.414,51.678-21.414c20.177,0,37.401,7.139,51.674,21.414c14.274,14.272,21.413,31.5,21.413,51.675 C292.355,166.352,285.217,183.575,270.942,197.855z"),p.appendChild(r)}function h(e){if(nav[0].classList.contains("desktop")&&this.classList.contains("sub-list"))return;e.preventDefault(),i(this).parent("li").children("ul").stop(!0,!0).slideToggle(t.openingSpeed),i(this).parent("li").toggleClass("open")}i(".menu-toggle, .stellarnav-open").on("click",function(e){e.preventDefault(),"left"==t.position||"right"==t.position?(nav.find("ul:first").stop(!0,!0).fadeToggle(t.openingSpeed),nav.toggleClass("active"),nav.hasClass("active")&&nav.hasClass("mobile")&&i(document).on("click",function(e){nav.hasClass("mobile")&&!i(e.target).closest(nav).length&&(nav.find("ul:first").stop(!0,!0).fadeOut(t.openingSpeed),nav.removeClass("active"))})):(nav.find("ul:first").stop(!0,!0).slideToggle(t.openingSpeed),nav.toggleClass("active"))}),i(".close-menu, .stellarnav-close").on("click",function(){nav.removeClass("active"),"left"==t.position||"right"==t.position?nav.find("ul:first").stop(!0,!0).fadeToggle(t.openingSpeed):nav.find("ul:first").stop(!0,!0).slideUp(t.openingSpeed).toggleClass("active")}),nav.find("li a").each(function(){i(this).next().length>0&&(i(this).addClass("sub-list"),i(this).parent("li").addClass("has-sub").append('<a class="dd-toggle" href="#"><span class="icon-plus"></span></a>'))}),nav.find("li .dd-toggle").on("click",h),nav.find("li .sub-list").on("click",h);var f=function(){nav.find("li").off("mouseenter"),nav.find("li").off("mouseleave")};parentItems=nav.find("> ul > li");var $=function(){i(parentItems).each(function(){i(this).hasClass("mega")?(i(this).on("mouseenter",function(){i(this).find("ul").first().stop(!0,!0).slideDown(t.openingSpeed)}),i(this).on("mouseleave",function(){i(this).find("ul").first().stop(!0,!0).slideUp(t.openingSpeed)})):(i(this).on("mouseenter",function(){i(this).children("ul").stop(!0,!0).slideDown(t.openingSpeed)}),i(this).on("mouseleave",function(){i(this).children("ul").stop(!0,!0).delay(t.closingDelay).slideUp(t.openingSpeed)}),i(this).find("li.has-sub").on("mouseenter",function(){i(this).children("ul").stop(!0,!0).slideDown(t.openingSpeed)}),i(this).find("li.has-sub").on("mouseleave",function(){i(this).children("ul").stop(!0,!0).delay(t.closingDelay).slideUp(t.openingSpeed)}))})};function u(){window.innerWidth<=n||t.mobileMode?(f(),nav.addClass("mobile"),nav.removeClass("desktop"),!nav.hasClass("active")&&nav.find("ul:first").is(":visible")&&nav.find("ul:first").hide(),nav.find("li.mega").each(function(){i(this).find("ul").first().removeAttr("style"),i(this).find("ul").first().children().removeAttr("style")})):(nav.addClass("desktop"),nav.removeClass("mobile"),nav.hasClass("active")&&nav.removeClass("active"),!nav.hasClass("active")&&nav.find("ul:first").is(":hidden")&&nav.find("ul:first").show(),i("li.open").removeClass("open").find("ul:visible").hide(),f(),$(),navWidth=0,i(parentItems).each(function(){navWidth+=i(this)[0].getBoundingClientRect().width,navWidth=Math.round(navWidth),i(this).hasClass("mega")&&(i(this).find("ul").first().css({left:0,right:0,margin:"0px auto"}),2==(numCols=i(this).attr("data-columns"))?i(this).find("li.has-sub").width("50%"):3==numCols?i(this).find("ul").first().children().width("33.33%"):4==numCols?i(this).find("ul").first().children().width("25%"):5==numCols?i(this).find("ul").first().children().width("20%"):6==numCols?i(this).find("ul").first().children().width("16.66%"):7==numCols?i(this).find("ul").first().children().width("14.28%"):8==numCols?i(this).find("ul").first().children().width("12.5%"):i(this).find("ul").first().children().width("25%"))}),parentItems.hasClass("mega")&&nav.find("li.mega > ul").css({"max-width":navWidth}))}u(),i(window).on("resize",function(){u()})})}}(jQuery); No newline at end of file
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

Editing minified files directly is a significant maintainability risk. While this change fixes the immediate issue, it will be overwritten and the bug will reappear the next time this file is generated from its source (stellarnav.js). The correct practice is to modify the source file and have a build process create the minified version. Please either add a build step to this PR or create a follow-up issue to implement a proper build process for JavaScript assets.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the review! For context, the source file (js/stellarnav.js) was already fixed and merged in PR #2613.

Since this repo currently lacks an automated minification pipeline, the live site is still serving the old .min.js file. This PR just manually syncs the minified file to get the fix into production

@sm-28601
Copy link
Contributor Author

@saurabhraghuvanshii - I figured out the main issue for why the fix wasn't showing in production! The live site loads stellarnav.min.js, but I only updated the source file in PR #2613. I've synced the minified file here so it can go live. Could you please review this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants