-
Notifications
You must be signed in to change notification settings - Fork 177
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[MWPW-166027] - Add empty space if the logo is undefined #3528
Conversation
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## stage #3528 +/- ##
=======================================
Coverage 96.47% 96.47%
=======================================
Files 260 260
Lines 60415 60416 +1
=======================================
+ Hits 58284 58285 +1
Misses 2131 2131 ☔ View full report in Codecov by Sentry. |
Reminder to set the |
@@ -457,7 +457,8 @@ export const transformTemplateToMobile = async (popup, item, localnav = false) = | |||
{{main-menu}} | |||
</button> | |||
`; | |||
const brand = document.querySelector('.feds-brand')?.outerHTML; | |||
// Get the outerHTML of the .feds-brand element or use a default empty <span> if it doesn't exist | |||
const brand = document.querySelector('.feds-brand')?.outerHTML || '<span></span>'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be an empty span, or simply an empty string? 🤔
Verified the fix for the new mobile GNAV, the logo appears as undefined in certain instances. Instead of space it was showing 'undefined' . The result looks good after the fix. https://main--cc--adobecom.hlx.page/products/indesign?milolibs=mwpw-166027--milo--deva309 |
Skipped 3528: "[MWPW-166027] - Add empty space if the logo is undefined" due to file "libs/blocks/global-navigation/utilities/utilities.js" overlap. Merging will be attempted in the next batch |
In some cases the logo is coming as undefined for the new mobile GNAV.
We have added a empty space instead of 'undefined' text showing in the new Mobile GNAV.
Error Screenshot:
Resolves: MWPW-166027
Test URLs: