react-native-screen-transitions 2.0.4 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +100 -77
- package/lib/commonjs/components/{bounds-activator.js → bound-capture.js} +4 -4
- package/lib/commonjs/components/bound-capture.js.map +1 -0
- package/lib/commonjs/components/controllers/screen-lifecycle.js +18 -4
- package/lib/commonjs/components/controllers/screen-lifecycle.js.map +1 -1
- package/lib/commonjs/components/create-transition-aware-component.js +14 -12
- package/lib/commonjs/components/create-transition-aware-component.js.map +1 -1
- package/lib/commonjs/components/integrations/masked-view.js +52 -0
- package/lib/commonjs/components/integrations/masked-view.js.map +1 -0
- package/lib/commonjs/components/root-transition-aware.js +6 -15
- package/lib/commonjs/components/root-transition-aware.js.map +1 -1
- package/lib/commonjs/configs/index.js +15 -5
- package/lib/commonjs/configs/index.js.map +1 -1
- package/lib/commonjs/configs/presets.js +378 -7
- package/lib/commonjs/configs/presets.js.map +1 -1
- package/lib/commonjs/configs/specs.js +1 -1
- package/lib/commonjs/hooks/animation/use-associated-style.js +7 -10
- package/lib/commonjs/hooks/animation/use-associated-style.js.map +1 -1
- package/lib/commonjs/hooks/animation/use-screen-animation.js +37 -37
- package/lib/commonjs/hooks/animation/use-screen-animation.js.map +1 -1
- package/lib/commonjs/hooks/bounds/use-bound-registry.js +73 -0
- package/lib/commonjs/hooks/bounds/use-bound-registry.js.map +1 -0
- package/lib/commonjs/hooks/gestures/use-build-gestures.js +156 -152
- package/lib/commonjs/hooks/gestures/use-build-gestures.js.map +1 -1
- package/lib/commonjs/hooks/gestures/use-parent-gesture-registry.js +28 -0
- package/lib/commonjs/hooks/gestures/use-parent-gesture-registry.js.map +1 -0
- package/lib/commonjs/hooks/gestures/use-scroll-registry.js +146 -0
- package/lib/commonjs/hooks/gestures/use-scroll-registry.js.map +1 -0
- package/lib/commonjs/index.js +3 -0
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/integrations/native-stack/views/NativeStackView.native.js +7 -4
- package/lib/commonjs/integrations/native-stack/views/NativeStackView.native.js.map +1 -1
- package/lib/commonjs/providers/gestures.js +16 -16
- package/lib/commonjs/providers/gestures.js.map +1 -1
- package/lib/commonjs/providers/transition-styles.js +44 -0
- package/lib/commonjs/providers/transition-styles.js.map +1 -0
- package/lib/commonjs/stores/bounds.js +142 -1
- package/lib/commonjs/stores/bounds.js.map +1 -1
- package/lib/commonjs/stores/utils/reset-stores-for-screen.js +4 -2
- package/lib/commonjs/stores/utils/reset-stores-for-screen.js.map +1 -1
- package/lib/commonjs/types/gesture.js +11 -0
- package/lib/commonjs/types/gesture.js.map +1 -1
- package/lib/commonjs/utils/animation/derivations.js +39 -0
- package/lib/commonjs/utils/animation/derivations.js.map +1 -0
- package/lib/commonjs/utils/animation/run-transition.js +6 -2
- package/lib/commonjs/utils/animation/run-transition.js.map +1 -1
- package/lib/commonjs/utils/bounds/_utils/flatten-styles.js.map +1 -0
- package/lib/commonjs/utils/bounds/_utils/geometry.js +179 -0
- package/lib/commonjs/utils/bounds/_utils/geometry.js.map +1 -0
- package/lib/commonjs/utils/bounds/{get-bounds.js → _utils/get-bounds.js} +7 -9
- package/lib/commonjs/utils/bounds/_utils/get-bounds.js.map +1 -0
- package/lib/commonjs/utils/bounds/_utils/is-bounds-equal.js +19 -0
- package/lib/commonjs/utils/bounds/_utils/is-bounds-equal.js.map +1 -0
- package/lib/commonjs/utils/bounds/_utils/style-composers.js +201 -0
- package/lib/commonjs/utils/bounds/_utils/style-composers.js.map +1 -0
- package/lib/commonjs/utils/bounds/constants.js +14 -3
- package/lib/commonjs/utils/bounds/constants.js.map +1 -1
- package/lib/commonjs/utils/bounds/index.js +210 -17
- package/lib/commonjs/utils/bounds/index.js.map +1 -1
- package/lib/commonjs/utils/gesture/apply-offset-rules.js +233 -0
- package/lib/commonjs/utils/gesture/apply-offset-rules.js.map +1 -0
- package/lib/commonjs/utils/gesture/check-gesture-activation.js +231 -0
- package/lib/commonjs/utils/gesture/check-gesture-activation.js.map +1 -0
- package/lib/commonjs/utils/gesture/determine-dismissal.js +98 -0
- package/lib/commonjs/utils/gesture/determine-dismissal.js.map +1 -0
- package/lib/module/components/{bounds-activator.js → bound-capture.js} +2 -2
- package/lib/module/components/bound-capture.js.map +1 -0
- package/lib/module/components/controllers/screen-lifecycle.js +18 -4
- package/lib/module/components/controllers/screen-lifecycle.js.map +1 -1
- package/lib/module/components/create-transition-aware-component.js +14 -12
- package/lib/module/components/create-transition-aware-component.js.map +1 -1
- package/lib/module/components/integrations/masked-view.js +48 -0
- package/lib/module/components/integrations/masked-view.js.map +1 -0
- package/lib/module/components/root-transition-aware.js +7 -16
- package/lib/module/components/root-transition-aware.js.map +1 -1
- package/lib/module/configs/index.js +15 -2
- package/lib/module/configs/index.js.map +1 -1
- package/lib/module/configs/presets.js +374 -6
- package/lib/module/configs/presets.js.map +1 -1
- package/lib/module/configs/specs.js +1 -1
- package/lib/module/hooks/animation/use-associated-style.js +6 -10
- package/lib/module/hooks/animation/use-associated-style.js.map +1 -1
- package/lib/module/hooks/animation/use-screen-animation.js +37 -37
- package/lib/module/hooks/animation/use-screen-animation.js.map +1 -1
- package/lib/module/hooks/bounds/use-bound-registry.js +68 -0
- package/lib/module/hooks/bounds/use-bound-registry.js.map +1 -0
- package/lib/module/hooks/gestures/use-build-gestures.js +156 -153
- package/lib/module/hooks/gestures/use-build-gestures.js.map +1 -1
- package/lib/module/hooks/gestures/use-parent-gesture-registry.js +23 -0
- package/lib/module/hooks/gestures/use-parent-gesture-registry.js.map +1 -0
- package/lib/module/hooks/gestures/use-scroll-registry.js +140 -0
- package/lib/module/hooks/gestures/use-scroll-registry.js.map +1 -0
- package/lib/module/index.js +2 -0
- package/lib/module/index.js.map +1 -1
- package/lib/module/integrations/native-stack/views/NativeStackView.native.js +7 -4
- package/lib/module/integrations/native-stack/views/NativeStackView.native.js.map +1 -1
- package/lib/module/providers/gestures.js +16 -16
- package/lib/module/providers/gestures.js.map +1 -1
- package/lib/module/providers/transition-styles.js +39 -0
- package/lib/module/providers/transition-styles.js.map +1 -0
- package/lib/module/stores/bounds.js +142 -1
- package/lib/module/stores/bounds.js.map +1 -1
- package/lib/module/stores/utils/reset-stores-for-screen.js +4 -2
- package/lib/module/stores/utils/reset-stores-for-screen.js.map +1 -1
- package/lib/module/types/gesture.js +7 -0
- package/lib/module/types/gesture.js.map +1 -1
- package/lib/module/utils/animation/derivations.js +34 -0
- package/lib/module/utils/animation/derivations.js.map +1 -0
- package/lib/module/utils/animation/run-transition.js +6 -2
- package/lib/module/utils/animation/run-transition.js.map +1 -1
- package/lib/module/utils/bounds/_utils/flatten-styles.js.map +1 -0
- package/lib/module/utils/bounds/_utils/geometry.js +174 -0
- package/lib/module/utils/bounds/_utils/geometry.js.map +1 -0
- package/lib/module/utils/bounds/{get-bounds.js → _utils/get-bounds.js} +7 -9
- package/lib/module/utils/bounds/_utils/get-bounds.js.map +1 -0
- package/lib/module/utils/bounds/_utils/is-bounds-equal.js +14 -0
- package/lib/module/utils/bounds/_utils/is-bounds-equal.js.map +1 -0
- package/lib/module/utils/bounds/_utils/style-composers.js +194 -0
- package/lib/module/utils/bounds/_utils/style-composers.js.map +1 -0
- package/lib/module/utils/bounds/constants.js +14 -3
- package/lib/module/utils/bounds/constants.js.map +1 -1
- package/lib/module/utils/bounds/index.js +208 -15
- package/lib/module/utils/bounds/index.js.map +1 -1
- package/lib/module/utils/gesture/apply-offset-rules.js +228 -0
- package/lib/module/utils/gesture/apply-offset-rules.js.map +1 -0
- package/lib/module/utils/gesture/check-gesture-activation.js +226 -0
- package/lib/module/utils/gesture/check-gesture-activation.js.map +1 -0
- package/lib/module/utils/gesture/determine-dismissal.js +93 -0
- package/lib/module/utils/gesture/determine-dismissal.js.map +1 -0
- package/lib/typescript/components/bound-capture.d.ts +8 -0
- package/lib/typescript/components/bound-capture.d.ts.map +1 -0
- package/lib/typescript/components/controllers/screen-lifecycle.d.ts.map +1 -1
- package/lib/typescript/components/create-transition-aware-component.d.ts.map +1 -1
- package/lib/typescript/components/integrations/masked-view.d.ts +6 -0
- package/lib/typescript/components/integrations/masked-view.d.ts.map +1 -0
- package/lib/typescript/components/root-transition-aware.d.ts +3 -3
- package/lib/typescript/components/root-transition-aware.d.ts.map +1 -1
- package/lib/typescript/configs/index.d.ts +15 -2
- package/lib/typescript/configs/index.d.ts.map +1 -1
- package/lib/typescript/configs/presets.d.ts +3 -0
- package/lib/typescript/configs/presets.d.ts.map +1 -1
- package/lib/typescript/hooks/animation/use-associated-style.d.ts +6 -4
- package/lib/typescript/hooks/animation/use-associated-style.d.ts.map +1 -1
- package/lib/typescript/hooks/animation/use-screen-animation.d.ts.map +1 -1
- package/lib/typescript/hooks/bounds/{use-bound-measurer.d.ts → use-bound-registry.d.ts} +5 -4
- package/lib/typescript/hooks/bounds/{use-bound-measurer.d.ts.map → use-bound-registry.d.ts.map} +1 -1
- package/lib/typescript/hooks/gestures/use-build-gestures.d.ts +6 -5
- package/lib/typescript/hooks/gestures/use-build-gestures.d.ts.map +1 -1
- package/lib/typescript/hooks/gestures/use-parent-gesture-registry.d.ts +6 -0
- package/lib/typescript/hooks/gestures/use-parent-gesture-registry.d.ts.map +1 -0
- package/lib/typescript/hooks/gestures/{use-scroll-progress.d.ts → use-scroll-registry.d.ts} +2 -2
- package/lib/typescript/hooks/gestures/use-scroll-registry.d.ts.map +1 -0
- package/lib/typescript/index.d.ts +25 -11
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/integrations/native-stack/views/NativeStackView.native.d.ts.map +1 -1
- package/lib/typescript/providers/gestures.d.ts +4 -2
- package/lib/typescript/providers/gestures.d.ts.map +1 -1
- package/lib/typescript/providers/transition-styles.d.ts +8 -0
- package/lib/typescript/providers/transition-styles.d.ts.map +1 -0
- package/lib/typescript/stores/bounds.d.ts +11 -0
- package/lib/typescript/stores/bounds.d.ts.map +1 -1
- package/lib/typescript/stores/utils/reset-stores-for-screen.d.ts +3 -1
- package/lib/typescript/stores/utils/reset-stores-for-screen.d.ts.map +1 -1
- package/lib/typescript/types/bounds.d.ts +5 -1
- package/lib/typescript/types/bounds.d.ts.map +1 -1
- package/lib/typescript/types/gesture.d.ts +14 -0
- package/lib/typescript/types/gesture.d.ts.map +1 -1
- package/lib/typescript/types/navigator.d.ts +5 -1
- package/lib/typescript/types/navigator.d.ts.map +1 -1
- package/lib/typescript/utils/animation/derivations.d.ts +19 -0
- package/lib/typescript/utils/animation/derivations.d.ts.map +1 -0
- package/lib/typescript/utils/animation/run-transition.d.ts +2 -1
- package/lib/typescript/utils/animation/run-transition.d.ts.map +1 -1
- package/lib/typescript/utils/bounds/_types/builder.d.ts +96 -14
- package/lib/typescript/utils/bounds/_types/builder.d.ts.map +1 -1
- package/lib/typescript/utils/bounds/_types/geometry.d.ts +0 -1
- package/lib/typescript/utils/bounds/_types/geometry.d.ts.map +1 -1
- package/lib/typescript/utils/bounds/_utils/flatten-styles.d.ts.map +1 -0
- package/lib/typescript/utils/bounds/{geometry.d.ts → _utils/geometry.d.ts} +8 -5
- package/lib/typescript/utils/bounds/_utils/geometry.d.ts.map +1 -0
- package/lib/typescript/utils/bounds/_utils/get-bounds.d.ts +4 -0
- package/lib/typescript/utils/bounds/_utils/get-bounds.d.ts.map +1 -0
- package/lib/typescript/utils/bounds/_utils/is-bounds-equal.d.ts +7 -0
- package/lib/typescript/utils/bounds/_utils/is-bounds-equal.d.ts.map +1 -0
- package/lib/typescript/utils/bounds/{style-composers.d.ts → _utils/style-composers.d.ts} +7 -10
- package/lib/typescript/utils/bounds/_utils/style-composers.d.ts.map +1 -0
- package/lib/typescript/utils/bounds/constants.d.ts +5 -5
- package/lib/typescript/utils/bounds/constants.d.ts.map +1 -1
- package/lib/typescript/utils/bounds/index.d.ts +2 -4
- package/lib/typescript/utils/bounds/index.d.ts.map +1 -1
- package/lib/typescript/utils/gesture/apply-offset-rules.d.ts +38 -0
- package/lib/typescript/utils/gesture/apply-offset-rules.d.ts.map +1 -0
- package/lib/typescript/utils/gesture/check-gesture-activation.d.ts +38 -0
- package/lib/typescript/utils/gesture/check-gesture-activation.d.ts.map +1 -0
- package/lib/typescript/utils/gesture/determine-dismissal.d.ts +25 -0
- package/lib/typescript/utils/gesture/determine-dismissal.d.ts.map +1 -0
- package/package.json +2 -3
- package/src/__tests__/geometry.test.ts +15 -12
- package/src/components/{bounds-activator.tsx → bound-capture.tsx} +1 -1
- package/src/components/controllers/screen-lifecycle.tsx +13 -5
- package/src/components/create-transition-aware-component.tsx +17 -11
- package/src/components/integrations/masked-view.tsx +56 -0
- package/src/components/root-transition-aware.tsx +31 -39
- package/src/configs/index.ts +26 -2
- package/src/configs/presets.ts +401 -6
- package/src/configs/specs.ts +1 -1
- package/src/hooks/animation/use-associated-style.tsx +12 -11
- package/src/hooks/animation/use-screen-animation.tsx +48 -49
- package/src/hooks/bounds/{use-bound-measurer.tsx → use-bound-registry.tsx} +32 -20
- package/src/hooks/gestures/use-build-gestures.tsx +193 -228
- package/src/hooks/gestures/use-parent-gesture-registry.tsx +18 -0
- package/src/hooks/gestures/use-scroll-registry.tsx +145 -0
- package/src/index.ts +2 -0
- package/src/integrations/native-stack/views/NativeStackView.native.tsx +8 -5
- package/src/providers/gestures.tsx +19 -22
- package/src/providers/transition-styles.tsx +52 -0
- package/src/stores/bounds.ts +156 -0
- package/src/stores/utils/reset-stores-for-screen.ts +7 -2
- package/src/types/bounds.ts +8 -1
- package/src/types/gesture.ts +19 -0
- package/src/types/navigator.ts +5 -1
- package/src/utils/animation/derivations.ts +38 -0
- package/src/utils/animation/run-transition.ts +4 -1
- package/src/utils/bounds/_types/builder.ts +127 -11
- package/src/utils/bounds/_types/geometry.ts +0 -1
- package/src/utils/bounds/_utils/geometry.ts +166 -0
- package/src/utils/bounds/_utils/get-bounds.ts +54 -0
- package/src/utils/bounds/_utils/is-bounds-equal.ts +24 -0
- package/src/utils/bounds/_utils/style-composers.ts +216 -0
- package/src/utils/bounds/constants.ts +37 -22
- package/src/utils/bounds/index.ts +269 -19
- package/src/utils/gesture/apply-offset-rules.ts +314 -0
- package/src/utils/gesture/check-gesture-activation.ts +310 -0
- package/src/utils/gesture/determine-dismissal.ts +131 -0
- package/lib/commonjs/components/bounds-activator.js.map +0 -1
- package/lib/commonjs/hooks/bounds/use-bound-measurer.js +0 -52
- package/lib/commonjs/hooks/bounds/use-bound-measurer.js.map +0 -1
- package/lib/commonjs/hooks/gestures/use-scroll-progress.js +0 -57
- package/lib/commonjs/hooks/gestures/use-scroll-progress.js.map +0 -1
- package/lib/commonjs/utils/bounds/build-bound-styles.js +0 -145
- package/lib/commonjs/utils/bounds/build-bound-styles.js.map +0 -1
- package/lib/commonjs/utils/bounds/flatten-styles.js.map +0 -1
- package/lib/commonjs/utils/bounds/geometry.js +0 -94
- package/lib/commonjs/utils/bounds/geometry.js.map +0 -1
- package/lib/commonjs/utils/bounds/get-bounds.js.map +0 -1
- package/lib/commonjs/utils/bounds/style-composers.js +0 -199
- package/lib/commonjs/utils/bounds/style-composers.js.map +0 -1
- package/lib/commonjs/utils/gesture/apply-gesture-activation-criteria.js +0 -81
- package/lib/commonjs/utils/gesture/apply-gesture-activation-criteria.js.map +0 -1
- package/lib/commonjs/utils/gesture/normalize-gesture-translation.js +0 -21
- package/lib/commonjs/utils/gesture/normalize-gesture-translation.js.map +0 -1
- package/lib/commonjs/utils/index.js +0 -17
- package/lib/commonjs/utils/index.js.map +0 -1
- package/lib/module/components/bounds-activator.js.map +0 -1
- package/lib/module/hooks/bounds/use-bound-measurer.js +0 -47
- package/lib/module/hooks/bounds/use-bound-measurer.js.map +0 -1
- package/lib/module/hooks/gestures/use-scroll-progress.js +0 -52
- package/lib/module/hooks/gestures/use-scroll-progress.js.map +0 -1
- package/lib/module/utils/bounds/build-bound-styles.js +0 -141
- package/lib/module/utils/bounds/build-bound-styles.js.map +0 -1
- package/lib/module/utils/bounds/flatten-styles.js.map +0 -1
- package/lib/module/utils/bounds/geometry.js +0 -89
- package/lib/module/utils/bounds/geometry.js.map +0 -1
- package/lib/module/utils/bounds/get-bounds.js.map +0 -1
- package/lib/module/utils/bounds/style-composers.js +0 -191
- package/lib/module/utils/bounds/style-composers.js.map +0 -1
- package/lib/module/utils/gesture/apply-gesture-activation-criteria.js +0 -76
- package/lib/module/utils/gesture/apply-gesture-activation-criteria.js.map +0 -1
- package/lib/module/utils/gesture/normalize-gesture-translation.js +0 -16
- package/lib/module/utils/gesture/normalize-gesture-translation.js.map +0 -1
- package/lib/module/utils/index.js +0 -4
- package/lib/module/utils/index.js.map +0 -1
- package/lib/typescript/components/bounds-activator.d.ts +0 -8
- package/lib/typescript/components/bounds-activator.d.ts.map +0 -1
- package/lib/typescript/hooks/gestures/use-scroll-progress.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/build-bound-styles.d.ts +0 -4
- package/lib/typescript/utils/bounds/build-bound-styles.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/flatten-styles.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/geometry.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/get-bounds.d.ts +0 -4
- package/lib/typescript/utils/bounds/get-bounds.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/style-composers.d.ts.map +0 -1
- package/lib/typescript/utils/gesture/apply-gesture-activation-criteria.d.ts +0 -17
- package/lib/typescript/utils/gesture/apply-gesture-activation-criteria.d.ts.map +0 -1
- package/lib/typescript/utils/gesture/normalize-gesture-translation.d.ts +0 -6
- package/lib/typescript/utils/gesture/normalize-gesture-translation.d.ts.map +0 -1
- package/lib/typescript/utils/index.d.ts +0 -2
- package/lib/typescript/utils/index.d.ts.map +0 -1
- package/src/hooks/gestures/use-scroll-progress.tsx +0 -60
- package/src/utils/bounds/build-bound-styles.ts +0 -184
- package/src/utils/bounds/geometry.ts +0 -113
- package/src/utils/bounds/get-bounds.ts +0 -56
- package/src/utils/bounds/style-composers.ts +0 -172
- package/src/utils/gesture/apply-gesture-activation-criteria.ts +0 -109
- package/src/utils/gesture/normalize-gesture-translation.ts +0 -20
- package/src/utils/index.ts +0 -1
- /package/lib/commonjs/utils/bounds/{flatten-styles.js → _utils/flatten-styles.js} +0 -0
- /package/lib/module/utils/bounds/{flatten-styles.js → _utils/flatten-styles.js} +0 -0
- /package/lib/typescript/utils/bounds/{flatten-styles.d.ts → _utils/flatten-styles.d.ts} +0 -0
- /package/src/utils/bounds/{flatten-styles.ts → _utils/flatten-styles.ts} +0 -0
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
import { DraggableCard, ElasticCard, SharedAppleMusic, SharedIGImage, SharedXImage, SlideFromBottom, SlideFromTop, ZoomIn } from "./presets";
|
|
4
|
+
import { DefaultSpec } from "./specs";
|
|
5
|
+
export const specs = {
|
|
6
|
+
DefaultSpec
|
|
7
|
+
};
|
|
8
|
+
export const presets = {
|
|
9
|
+
SlideFromTop,
|
|
10
|
+
ZoomIn,
|
|
11
|
+
SlideFromBottom,
|
|
12
|
+
DraggableCard,
|
|
13
|
+
ElasticCard,
|
|
14
|
+
SharedIGImage,
|
|
15
|
+
SharedAppleMusic,
|
|
16
|
+
SharedXImage
|
|
17
|
+
};
|
|
5
18
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["DraggableCard","ElasticCard","SharedAppleMusic","SharedIGImage","SharedXImage","SlideFromBottom","SlideFromTop","ZoomIn","DefaultSpec","specs","presets"],"sourceRoot":"../../../src","sources":["configs/index.ts"],"mappings":";;AAAA,SACCA,aAAa,EACbC,WAAW,EACXC,gBAAgB,EAChBC,aAAa,EACbC,YAAY,EACZC,eAAe,EACfC,YAAY,EACZC,MAAM,QACA,WAAW;AAClB,SAASC,WAAW,QAAQ,SAAS;AAErC,OAAO,MAAMC,KAAK,GAAG;EACpBD;AACD,CAAC;AAED,OAAO,MAAME,OAAO,GAAG;EACtBJ,YAAY;EACZC,MAAM;EACNF,eAAe;EACfL,aAAa;EACbC,WAAW;EACXE,aAAa;EACbD,gBAAgB;EAChBE;AACD,CAAC","ignoreList":[]}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
import { Platform } from "react-native";
|
|
3
4
|
import { Extrapolation, interpolate, interpolateColor } from "react-native-reanimated";
|
|
4
5
|
import { DefaultSpec } from "./specs";
|
|
6
|
+
const platform = Platform.OS;
|
|
5
7
|
export const SlideFromTop = (config = {}) => {
|
|
6
8
|
return {
|
|
7
9
|
enableTransitions: true,
|
|
@@ -160,17 +162,13 @@ export const ElasticCard = (config = {
|
|
|
160
162
|
*/
|
|
161
163
|
const scale = interpolate(progress, [0, 1, 2], [0, 1, 0.8]);
|
|
162
164
|
|
|
163
|
-
|
|
164
|
-
* Applies to current screen
|
|
165
|
-
*/
|
|
165
|
+
// applies to current screen
|
|
166
166
|
const maxElasticityX = screen.width * (config.elasticFactor ?? 0.5);
|
|
167
167
|
const maxElasticityY = screen.height * (config.elasticFactor ?? 0.5);
|
|
168
168
|
const translateX = interpolate(current.gesture.normalizedX, [-1, 0, 1], [-maxElasticityX, 0, maxElasticityX], "clamp");
|
|
169
169
|
const translateY = interpolate(current.gesture.normalizedY, [-1, 0, 1], [-maxElasticityY, 0, maxElasticityY], "clamp");
|
|
170
170
|
|
|
171
|
-
|
|
172
|
-
* Applies to unfocused screen ( previous screen )
|
|
173
|
-
*/
|
|
171
|
+
// applies to unfocused screen ( previous screen )
|
|
174
172
|
const overlayColor = interpolateColor(progress, [0, 1], ["rgba(0,0,0,0)", "rgba(0,0,0,0.5)"]);
|
|
175
173
|
return {
|
|
176
174
|
contentStyle: {
|
|
@@ -194,4 +192,374 @@ export const ElasticCard = (config = {
|
|
|
194
192
|
...config
|
|
195
193
|
};
|
|
196
194
|
};
|
|
195
|
+
export const SharedIGImage = (config = {}) => {
|
|
196
|
+
return {
|
|
197
|
+
gestureEnabled: true,
|
|
198
|
+
gestureDirection: ["vertical", "horizontal"],
|
|
199
|
+
enableTransitions: true,
|
|
200
|
+
gestureDrivesProgress: false,
|
|
201
|
+
screenStyleInterpolator: ({
|
|
202
|
+
current,
|
|
203
|
+
layouts: {
|
|
204
|
+
screen: {
|
|
205
|
+
height,
|
|
206
|
+
width
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
bounds,
|
|
210
|
+
progress,
|
|
211
|
+
focused,
|
|
212
|
+
activeBoundId,
|
|
213
|
+
next
|
|
214
|
+
}) => {
|
|
215
|
+
"worklet";
|
|
216
|
+
|
|
217
|
+
const normX = focused ? current.gesture.normalizedX : next?.gesture.normalizedX ?? 0;
|
|
218
|
+
const normY = focused ? current.gesture.normalizedY : next?.gesture.normalizedY ?? 0;
|
|
219
|
+
|
|
220
|
+
// animations for both bounds
|
|
221
|
+
const dragX = interpolate(normX, [-1, 0, 1], [-width * 0.7, 0, width * 0.7]);
|
|
222
|
+
const dragY = interpolate(normY, [-1, 0, 1], [-height * 0.4, 0, height * 0.4]);
|
|
223
|
+
const dragXScale = interpolate(normX, [0, 1], [1, 0.8]);
|
|
224
|
+
const dragYScale = interpolate(normY, [0, 1], [1, 0.8]);
|
|
225
|
+
const boundValues = bounds({
|
|
226
|
+
method: focused ? "content" : "transform",
|
|
227
|
+
scaleMode: "uniform",
|
|
228
|
+
raw: true
|
|
229
|
+
});
|
|
230
|
+
|
|
231
|
+
// focused specific animations
|
|
232
|
+
if (focused) {
|
|
233
|
+
const maskedValues = bounds({
|
|
234
|
+
space: "absolute",
|
|
235
|
+
target: "fullscreen",
|
|
236
|
+
method: "size",
|
|
237
|
+
raw: true
|
|
238
|
+
});
|
|
239
|
+
return {
|
|
240
|
+
overlayStyle: {
|
|
241
|
+
backgroundColor: "black",
|
|
242
|
+
opacity: interpolate(progress, [0, 1], [0, 0.5])
|
|
243
|
+
},
|
|
244
|
+
contentStyle: {
|
|
245
|
+
transform: [{
|
|
246
|
+
translateX: dragX
|
|
247
|
+
}, {
|
|
248
|
+
translateY: dragY
|
|
249
|
+
}, {
|
|
250
|
+
scale: dragXScale
|
|
251
|
+
}, {
|
|
252
|
+
scale: dragYScale
|
|
253
|
+
}]
|
|
254
|
+
},
|
|
255
|
+
_ROOT_CONTAINER: {
|
|
256
|
+
transform: [{
|
|
257
|
+
translateX: boundValues.translateX || 0
|
|
258
|
+
}, {
|
|
259
|
+
translateY: boundValues.translateY || 0
|
|
260
|
+
},
|
|
261
|
+
//@ts-expect-error
|
|
262
|
+
{
|
|
263
|
+
scale: boundValues.scale || 1
|
|
264
|
+
}]
|
|
265
|
+
},
|
|
266
|
+
_ROOT_MASKED: {
|
|
267
|
+
width: maskedValues.width,
|
|
268
|
+
height: maskedValues.height,
|
|
269
|
+
transform: [{
|
|
270
|
+
translateX: maskedValues.translateX || 0
|
|
271
|
+
}, {
|
|
272
|
+
translateY: maskedValues.translateY || 0
|
|
273
|
+
}],
|
|
274
|
+
borderRadius: interpolate(progress, [0, 1], [0, 24])
|
|
275
|
+
}
|
|
276
|
+
};
|
|
277
|
+
}
|
|
278
|
+
return {
|
|
279
|
+
contentStyle: {
|
|
280
|
+
pointerEvents: current.gesture.isDismissing ? "none" : "auto"
|
|
281
|
+
},
|
|
282
|
+
[activeBoundId]: {
|
|
283
|
+
transform: [{
|
|
284
|
+
translateX: dragX || 0
|
|
285
|
+
}, {
|
|
286
|
+
translateY: dragY || 0
|
|
287
|
+
}, {
|
|
288
|
+
translateX: boundValues.translateX || 0
|
|
289
|
+
}, {
|
|
290
|
+
translateY: boundValues.translateY || 0
|
|
291
|
+
}, {
|
|
292
|
+
scaleX: boundValues.scaleX || 1
|
|
293
|
+
}, {
|
|
294
|
+
scaleY: boundValues.scaleY || 1
|
|
295
|
+
}, {
|
|
296
|
+
scale: dragXScale
|
|
297
|
+
}, {
|
|
298
|
+
scale: dragYScale
|
|
299
|
+
}]
|
|
300
|
+
}
|
|
301
|
+
};
|
|
302
|
+
},
|
|
303
|
+
transitionSpec: {
|
|
304
|
+
open: {
|
|
305
|
+
stiffness: 1500,
|
|
306
|
+
damping: 1000,
|
|
307
|
+
mass: 3,
|
|
308
|
+
overshootClamping: true,
|
|
309
|
+
restSpeedThreshold: 0.02
|
|
310
|
+
},
|
|
311
|
+
close: {
|
|
312
|
+
stiffness: 1500,
|
|
313
|
+
damping: 1000,
|
|
314
|
+
mass: 3,
|
|
315
|
+
overshootClamping: true,
|
|
316
|
+
restSpeedThreshold: 0.02
|
|
317
|
+
}
|
|
318
|
+
},
|
|
319
|
+
...config
|
|
320
|
+
};
|
|
321
|
+
};
|
|
322
|
+
export const SharedAppleMusic = (config = {}) => {
|
|
323
|
+
return {
|
|
324
|
+
enableTransitions: true,
|
|
325
|
+
gestureEnabled: true,
|
|
326
|
+
gestureDirection: ["vertical", "horizontal"],
|
|
327
|
+
gestureDrivesProgress: false,
|
|
328
|
+
screenStyleInterpolator: ({
|
|
329
|
+
bounds,
|
|
330
|
+
activeBoundId,
|
|
331
|
+
focused,
|
|
332
|
+
progress,
|
|
333
|
+
layouts: {
|
|
334
|
+
screen
|
|
335
|
+
},
|
|
336
|
+
current,
|
|
337
|
+
next
|
|
338
|
+
}) => {
|
|
339
|
+
"worklet";
|
|
340
|
+
|
|
341
|
+
const normX = focused ? current.gesture.normalizedX : next?.gesture.normalizedX ?? 0;
|
|
342
|
+
const normY = focused ? current.gesture.normalizedY : next?.gesture.normalizedY ?? 0;
|
|
343
|
+
|
|
344
|
+
/**
|
|
345
|
+
* ===============================
|
|
346
|
+
* Animations for both bounds
|
|
347
|
+
* ===============================
|
|
348
|
+
*/
|
|
349
|
+
const dragX = interpolate(normX, [0, 1], [0, screen.width * 0.8]);
|
|
350
|
+
const dragY = interpolate(normY, [0, 1], [0, screen.height * 0.8]);
|
|
351
|
+
const dragXScale = interpolate(normX, [0, 1], [1, 0.75]);
|
|
352
|
+
const dragYScale = interpolate(normY, [0, 1], [1, 0.75]);
|
|
353
|
+
const boundValues = bounds({
|
|
354
|
+
method: focused ? "content" : "transform",
|
|
355
|
+
anchor: "top",
|
|
356
|
+
scaleMode: "uniform",
|
|
357
|
+
raw: true
|
|
358
|
+
});
|
|
359
|
+
const opacity = interpolate(progress, [0, 0.35, 1, 1.25, 2], [0, 1, 1, 1, 0], "clamp");
|
|
360
|
+
|
|
361
|
+
/**
|
|
362
|
+
* ===============================
|
|
363
|
+
* Focused specific animations
|
|
364
|
+
* ===============================
|
|
365
|
+
*/
|
|
366
|
+
if (focused) {
|
|
367
|
+
const maskedValues = bounds({
|
|
368
|
+
space: "absolute",
|
|
369
|
+
method: "size",
|
|
370
|
+
target: "fullscreen",
|
|
371
|
+
raw: true
|
|
372
|
+
});
|
|
373
|
+
|
|
374
|
+
// Apple Music style drop shadow that increases with drag magnitude
|
|
375
|
+
const dragMagnitude = Math.max(Math.abs(normX), Math.abs(normY));
|
|
376
|
+
const shadowOpacity = interpolate(dragMagnitude, [0, 1], [0, 0.25], "clamp");
|
|
377
|
+
const shadowRadius = interpolate(dragMagnitude, [0, 1], [0, 24], "clamp");
|
|
378
|
+
const shadowOffsetY = interpolate(dragMagnitude, [0, 1], [0, 20], "clamp");
|
|
379
|
+
const elevation = interpolate(dragMagnitude, [0, 1], [0, 24], "clamp");
|
|
380
|
+
const IOSShadowStyle = {
|
|
381
|
+
shadowColor: "#000",
|
|
382
|
+
shadowOpacity,
|
|
383
|
+
shadowRadius,
|
|
384
|
+
shadowOffset: {
|
|
385
|
+
width: 0,
|
|
386
|
+
height: shadowOffsetY
|
|
387
|
+
}
|
|
388
|
+
};
|
|
389
|
+
const AndroidShadowStyle = {
|
|
390
|
+
elevation,
|
|
391
|
+
shadowColor: "#000"
|
|
392
|
+
};
|
|
393
|
+
return {
|
|
394
|
+
contentStyle: {
|
|
395
|
+
pointerEvents: current.animating ? "none" : "auto",
|
|
396
|
+
transform: [{
|
|
397
|
+
translateX: dragX || 0
|
|
398
|
+
}, {
|
|
399
|
+
translateY: dragY || 0
|
|
400
|
+
}, {
|
|
401
|
+
scale: dragXScale
|
|
402
|
+
}, {
|
|
403
|
+
scale: dragYScale
|
|
404
|
+
}],
|
|
405
|
+
opacity,
|
|
406
|
+
...(platform === "ios" ? IOSShadowStyle : AndroidShadowStyle)
|
|
407
|
+
},
|
|
408
|
+
_ROOT_CONTAINER: {
|
|
409
|
+
transform: [{
|
|
410
|
+
translateX: boundValues.translateX || 0
|
|
411
|
+
}, {
|
|
412
|
+
translateY: boundValues.translateY || 0
|
|
413
|
+
},
|
|
414
|
+
//@ts-expect-error
|
|
415
|
+
{
|
|
416
|
+
scale: boundValues.scale || 1
|
|
417
|
+
}]
|
|
418
|
+
},
|
|
419
|
+
_ROOT_MASKED: {
|
|
420
|
+
width: maskedValues.width,
|
|
421
|
+
height: maskedValues.height,
|
|
422
|
+
transform: [{
|
|
423
|
+
translateX: maskedValues.translateX || 0
|
|
424
|
+
}, {
|
|
425
|
+
translateY: maskedValues.translateY || 0
|
|
426
|
+
}],
|
|
427
|
+
borderRadius: interpolate(progress, [0, 1], [0, 24])
|
|
428
|
+
}
|
|
429
|
+
};
|
|
430
|
+
}
|
|
431
|
+
|
|
432
|
+
/**
|
|
433
|
+
* ===============================
|
|
434
|
+
* Unfocused specific animations
|
|
435
|
+
* ===============================
|
|
436
|
+
*/
|
|
437
|
+
|
|
438
|
+
const scaledBoundTranslateX = (boundValues.translateX || 0) * dragXScale;
|
|
439
|
+
const scaledBoundTranslateY = (boundValues.translateY || 0) * dragYScale;
|
|
440
|
+
const scaledBoundScaleX = (boundValues.scaleX || 1) * dragXScale;
|
|
441
|
+
const scaledBoundScaleY = (boundValues.scaleY || 1) * dragYScale;
|
|
442
|
+
const contentScale = interpolate(progress, [1, 2], [1, 0.9], "clamp");
|
|
443
|
+
return {
|
|
444
|
+
[activeBoundId]: {
|
|
445
|
+
transform: [{
|
|
446
|
+
translateX: dragX || 0
|
|
447
|
+
}, {
|
|
448
|
+
translateY: dragY || 0
|
|
449
|
+
}, {
|
|
450
|
+
translateX: scaledBoundTranslateX
|
|
451
|
+
}, {
|
|
452
|
+
translateY: scaledBoundTranslateY
|
|
453
|
+
}, {
|
|
454
|
+
scale: dragXScale
|
|
455
|
+
}, {
|
|
456
|
+
scale: dragYScale
|
|
457
|
+
}, {
|
|
458
|
+
scaleX: scaledBoundScaleX
|
|
459
|
+
}, {
|
|
460
|
+
scaleY: scaledBoundScaleY
|
|
461
|
+
}],
|
|
462
|
+
opacity,
|
|
463
|
+
zIndex: current.animating ? 999 : -1,
|
|
464
|
+
position: "relative"
|
|
465
|
+
},
|
|
466
|
+
contentStyle: {
|
|
467
|
+
transform: [{
|
|
468
|
+
scale: contentScale
|
|
469
|
+
}]
|
|
470
|
+
}
|
|
471
|
+
};
|
|
472
|
+
},
|
|
473
|
+
transitionSpec: {
|
|
474
|
+
open: {
|
|
475
|
+
stiffness: 1000,
|
|
476
|
+
damping: 500,
|
|
477
|
+
mass: 3,
|
|
478
|
+
overshootClamping: true,
|
|
479
|
+
restSpeedThreshold: 0.02
|
|
480
|
+
},
|
|
481
|
+
close: {
|
|
482
|
+
stiffness: 600,
|
|
483
|
+
damping: 60,
|
|
484
|
+
mass: 3,
|
|
485
|
+
overshootClamping: false,
|
|
486
|
+
restSpeedThreshold: 0.02,
|
|
487
|
+
restDisplacementThreshold: 0.002
|
|
488
|
+
}
|
|
489
|
+
},
|
|
490
|
+
...config
|
|
491
|
+
};
|
|
492
|
+
};
|
|
493
|
+
export const SharedXImage = (config = {}) => {
|
|
494
|
+
return {
|
|
495
|
+
enableTransitions: true,
|
|
496
|
+
gestureEnabled: true,
|
|
497
|
+
gestureDirection: ["vertical", "vertical-inverted"],
|
|
498
|
+
gestureDrivesProgress: false,
|
|
499
|
+
screenStyleInterpolator: ({
|
|
500
|
+
focused,
|
|
501
|
+
activeBoundId,
|
|
502
|
+
bounds,
|
|
503
|
+
current,
|
|
504
|
+
layouts: {
|
|
505
|
+
screen
|
|
506
|
+
},
|
|
507
|
+
progress
|
|
508
|
+
}) => {
|
|
509
|
+
"worklet";
|
|
510
|
+
|
|
511
|
+
// twitter doesn't animate the unfocused screen
|
|
512
|
+
if (!focused) return {};
|
|
513
|
+
const boundValues = bounds({
|
|
514
|
+
method: "transform",
|
|
515
|
+
raw: true
|
|
516
|
+
});
|
|
517
|
+
|
|
518
|
+
// content styles
|
|
519
|
+
const dragY = interpolate(current.gesture.normalizedY, [-1, 0, 1], [-screen.height, 0, screen.height]);
|
|
520
|
+
|
|
521
|
+
// dynamically changes direction based on the drag direction
|
|
522
|
+
const contentY = interpolate(progress, [0, 1], [dragY >= 0 ? screen.height : -screen.height, 0]);
|
|
523
|
+
const overlayClr = interpolateColor(current.progress - Math.abs(current.gesture.normalizedY), [0, 1], ["rgba(0,0,0,0)", "rgba(0,0,0,1)"]);
|
|
524
|
+
const borderRadius = interpolate(current.progress, [0, 1], [12, 0]);
|
|
525
|
+
|
|
526
|
+
// bound styles - only enter animation
|
|
527
|
+
const x = !current.closing ? boundValues.translateX : 0;
|
|
528
|
+
const y = !current.closing ? boundValues.translateY : 0;
|
|
529
|
+
const scaleX = !current.closing ? boundValues.scaleX : 1;
|
|
530
|
+
const scaleY = !current.closing ? boundValues.scaleY : 1;
|
|
531
|
+
return {
|
|
532
|
+
[activeBoundId]: {
|
|
533
|
+
transform: [{
|
|
534
|
+
translateX: x
|
|
535
|
+
}, {
|
|
536
|
+
translateY: y
|
|
537
|
+
}, {
|
|
538
|
+
scaleX: scaleX
|
|
539
|
+
}, {
|
|
540
|
+
scaleY: scaleY
|
|
541
|
+
}],
|
|
542
|
+
borderRadius,
|
|
543
|
+
overflow: "hidden"
|
|
544
|
+
},
|
|
545
|
+
contentStyle: {
|
|
546
|
+
transform: [{
|
|
547
|
+
translateY: contentY
|
|
548
|
+
}, {
|
|
549
|
+
translateY: dragY
|
|
550
|
+
}],
|
|
551
|
+
pointerEvents: current.animating ? "none" : "auto"
|
|
552
|
+
},
|
|
553
|
+
overlayStyle: {
|
|
554
|
+
backgroundColor: overlayClr
|
|
555
|
+
}
|
|
556
|
+
};
|
|
557
|
+
},
|
|
558
|
+
transitionSpec: {
|
|
559
|
+
open: DefaultSpec,
|
|
560
|
+
close: DefaultSpec
|
|
561
|
+
},
|
|
562
|
+
...config
|
|
563
|
+
};
|
|
564
|
+
};
|
|
197
565
|
//# sourceMappingURL=presets.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Extrapolation","interpolate","interpolateColor","DefaultSpec","SlideFromTop","config","enableTransitions","gestureEnabled","gestureDirection","screenStyleInterpolator","current","next","layouts","screen","height","progress","y","contentStyle","transform","translateY","transitionSpec","open","close","ZoomIn","scale","CLAMP","opacity","SlideFromBottom","DraggableCard","gesture","normalizedY","translateX","normalizedX","width","ElasticCard","elasticFactor","maxElasticityX","maxElasticityY","overlayColor","overlayStyle","backgroundColor"],"sourceRoot":"../../../src","sources":["configs/presets.ts"],"mappings":";;AAAA,SACCA,aAAa,EACbC,WAAW,EACXC,gBAAgB,QACV,yBAAyB;AAEhC,SAASC,WAAW,QAAQ,SAAS;AAErC,OAAO,MAAMC,YAAY,GAAGA,CAC3BC,MAAuC,GAAG,CAAC,CAAC,KAChB;EAC5B,OAAO;IACNC,iBAAiB,EAAE,IAAI;IACvBC,cAAc,EAAE,IAAI;IACpBC,gBAAgB,EAAE,mBAAmB;IACrCC,uBAAuB,EAAEA,CAAC;MACzBC,OAAO;MACPC,IAAI;MACJC,OAAO,EAAE;QACRC,MAAM,EAAE;UAAEC;QAAO;MAClB;IACD,CAAC,KAAK;MACL,SAAS;;MAET,MAAMC,QAAQ,GAAGL,OAAO,CAACK,QAAQ,IAAIJ,IAAI,EAAEI,QAAQ,IAAI,CAAC,CAAC;MAEzD,MAAMC,CAAC,GAAGf,WAAW,CAACc,QAAQ,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAACD,MAAM,EAAE,CAAC,EAAEA,MAAM,CAAC,CAAC;MAEhE,OAAO;QACNG,YAAY,EAAE;UACbC,SAAS,EAAE,CAA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AC8B,aAAa,IAAI,GAAG,CAAC;MACpE,MAAMJ,UAAU,GAAG9B,WAAW,CAC7BS,OAAO,CAACmB,OAAO,CAACG,WAAW,EAC3B,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EACV,CAAC,CAACI,cAAc,EAAE,CAAC,EAAEA,cAAc,CAAC,EACpC,OACD,CAAC;MAED,MAAMjB,UAAU,GAAGlB,WAAW,CAC7BS,OAAO,CAACmB,OAAO,CAACC,WAAW,EAC3B,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EACV,CAAC,CAACO,cAAc,EAAE,CAAC,EAAEA,cAAc,CAAC,EACpC,OACD,CAAC;;MAED;AACH;AACA;MACG,MAAMC,YAAY,GAAGpC,gBAAgB,CACpCa,QAAQ,EACR,CAAC,CAAC,EAAE,CAAC,CAAC,EACN,CAAC,eAAe,EAAE,iBAAiB,CACpC,CAAC;MAED,OAAO;QACNE,YAAY,EAAE;UACbC,SAAS,EAAE,CAAC;YAAEM;UAAM,CAAC,EAAE;YAAEO;UAAW,CAAC,EAAE;YAAEZ;UAAW,CAAC;QACtD,CAAC;QACDoB,YAAY,EAAE;UACbC,eAAe,EAAE,CAAC7B,IAAI,GAAG2B,YAAY,GAAG;QACzC;MACD,CAAC;IACF,CAAC;IACDlB,cAAc,EAAE;MACfC,IAAI,EAAElB,WAAW;MACjBmB,KAAK,EAAEnB;IACR,CAAC;IACD,GAAGE;EACJ,CAAC;AACF,CAAC","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["Platform","Extrapolation","interpolate","interpolateColor","DefaultSpec","platform","OS","SlideFromTop","config","enableTransitions","gestureEnabled","gestureDirection","screenStyleInterpolator","current","next","layouts","screen","height","progress","y","contentStyle","transform","translateY","transitionSpec","open","close","ZoomIn","scale","CLAMP","opacity","SlideFromBottom","DraggableCard","gesture","normalizedY","translateX","normalizedX","width","ElasticCard","elasticFactor","maxElasticityX","maxElasticityY","overlayColor","overlayStyle","backgroundColor","SharedIGImage","gestureDrivesProgress","bounds","focused","activeBoundId","normX","normY","dragX","dragY","dragXScale","dragYScale","boundValues","method","scaleMode","raw","maskedValues","space","target","_ROOT_CONTAINER","_ROOT_MASKED","borderRadius","pointerEvents","isDismissing","scaleX","scaleY","stiffness","damping","mass","overshootClamping","restSpeedThreshold","SharedAppleMusic","anchor","dragMagnitude","Math","max","abs","shadowOpacity","shadowRadius","shadowOffsetY","elevation","IOSShadowStyle","shadowColor","shadowOffset","AndroidShadowStyle","animating","scaledBoundTranslateX","scaledBoundTranslateY","scaledBoundScaleX","scaledBoundScaleY","contentScale","zIndex","position","restDisplacementThreshold","SharedXImage","contentY","overlayClr","x","closing","overflow"],"sourceRoot":"../../../src","sources":["configs/presets.ts"],"mappings":";;AAAA,SAASA,QAAQ,QAAQ,cAAc;AACvC,SACCC,aAAa,EACbC,WAAW,EACXC,gBAAgB,QACV,yBAAyB;AAEhC,SAASC,WAAW,QAAQ,SAAS;AAErC,MAAMC,QAAQ,GAAGL,QAAQ,CAACM,EAAE;AAE5B,OAAO,MAAMC,YAAY,GAAGA,CAC3BC,MAAuC,GAAG,CAAC,CAAC,KAChB;EAC5B,OAAO;IACNC,iBAAiB,EAAE,IAAI;IACvBC,cAAc,EAAE,IAAI;IACpBC,gBAAgB,EAAE,mBAAmB;IACrCC,uBAAuB,EAAEA,CAAC;MACzBC,OAAO;MACPC,IAAI;MACJC,OAAO,EAAE;QACRC,MAAM,EAAE;UAAEC;QAAO;MAClB;IACD,CAAC,KAAK;MACL,SAAS;;MAET,MAAMC,QAAQ,GAAGL,OAAO,CAACK,QAAQ,IAAIJ,IAAI,EAAEI,QAAQ,IAAI,CAAC,CAAC;MAEzD,MAAMC,CAAC,GAAGjB,WAAW,CAACgB,QAAQ,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAACD,MAAM,EAAE,CAAC,EAAEA,MAAM,CAAC,CAAC;MAEhE,OAAO;QACNG,YAAY,EAA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";
|
|
2
2
|
|
|
3
3
|
import { useAnimatedStyle } from "react-native-reanimated";
|
|
4
|
-
import {
|
|
4
|
+
import { useTransitionStyles } from "../../providers/transition-styles";
|
|
5
|
+
const EMPTY_STYLE = Object.freeze({});
|
|
5
6
|
|
|
6
7
|
/**
|
|
7
8
|
* This hook is used to get the associated styles for a given styleId.
|
|
@@ -11,19 +12,14 @@ import { _useScreenAnimation } from "./use-screen-animation";
|
|
|
11
12
|
export const useAssociatedStyles = ({
|
|
12
13
|
id
|
|
13
14
|
} = {}) => {
|
|
14
|
-
const
|
|
15
|
-
screenStyleInterpolator,
|
|
16
|
-
screenInterpolatorProps
|
|
17
|
-
} = _useScreenAnimation();
|
|
15
|
+
const stylesMap = useTransitionStyles();
|
|
18
16
|
const associatedStyles = useAnimatedStyle(() => {
|
|
19
17
|
"worklet";
|
|
20
18
|
|
|
21
|
-
if (!id || !
|
|
22
|
-
return
|
|
19
|
+
if (!id || !stylesMap) {
|
|
20
|
+
return EMPTY_STYLE;
|
|
23
21
|
}
|
|
24
|
-
return
|
|
25
|
-
opacity: 1 // <-- This fixes flickering?? We'll have to deep dive this?? wtf
|
|
26
|
-
};
|
|
22
|
+
return stylesMap.value[id] || EMPTY_STYLE;
|
|
27
23
|
});
|
|
28
24
|
return {
|
|
29
25
|
associatedStyles
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useAnimatedStyle","
|
|
1
|
+
{"version":3,"names":["useAnimatedStyle","useTransitionStyles","EMPTY_STYLE","Object","freeze","useAssociatedStyles","id","stylesMap","associatedStyles","value"],"sourceRoot":"../../../../src","sources":["hooks/animation/use-associated-style.tsx"],"mappings":";;AAAA,SAASA,gBAAgB,QAAQ,yBAAyB;AAC1D,SAASC,mBAAmB,QAAQ,mCAAmC;AAMvE,MAAMC,WAAW,GAAGC,MAAM,CAACC,MAAM,CAAC,CAAC,CAAC,CAAC;;AAErC;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,mBAAmB,GAAGA,CAAC;EAAEC;AAAU,CAAC,GAAG,CAAC,CAAC,KAAK;EAC1D,MAAMC,SAAS,GAAGN,mBAAmB,CAAC,CAAC;EAEvC,MAAMO,gBAAgB,GAAGR,gBAAgB,CAAC,MAAM;IAC/C,SAAS;;IAET,IAAI,CAACM,EAAE,IAAI,CAACC,SAAS,EAAE;MACtB,OAAOL,WAAW;IACnB;IAEA,OAAOK,SAAS,CAACE,KAAK,CAACH,EAAE,CAAC,IAAIJ,WAAW;EAC1C,CAAC,CAAC;EAEF,OAAO;IAAEM;EAAiB,CAAC;AAC5B,CAAC","ignoreList":[]}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
import { useMemo } from "react";
|
|
3
4
|
import { useWindowDimensions } from "react-native";
|
|
4
5
|
import { useDerivedValue } from "react-native-reanimated";
|
|
5
6
|
import { useSafeAreaInsets } from "react-native-safe-area-context";
|
|
@@ -7,7 +8,8 @@ import { useKeys } from "../../providers/keys";
|
|
|
7
8
|
import { Animations } from "../../stores/animations";
|
|
8
9
|
import { Bounds } from "../../stores/bounds";
|
|
9
10
|
import { Gestures } from "../../stores/gestures";
|
|
10
|
-
import {
|
|
11
|
+
import { derivations } from "../../utils/animation/derivations";
|
|
12
|
+
const EMPTY_BOUNDS = Object.freeze({});
|
|
11
13
|
const FALLBACK = Object.freeze({
|
|
12
14
|
progress: 0,
|
|
13
15
|
closing: 0,
|
|
@@ -23,67 +25,65 @@ const FALLBACK = Object.freeze({
|
|
|
23
25
|
bounds: {},
|
|
24
26
|
route: {}
|
|
25
27
|
});
|
|
26
|
-
const useBuildScreenTransitionState = descriptor => {
|
|
27
|
-
const key = descriptor?.route.key;
|
|
28
|
-
if (!key) return undefined;
|
|
29
|
-
const progress = Animations.getAnimation(key, "progress");
|
|
30
|
-
const closing = Animations.getAnimation(key, "closing");
|
|
31
|
-
const animating = Animations.getAnimation(key, "animating");
|
|
32
|
-
const gesture = Gestures.getRouteGestures(key);
|
|
33
|
-
const route = descriptor?.route;
|
|
34
|
-
return {
|
|
35
|
-
progress,
|
|
36
|
-
closing,
|
|
37
|
-
animating,
|
|
38
|
-
gesture,
|
|
39
|
-
route
|
|
40
|
-
};
|
|
41
|
-
};
|
|
42
28
|
const unwrap = (s, key) => {
|
|
43
29
|
"worklet";
|
|
44
30
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
31
|
+
if (!s || !key) return undefined;
|
|
32
|
+
return {
|
|
33
|
+
progress: s.progress.value,
|
|
34
|
+
closing: s.closing.value,
|
|
35
|
+
animating: s.animating.value,
|
|
49
36
|
gesture: {
|
|
50
|
-
x: s.gesture.x.value
|
|
51
|
-
y: s.gesture.y.value
|
|
52
|
-
normalizedX: s.gesture.normalizedX.value
|
|
53
|
-
normalizedY: s.gesture.normalizedY.value
|
|
54
|
-
isDismissing: s.gesture.isDismissing.value
|
|
55
|
-
isDragging: s.gesture.isDragging.value
|
|
37
|
+
x: s.gesture.x.value,
|
|
38
|
+
y: s.gesture.y.value,
|
|
39
|
+
normalizedX: s.gesture.normalizedX.value,
|
|
40
|
+
normalizedY: s.gesture.normalizedY.value,
|
|
41
|
+
isDismissing: s.gesture.isDismissing.value,
|
|
42
|
+
isDragging: s.gesture.isDragging.value
|
|
56
43
|
},
|
|
57
|
-
bounds: Bounds.getBounds(key)
|
|
44
|
+
bounds: Bounds.getBounds(key) || EMPTY_BOUNDS,
|
|
58
45
|
route: s.route
|
|
59
|
-
}
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
const useBuildScreenTransitionState = descriptor => {
|
|
49
|
+
const key = descriptor?.route.key;
|
|
50
|
+
return useMemo(() => {
|
|
51
|
+
if (!key) return undefined;
|
|
52
|
+
return {
|
|
53
|
+
progress: Animations.getAnimation(key, "progress"),
|
|
54
|
+
closing: Animations.getAnimation(key, "closing"),
|
|
55
|
+
animating: Animations.getAnimation(key, "animating"),
|
|
56
|
+
gesture: Gestures.getRouteGestures(key),
|
|
57
|
+
route: descriptor.route
|
|
58
|
+
};
|
|
59
|
+
}, [key, descriptor?.route]);
|
|
60
60
|
};
|
|
61
61
|
export function _useScreenAnimation() {
|
|
62
|
+
const dimensions = useWindowDimensions();
|
|
63
|
+
const insets = useSafeAreaInsets();
|
|
62
64
|
const {
|
|
63
65
|
current: currentDescriptor,
|
|
64
66
|
next: nextDescriptor,
|
|
65
67
|
previous: previousDescriptor
|
|
66
68
|
} = useKeys();
|
|
67
|
-
const dimensions = useWindowDimensions();
|
|
68
69
|
const currentAnimation = useBuildScreenTransitionState(currentDescriptor);
|
|
69
70
|
const nextAnimation = useBuildScreenTransitionState(nextDescriptor);
|
|
70
71
|
const prevAnimation = useBuildScreenTransitionState(previousDescriptor);
|
|
71
|
-
const insets = useSafeAreaInsets();
|
|
72
72
|
const screenInterpolatorProps = useDerivedValue(() => {
|
|
73
73
|
"worklet";
|
|
74
74
|
|
|
75
75
|
const previous = unwrap(prevAnimation, previousDescriptor?.route.key);
|
|
76
76
|
const next = unwrap(nextAnimation, nextDescriptor?.route.key);
|
|
77
77
|
const current = unwrap(currentAnimation, currentDescriptor?.route.key) ?? FALLBACK;
|
|
78
|
-
const
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
const bounds = buildBoundsAccessor({
|
|
78
|
+
const {
|
|
79
|
+
progress,
|
|
80
|
+
focused,
|
|
82
81
|
activeBoundId,
|
|
82
|
+
bounds
|
|
83
|
+
} = derivations({
|
|
83
84
|
current,
|
|
84
|
-
previous,
|
|
85
85
|
next,
|
|
86
|
-
|
|
86
|
+
previous,
|
|
87
87
|
dimensions
|
|
88
88
|
});
|
|
89
89
|
return {
|