-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Fix #12795: Missing class on Points > Manage Group menu #14750
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
Conversation
The issue occurred because CSS misinterpreted the group’s ID (mautic_point.group_index), treating the dot as a class separator instead of part of the ID. This was fixed by applying CSS.escape() to ensure proper handling. Tests were also added to verify the fix and prevent regressions.
@nox1134 would you take a 👀 at the E2E test here? |
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.
Pull Request Overview
This PR fixes the active state indicator for the "Manage Groups" menu under "Points" by escaping the CSS selector string to prevent misinterpretation of the dot.
- Updates the JS file to apply CSS.escape() to the link identifier.
- Ensures the visual indicator (dot) before the menu item displays as expected.
Files not reviewed (3)
- tests/_support/Page/Acceptance/MenuPage.php: Language not supported
- tests/_support/Step/Acceptance/MenuStep.php: Language not supported
- tests/acceptance/MenuNavigationCest.php: Language not supported
Comments suppressed due to low confidence (1)
app/bundles/CoreBundle/Assets/js/1a.content.js:926
- Ensure that CSS.escape is supported in all target browsers or that a polyfill is provided to avoid potential runtime errors in unsupported environments.
link = "#" + CSS.escape(link);
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.
The code changes look great! The usage of CSS.escape()
is used as they do in the docs:
at https://developer.mozilla.org/en-US/docs/Web/API/CSS/escape_static
I approve the code changes 👍
@RCheesley @escopecz a first-time contributor's PR - needs to be added via @all-contributors |
@all-contributors please add @SaraCRM for code tests |
I've put up a pull request to add @SaraCRM! 🎉 |
Description
The "Manage Groups" menu item under "Points" didn’t display the expected active state. The visual indicator (dot) before the item was missing, making it unclear which page was selected.
The issue occurred because CSS misinterpreted the group’s ID (mautic_point.group_index), treating the dot as a class separator instead of part of the ID. This was fixed by applying CSS.escape() to ensure proper handling. Tests were also added to verify the fix and prevent regressions.
📋 Steps to test this PR: