mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00
chore: Fix select warning when panes docked on right (#35404)
This commit is contained in:
parent
fffd87af1d
commit
62a8d4e01f
@ -63,7 +63,7 @@ export const TabbedPane: React.FunctionComponent<{
|
|||||||
]}
|
]}
|
||||||
</div>}
|
</div>}
|
||||||
{mode === 'select' && <div style={{ flex: 'auto', display: 'flex', height: '100%', overflow: 'hidden' }} role='tablist'>
|
{mode === 'select' && <div style={{ flex: 'auto', display: 'flex', height: '100%', overflow: 'hidden' }} role='tablist'>
|
||||||
<select style={{ width: '100%', background: 'none', cursor: 'pointer' }} onChange={e => {
|
<select style={{ width: '100%', background: 'none', cursor: 'pointer' }} value={selectedTab} onChange={e => {
|
||||||
setSelectedTab?.(tabs[e.currentTarget.selectedIndex].id);
|
setSelectedTab?.(tabs[e.currentTarget.selectedIndex].id);
|
||||||
}}>
|
}}>
|
||||||
{tabs.map(tab => {
|
{tabs.map(tab => {
|
||||||
@ -72,7 +72,7 @@ export const TabbedPane: React.FunctionComponent<{
|
|||||||
suffix = ` (${tab.count})`;
|
suffix = ` (${tab.count})`;
|
||||||
if (tab.errorCount)
|
if (tab.errorCount)
|
||||||
suffix = ` (${tab.errorCount})`;
|
suffix = ` (${tab.errorCount})`;
|
||||||
return <option key={tab.id} value={tab.id} selected={tab.id === selectedTab} role='tab' aria-controls={`${id}-${tab.id}`}>{tab.title}{suffix}</option>;
|
return <option key={tab.id} value={tab.id} role='tab' aria-controls={`${id}-${tab.id}`}>{tab.title}{suffix}</option>;
|
||||||
})}
|
})}
|
||||||
</select>
|
</select>
|
||||||
</div>}
|
</div>}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user