Tabs are showing even when there are no visible panels inside
See original GitHub issueIssue Summary
In wagtail 3.0 a tab in the admin UI is shown even if it has no visible panels or fields (e.g. because of lacking user permissions).
Steps to Reproduce
- In the bakery demo, update the blog model (or any model) with the following
settings_panels
settings_panels = [
FieldPanel("go_live_at", permission='superuser')
]
- As superuser, confirm you can view the settings tab and see one field
- Create a user that does not have superuser (admin) permissions
- In a new incognito window, sign in as the non-superuser
- Load any blog page
- Expected: The settings tab should not show at all
- Actual: The settings tab shows but no fields are visible within it
Screenshot
User does not have permissions to see the settings panel fields and instead of the tab not showing at all, it shows but is blank inside.
Additional context
- This is because
wagtailadmin/panels/tabbed_interface.html
renderschild in self.children
instead ofchild in self.visible_children
. - Maybe there is a good reason for this implementation but from a editor perspective it looks like something’s wrong…
Technical details
- Python version:
3.9
. - Django version:
4.0
. - Wagtail version:
3.0
.
Issue Analytics
- State:
- Created a year ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Panel inside tab not displayed - java
Everything is working fine one by one but all together are not displaying. Is there is a "special" layout to use for the...
Read more >Task Manager Menu Bar and Tabs Are Not Visible
Click Start, and then click Run. Type taskmgr.exe. Hold down CTRL+ALT+SHIFT at the same time, and while holding them down press ENTER.
Read more >What To Do When Worksheet Tabs Go Missing
If so, the first place to check is to see if the worksheet has been hidden. In Excel 2007 and later, you can...
Read more >The screen tabs are not visible in the new Jira issue view.
The screen tabs are not visible in the new Jira issue view. ... that Tab is always showing under Show More even if...
Read more >Tabs | APG | WAI
When a tabbed interface is initialized, one tab panel is displayed and ... their normal browser scrolling functions even when focus is inside...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thank you!!!
Cherry picked to 3.0 branch https://github.com/wagtail/wagtail/commit/6b16de6c7b1cb251acc61fd2d7a0e8ad885f0356