-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Page List: Prevent users from adding inner blocks to Page List #46269
Conversation
Size Change: +28 B (0%) Total Size: 1.33 MB
ℹ️ View Unchanged
|
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.
Try as I might I was not able to manipulate the inner blocks of the page list. This is the objective we want as the block is largely a read only block. The only reason we use inner blocks is to display the contents of the block more effectively in list view.
…ress#46269) * Page List: Allow only the page-list-item block, and disable the inserter and drag and drop * Also lock the page list item blocks
What?
This prevents users from modifying the content of the Page List block.
Fixes #46224.
Why?
Page List is a controlled block - it shouldn't allow users to add blocks to it in any way.
How?
We apply locking to the innerblocks, disabled the appender and turn off drag and drop.
Testing Instructions
Add a Page List block
Try to find a way of modifying the content of the block
Testing Instructions for Keyboard
As above
Co-authored-by: Maggie 3593343+MaggieCabrera@users.noreply.github.com
Co-authored-by: Dave Smith 444434+getdave@users.noreply.github.com