From 286da6d9ca0c96d32b807be3e22776d5c8dcebf7 Mon Sep 17 00:00:00 2001 From: Adam Argyle Date: Fri, 29 Sep 2023 11:50:04 -0700 Subject: [PATCH] document and create fallback --- docsite/index.html | 8 ++++++-- src/props.easing.css | 10 ++++++++++ src/props.easing.js | 12 ++++++++++++ 3 files changed, 28 insertions(+), 2 deletions(-) diff --git a/docsite/index.html b/docsite/index.html index a56a5517..9f453685 100644 --- a/docsite/index.html +++ b/docsite/index.html @@ -2254,9 +2254,13 @@
The Props
--ease-in-out-{1-5} --ease-elastic-out-{1-5} --ease-elastic-in-{1-5} - --ease-elastic-in-out{1-5} + --ease-elastic-in-out-{1-5} --ease-spring-{1-5} --ease-step-{1-5} + + /* will be removed in v2 */ + --ease-elastic-{1-5} /* deprecated; equal to elastic-out */ + --ease-squish-{1-5} /* deprecated; equal to elastic-in-out */ @@ -2387,7 +2391,7 @@
Ease Elastic In
ease-elastic-in-4
ease-elastic-in-5
- å +
diff --git a/src/props.easing.css b/src/props.easing.css index 07159a08..d0d03626 100644 --- a/src/props.easing.css +++ b/src/props.easing.css @@ -39,6 +39,16 @@ --ease-step-3: steps(4); --ease-step-4: steps(7); --ease-step-5: steps(10); + --ease-elastic-1: var(--ease-elastic-out-1); + --ease-elastic-2: var(--ease-elastic-out-2); + --ease-elastic-3: var(--ease-elastic-out-3); + --ease-elastic-4: var(--ease-elastic-out-4); + --ease-elastic-5: var(--ease-elastic-out-5); + --ease-squish-1: var(--elastic-in-out-1); + --ease-squish-2: var(--elastic-in-out-2); + --ease-squish-3: var(--elastic-in-out-3); + --ease-squish-4: var(--elastic-in-out-4); + --ease-squish-5: var(--elastic-in-out-5); --ease-spring-1: linear( 0, 0.006, 0.025 2.8%, 0.101 6.1%, 0.539 18.9%, 0.721 25.3%, 0.849 31.5%, 0.937 38.1%, 0.968 41.8%, 0.991 45.7%, 1.006 50.1%, 1.015 55%, 1.017 63.9%, diff --git a/src/props.easing.js b/src/props.easing.js index e21cb06f..bb583ec9 100644 --- a/src/props.easing.js +++ b/src/props.easing.js @@ -47,6 +47,18 @@ export default { '--ease-step-4': 'steps(7)', '--ease-step-5': 'steps(10)', + '--ease-elastic-1': 'var(--ease-elastic-out-1)', + '--ease-elastic-2': 'var(--ease-elastic-out-2)', + '--ease-elastic-3': 'var(--ease-elastic-out-3)', + '--ease-elastic-4': 'var(--ease-elastic-out-4)', + '--ease-elastic-5': 'var(--ease-elastic-out-5)', + + '--ease-squish-1': 'var(--elastic-in-out-1)', + '--ease-squish-2': 'var(--elastic-in-out-2)', + '--ease-squish-3': 'var(--elastic-in-out-3)', + '--ease-squish-4': 'var(--elastic-in-out-4)', + '--ease-squish-5': 'var(--elastic-in-out-5)', + '--ease-spring-1': `linear( 0, 0.006, 0.025 2.8%, 0.101 6.1%, 0.539 18.9%, 0.721 25.3%, 0.849 31.5%, 0.937 38.1%, 0.968 41.8%, 0.991 45.7%, 1.006 50.1%, 1.015 55%, 1.017 63.9%,