Skip to content

Issues with panel tab #1856

@Toutouwai

Description

@Toutouwai

Short description of the issue

I found a couple of issues with the tab that's displayed on the side of an open panel.

I'm following the documentation in /wire/modules/Jquery/JqueryUI/panel.js

For testing purposes I'm adding a link to ProcessPageEdit that opens a panel showing the page list:

$wire->addHookAfter('ProcessPageEdit::buildFormContent', function(HookEvent $event) {
	$wrapper = $event->return;
	$wrapper->appendMarkup = "<a class='pw-panel' href='/processwire/page/?modal=panel&pw_panel=1'>Open panel</a>";
});

If I add a data-tab-text='My panel' attribute the text is not visible in the tab:

2023-12-10_172959

If I add a data-tab-icon='list-ul' attribute the tab icon is unexpectedly rotated 90 degrees:

2023-12-10_173217

To get the rotation corrected it seems I have to also add a data-tab-text attribute but it's not clear why that should be needed if I'm choosing to display an icon rather than text.

Also, is there supposed to be a way to not show a tab on the panel? It would be good if there was because the tab seems like it's unnecessary in many cases but data-tab-text='' and data-tab-icon='' just results in a default tab being shown, again with the icon rotated incorrectly.

2023-12-10_173645

Setup/Environment

  • ProcessWire version: 3.0.231

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions