mirror of
https://github.com/material-components/material-web.git
synced 2024-08-17 09:30:27 +03:00
Merge pull request #4917 from VandeurenGlenn:fix-scroll-behavior-type
PiperOrigin-RevId: 576269563
This commit is contained in:
commit
2e993d3e2c
@ -157,7 +157,7 @@ export class Tabs extends LitElement {
|
||||
const max = offset + extent - hostExtent + scrollMargin;
|
||||
const to = Math.min(min, Math.max(max, scroll));
|
||||
// TODO(b/299934312): improve focus smoothness
|
||||
const behavior = !this.focusedTab ? 'smooth' : 'instant' as const;
|
||||
const behavior = !this.focusedTab ? 'smooth' : 'instant' as ScrollBehavior;
|
||||
this.scrollTo({behavior, top: 0, left: to});
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user