Combobox with 3 or more page groups #335
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Dear Kyle,
I did my best to apply the modifications we at the PLUS do to the plugin. It took me some more effort because we made it rather hacky and ugly until now, but now I wanted to contribute a clean code.
First things first: We introduced a new term, "page group" (more precisely, we introduced it in German, "Seitengruppe"). A page group is logically a toplevel page with all its subpages. Technically, a page group is identified by its toplevel page ID alone.
This modification prevents Nested Pages from loading and listing all the page groups if they exceed a certain number. If so, a page group needs to be selected from a combobox first in order to list it. The combobox is always there, so that the view can always be restricted.
While our modification usually includes a fixed limit of 3 page groups for the selection to be required, the provided modification lefts it configurable (but defaults to 3).
Please tell me if there is something I have to fix or I can improve.
I could not get Gulp running until now, because
npm install
fails for me. So, if this contains some tests or code beautifiers, I could not run them.Cheers,
Robert.