Skip to content

Commit

Permalink
fade-in-bloom and fade-out-boom for argyleink#255 (argyleink#260)
Browse files Browse the repository at this point in the history
* fade-in-bloom and fade-out-boom for argyleink#255

* update test 1086 + 8 = 1094

* remove console log (used for quick debug)
  • Loading branch information
hchiam committed Aug 11, 2022
1 parent 5f748e1 commit e1a0512
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 1 deletion.
12 changes: 12 additions & 0 deletions src/props.animations.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
:where(html) {
--animation-fade-in: fade-in .5s var(--ease-3);
--animation-fade-in-bloom: fade-in-bloom 2s var(--ease-3);
--animation-fade-out: fade-out .5s var(--ease-3);
--animation-fade-out-bloom: fade-out-bloom 2s var(--ease-3);
--animation-scale-up: scale-up .5s var(--ease-3);
--animation-scale-down: scale-down .5s var(--ease-3);
--animation-slide-out-up: slide-out-up .5s var(--ease-3);
Expand All @@ -24,9 +26,19 @@
@keyframes fade-in {
to { opacity: 1 }
}
@keyframes fade-in-bloom {
0% { opacity: 0; filter: brightness(1) blur(20px) }
10% { opacity: 1; filter: brightness(2) blur(10px) }
100% { opacity: 1; filter: brightness(1) blur(0) }
}
@keyframes fade-out {
to { opacity: 0 }
}
@keyframes fade-out-bloom {
100% { opacity: 0; filter: brightness(1) blur(20px) }
10% { opacity: 1; filter: brightness(2) blur(10px) }
0% { opacity: 1; filter: brightness(1) blur(0) }
}
@keyframes scale-up {
to { transform: scale(1.25) }
}
Expand Down
14 changes: 14 additions & 0 deletions src/props.animations.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,25 @@ export default {
"--animation-fade-in-@": `
@keyframes fade-in {
to { opacity: 1 }
}`,
"--animation-fade-in-bloom": "fade-in-bloom 2s var(--ease-3)",
"--animation-fade-in-bloom-@": `
@keyframes fade-in-bloom {
0% { opacity: 0; filter: brightness(1) blur(20px) }
10% { opacity: 1; filter: brightness(2) blur(10px) }
100% { opacity: 1; filter: brightness(1) blur(0) }
}`,
"--animation-fade-out": "fade-out .5s var(--ease-3)",
"--animation-fade-out-@": `
@keyframes fade-out {
to { opacity: 0 }
}`,
"--animation-fade-out-bloom": "fade-out-bloom 2s var(--ease-3)",
"--animation-fade-out-bloom-@": `
@keyframes fade-out-bloom {
100% { opacity: 0; filter: brightness(1) blur(20px) }
10% { opacity: 1; filter: brightness(2) blur(10px) }
0% { opacity: 1; filter: brightness(1) blur(0) }
}`,
"--animation-scale-up": "scale-up .5s var(--ease-3)",
"--animation-scale-up-@": `
Expand Down
2 changes: 1 addition & 1 deletion test/basic.test.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const OpenProps = require('../dist/open-props.cjs')
const OPtokens = require('../open-props.tokens.json')

test('Should have an all included import', t => {
t.is(Object.keys(OpenProps).length, 1086)
t.is(Object.keys(OpenProps).length, 1094)
})

test('Import should have animations', async t => {
Expand Down

0 comments on commit e1a0512

Please sign in to comment.