File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
core/src/components/modal/animations Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -12,9 +12,12 @@ export const createSheetEnterAnimation = (opts: ModalAnimationOptions) => {
1212 * current breakpoint, then the backdrop should be fading in.
1313 */
1414 const shouldShowBackdrop = backdropBreakpoint === undefined || backdropBreakpoint < currentBreakpoint ! ;
15- const initialBackdrop = shouldShowBackdrop
16- ? `calc(var(--backdrop-opacity) * ${ staticBackdropOpacity ? 1 : currentBreakpoint ! } )`
17- : '0' ;
15+ let initialBackdrop = '0' ;
16+ if ( staticBackdropOpacity ) {
17+ initialBackdrop = 'calc(var(--backdrop-opacity)' ;
18+ } else if ( shouldShowBackdrop ) {
19+ initialBackdrop = `calc(var(--backdrop-opacity) * ${ currentBreakpoint ! } )` ;
20+ }
1821
1922 const backdropAnimation = createAnimation ( 'backdropAnimation' ) . fromTo ( 'opacity' , 0 , initialBackdrop ) ;
2023
You can’t perform that action at this time.
0 commit comments