You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 19, 2024. It is now read-only.
paper-tabs inside a paper-toolbar inside a paper-header-panel. On load the tabs are hidden but have a default selected value (which happens to be the last and currently off-screen tab). On finishing load the paper-tabs are shown and I explicitly fire iron-resize on the paper-tabs element to force render of the scrollable arrows if necessary.
Expected outcome
iron-resize event and the subsequent call to _tabChanged() inside the _onResize() call should scroll to the currently selected item
Resize your screen to about iphone size (375 width) to see the tab scrolly-ness
Possible fix
In userspace see my workaround (explicitly firing, iron-select as well as iron-resize), if it were to be fixed inside paper-tabs it looks like the fix is to simply pass the currently selected item as the "old" item in _onResize() i.e., _tabChanged(this.selectedItem, this.selectedItem);
Browsers Affected
Chrome
Firefox
Safari 9
Safari 8
Safari 7
Edge
IE 11
IE 10
The text was updated successfully, but these errors were encountered:
When should paper-tabs scroll to the selected tab?
I'm having a similar issue when having several tabs and the last one is selected declaratively.
Here is a demo: https://jsbin.com/ciqasuhici/2/edit?html,output
Description
paper-tabs
inside apaper-toolbar
inside apaper-header-panel
. On load the tabs are hidden but have a default selected value (which happens to be the last and currently off-screen tab). On finishing load the paper-tabs are shown and I explicitly fireiron-resize
on thepaper-tabs
element to force render of the scrollable arrows if necessary.Expected outcome
iron-resize
event and the subsequent call to_tabChanged()
inside the_onResize()
call should scroll to the currently selected itemActual outcome
Does not scroll to the currently selected item
Live Demo
Reproduction JSBin: https://jsbin.com/fokuvo/edit?html,output
Resize your screen to about iphone size (375 width) to see the tab scrolly-ness
Possible fix
In userspace see my workaround (explicitly firing,
iron-select
as well asiron-resize
), if it were to be fixed insidepaper-tabs
it looks like the fix is to simply pass the currently selected item as the "old" item in_onResize()
i.e.,_tabChanged(this.selectedItem, this.selectedItem);
Browsers Affected
The text was updated successfully, but these errors were encountered: