Skip to content

Commit

Permalink
fix(modal): card style modal now adds appropriate contrast (#20604)
Browse files Browse the repository at this point in the history
  • Loading branch information
liamdebeasi committed Feb 24, 2020
1 parent 0224bed commit b5310ef
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions core/src/components/modal/animations/ios.enter.ts
Expand Up @@ -44,8 +44,8 @@ export const iosEnterAnimation = (
.beforeAddWrite(() => bodyEl.style.setProperty('background-color', 'black'))
.addElement(presentingEl)
.keyframes([
{ offset: 0, transform: 'translateY(0px) scale(1)', borderRadius: '0px' },
{ offset: 1, transform: finalTransform, borderRadius: '10px 10px 0 0' }
{ offset: 0, filter: 'contrast(1)', transform: 'translateY(0px) scale(1)', borderRadius: '0px' },
{ offset: 1, filter: 'contrast(0.85)', transform: finalTransform, borderRadius: '10px 10px 0 0' }
]);

baseAnimation.addAnimation(presentingAnimation);
Expand Down
4 changes: 2 additions & 2 deletions core/src/components/modal/animations/ios.leave.ts
Expand Up @@ -46,8 +46,8 @@ export const iosLeaveAnimation = (
}
})
.keyframes([
{ offset: 0, transform: `translateY(${modalTransform}) scale(${currentPresentingScale})`, borderRadius: '10px 10px 0 0' },
{ offset: 1, transform: 'translateY(0px) scale(1)', borderRadius: '0px' }
{ offset: 0, filter: 'contrast(0.85)', transform: `translateY(${modalTransform}) scale(${currentPresentingScale})`, borderRadius: '10px 10px 0 0' },
{ offset: 1, filter: 'contrast(1)', transform: 'translateY(0px) scale(1)', borderRadius: '0px' }
]);

baseAnimation.addAnimation(presentingAnimation);
Expand Down
2 changes: 1 addition & 1 deletion core/src/components/modal/modal.ios.scss
Expand Up @@ -20,7 +20,7 @@
}

:host(.modal-card) {
--backdrop-opacity: 0.15;
--backdrop-opacity: 0;
--width: 100%;

align-items: flex-end;
Expand Down

0 comments on commit b5310ef

Please sign in to comment.