-
-
Notifications
You must be signed in to change notification settings - Fork 661
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
fix: BodyClass depending on sections #6487
Conversation
✅ Deploy Preview for plone-components canceled.
|
Co-authored-by: Steve Piercy <web@stevepiercy.com>
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.
News looks good.
This PR needs a technical review from @plone/volto-team. I'm not sure whether this is a breaking change.
@giuliaghisini can you explain the issue that this PR solves?
@stevepiercy technically speaking it should replace all values of space with -. It's stupid that js has replace and replaceAll as such if you have more than one space only the first is replaced. Personally, I don't understand why we would set the searchable text as body classes. |
Other than it might have been a carryover from Classic UI, it is common with search engine indexing to specify the parts of the page that are indexible. Usually they exclude navigation, headers, footers, and other site-wide elements, and include |
That clearly looks like a bug to me. That code is trying to add a class for the Add view only, including the name of the content type being added -- but it's missing a conditional to only do it there.
TIL, but I don't really see how that's related to this class. |
the problem was exactly this one :-D. |
@giuliaghisini @davisagli marked it as a bug and I assume that so would @sneridagh. Would you be willing since you are here to also ensure this doesn't happen in this pull request if Victor also confirms this as a bug? |
This PR resolves the issue with replacing multiple spaces with |
@ichim-david @giuliaghisini yeah, looks like a bug and we should address it in other PR. |
* main: Release 18.1.1 Release @plone/providers 1.0.0-alpha.6 Release @plone/components 2.2.0 [components] Update RAC to 1.5.0, fix Disclosure import (#6498) Update instructions to install pipx in `RELEASING.md` (#6496) Refactor documentation includes to align with main documentation pattern (#6495) More privacy concerning youtube links and fixing link check warnings for youtube playlist links (#6494) fix: BodyClass depending on sections (#6487) Do not break toolbar if layout id is not registerd in layoutViewsNamesMapping (#6485) Add support for sphinxcontrib-youtube and alt tags for videos (#6486) Remove conflicting searchtools.js file for documentation (#6482) Release 18.1.0 Release @plone/slate 18.0.1 Add missing style Helmet serialization in the HTML component to make it work in SSR too (#6480) fix locales Dutch Translations update. (#6476) Docs 6472 tidy (#6475)
When you search for a string with spaces in search site, page brokes because section body class is wrong calculated
If your pull request closes an open issue, include the exact text below, immediately followed by the issue number. When your pull request gets merged, then that issue will close automatically.
Closes #