Skip to content
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

contentSelector only finds first matching element #51

Open
fteuber opened this issue Nov 15, 2019 · 2 comments
Open

contentSelector only finds first matching element #51

fteuber opened this issue Nov 15, 2019 · 2 comments

Comments

@fteuber
Copy link

fteuber commented Nov 15, 2019

The plugin uses querySelector(contentSelector) to get the content. By default, contentSelector is 'body' (PageParser.js)

We want to exclude all texts that are not in a top content-collection. In some setups there are more than one content-collections (e.g. one for "header", one for "main"). This leads to the problem, that something like "body > .neos-contentcollection" does not work. It only returns the first content-collection instead of all,

I would like to have PageParser to instead use querySelectorAll for this purpose. Would this break stuff? Should there be an option?

@Sebobo
Copy link
Collaborator

Sebobo commented Nov 15, 2019

Hi,

would be great to have this feature. Do you want to take a shot at it?
Shouldn't be to hard.

Bit busy right now with other stuff, so it would be great if I just have to review a PR.

@fteuber
Copy link
Author

fteuber commented Nov 26, 2019

Hi,

would be great to have this feature. Do you want to take a shot at it?
Shouldn't be to hard.

We probably will do a fork soon for a quick solution and a PR later if it looks well enough.

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

No branches or pull requests

2 participants