diff --git a/src/slider/tp-slider.ts b/src/slider/tp-slider.ts index 9c5409b..530fa2c 100644 --- a/src/slider/tp-slider.ts +++ b/src/slider/tp-slider.ts @@ -319,7 +319,9 @@ export class TPSliderElement extends HTMLElement { } // First, update the height. - this.updateHeight(); + + // Yield to main thread to fix a bug in Safari 16. + setTimeout( () => this.updateHeight(), 0 ); // Now lets slide! const behaviour: string = this.getAttribute( 'behaviour' ) || '';