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

Provide visual cue for editors that a folderish page is part of the site structure #4280

Open
fredvd opened this issue Jan 18, 2023 · 4 comments

Comments

@fredvd
Copy link
Member

fredvd commented Jan 18, 2023

One thing that has been confusing or rather slightly annoying while editing content in a Volto site is that everything in my (top) site hierarchy is a Page. I am lost without seeing the main site structure if I’m not reading every page title to umderstand it is a branch. I want my folders back !! 🤣 But I realise adding back the folder ct just for that is not worth it.

I had an insight though: it is only the editing UI where I want to see this. What if we index an extra property on every (Page) item that stores if the page has any direct sub pages? And with that info show a slightly different Icon on the folder contents to signal that this page is part of the site structure. That would do it for me as a visual cue for the branches between the leaves.

The icons shoudn’t switch for only contained images and files in a Page. Those are probably part of the blocks layout on the page.

We could even create 3 or 4 icons, where the folder icons are similar slightly differ on how much they are filled: if more than x pages are there or if there are sib sub pages. I do wonder what the indexing costs would be for this with a very large site. Then again, you could let the indexer run only when content is added and recalculate/reindex the parents.

Is something like this feasible? is the folderish page vs 'structural folder' UX debate partly addressed in Quanta? @sneridagh @tiberiuichim

( mostly copied from discussion at https://community.plone.org/t/why-is-volto-overriding-classical-dexterity-types/15895/4 )

@tiberiuichim
Copy link
Contributor

We would need a catalog metadata field to inform of the number of children, then this information can be plugged in the UI (the /contents view uses the @search endpoint)

@davisagli
Copy link
Member

There was an idea from a long time ago to change the indexer for the existing is_folderish index so that it returns true if the item has children or allows children to be added (instead of just a static property of the content type). We would need to take a look at how is_folderish is currently used and make sure that won't cause problems. plone/CMFPlone#317 doesn't discuss the indexer explicitly but is related.

@avoinea
Copy link
Member

avoinea commented Jun 7, 2023

I think that reindexing the parent everytime a child is added or removed will lead to ZODB ConflictErrors on sites with lot of editors.

@wesleybl
Copy link
Member

wesleybl commented Jun 7, 2023

@avoinea this reindexing is already done. See: plone/plone.volto#118 (comment)

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

6 participants