@ornikar/kitt-universal 31.4.0 → 31.4.1-canary.2fdbcaad37b7e76ba2442f7c56a4939349d51eb1.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/CHANGELOG.md +15 -0
- package/dist/definitions/CardModal/CardModalAnimation/OpacityAnimation.d.ts +8 -0
- package/dist/definitions/CardModal/CardModalAnimation/OpacityAnimation.d.ts.map +1 -0
- package/dist/definitions/CardModal/CardModalAnimation/{NativeRotationAnimation.d.ts → RotationAnimation.d.ts} +3 -3
- package/dist/definitions/CardModal/CardModalAnimation/RotationAnimation.d.ts.map +1 -0
- package/dist/definitions/DialogModal/DialogModalAnimation/NativeOpacityAnimation.d.ts.map +1 -1
- package/dist/definitions/DialogModal/DialogModalAnimation/NativeRotationAnimation.d.ts.map +1 -1
- package/dist/definitions/FullscreenModal/FullscreenModalAnimation.web.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/fullscreenModal.d.ts +0 -14
- package/dist/definitions/themes/late-ocean/fullscreenModal.d.ts.map +1 -1
- package/dist/index-metro.es.android.js +44 -42
- package/dist/index-metro.es.android.js.map +1 -1
- package/dist/index-metro.es.ios.js +44 -42
- package/dist/index-metro.es.ios.js.map +1 -1
- package/dist/index-node-22.17.cjs.js +44 -42
- package/dist/index-node-22.17.cjs.js.map +1 -1
- package/dist/index-node-22.17.cjs.web.css +38 -16
- package/dist/index-node-22.17.cjs.web.js +262 -179
- package/dist/index-node-22.17.cjs.web.js.map +1 -1
- package/dist/index-node-22.17.es.mjs +44 -42
- package/dist/index-node-22.17.es.mjs.map +1 -1
- package/dist/index-node-22.17.es.web.css +38 -16
- package/dist/index-node-22.17.es.web.mjs +262 -179
- package/dist/index-node-22.17.es.web.mjs.map +1 -1
- package/dist/index.es.js +44 -42
- package/dist/index.es.js.map +1 -1
- package/dist/index.es.web.js +288 -206
- package/dist/index.es.web.js.map +1 -1
- package/dist/linaria-themes-metro.es.android.js +30 -34
- package/dist/linaria-themes-metro.es.android.js.map +1 -1
- package/dist/linaria-themes-metro.es.ios.js +30 -34
- package/dist/linaria-themes-metro.es.ios.js.map +1 -1
- package/dist/linaria-themes-node-22.17.cjs.js +30 -34
- package/dist/linaria-themes-node-22.17.cjs.js.map +1 -1
- package/dist/linaria-themes-node-22.17.cjs.web.js +30 -34
- package/dist/linaria-themes-node-22.17.cjs.web.js.map +1 -1
- package/dist/linaria-themes-node-22.17.es.mjs +30 -34
- package/dist/linaria-themes-node-22.17.es.mjs.map +1 -1
- package/dist/linaria-themes-node-22.17.es.web.mjs +30 -34
- package/dist/linaria-themes-node-22.17.es.web.mjs.map +1 -1
- package/dist/linaria-themes.es.js +30 -34
- package/dist/linaria-themes.es.js.map +1 -1
- package/dist/linaria-themes.es.web.js +30 -34
- package/dist/linaria-themes.es.web.js.map +1 -1
- package/dist/styles.css +38 -16
- package/dist/tsbuildinfo +1 -1
- package/package.json +1 -1
- package/dist/definitions/CardModal/CardModalAnimation/NativeOpacityAnimation.d.ts +0 -8
- package/dist/definitions/CardModal/CardModalAnimation/NativeOpacityAnimation.d.ts.map +0 -1
- package/dist/definitions/CardModal/CardModalAnimation/NativeRotationAnimation.d.ts.map +0 -1
- package/dist/definitions/DialogModal/DialogModalAnimation/DialogModalAnimation.web.d.ts +0 -4
- package/dist/definitions/DialogModal/DialogModalAnimation/DialogModalAnimation.web.d.ts.map +0 -1
|
@@ -6,23 +6,45 @@
|
|
|
6
6
|
.kitt-u_opacityEnterActive_o1t4vl7b{opacity:1;-webkit-transition:opacity 250ms cubic-bezier(0.42,0,1,1);transition:opacity 250ms cubic-bezier(0.42,0,1,1);}
|
|
7
7
|
.kitt-u_opacityExit_ogyytm1{opacity:1;}
|
|
8
8
|
.kitt-u_opacityExitActive_o18xvk52{opacity:0;-webkit-transition:opacity 250ms cubic-bezier(0.42,0,1,1);transition:opacity 250ms cubic-bezier(0.42,0,1,1);}
|
|
9
|
-
.kitt-u_contentAnimationEnter_c1i0gle8{opacity:0;-webkit-transform:rotateZ(5deg) scale(0.8);-ms-transform:rotateZ(5deg) scale(0.8);transform:rotateZ(5deg) scale(0.8);}
|
|
10
|
-
.kitt-u_contentAnimatioEnterActive_c1jmfkjw{opacity:1;-webkit-transform:rotateZ(0) scale(1);-ms-transform:rotateZ(0) scale(1);transform:rotateZ(0) scale(1);-webkit-transition:all 400ms cubic-bezier(0.77,0,0.175,1);transition:all 400ms cubic-bezier(0.77,0,0.175,1);}
|
|
11
|
-
.kitt-u_contentAnimatioExit_cwjstxl{opacity:1;-webkit-transform:rotateZ(0) scale(1);-ms-transform:rotateZ(0) scale(1);transform:rotateZ(0) scale(1);}
|
|
12
|
-
.kitt-u_contentAnimatioExitActive_c1almbvu{opacity:0;-webkit-transform:rotateZ(5deg) scale(0.8);-ms-transform:rotateZ(5deg) scale(0.8);transform:rotateZ(5deg) scale(0.8);-webkit-transition:all 400ms cubic-bezier(0.77,0,0.175,1);transition:all 400ms cubic-bezier(0.77,0,0.175,1);}
|
|
13
|
-
.kitt-u_opacityEnter_o9rkayr{opacity:0;}
|
|
14
|
-
.kitt-u_opacityEnterActive_od7zvm9{opacity:1;-webkit-transition:opacity 250ms cubic-bezier(0.42,0,1,1);transition:opacity 250ms cubic-bezier(0.42,0,1,1);}
|
|
15
|
-
.kitt-u_opacityExit_opddo9j{opacity:1;}
|
|
16
|
-
.kitt-u_opacityExitActive_o15v6ove{opacity:0;-webkit-transition:opacity 250ms cubic-bezier(0.42,0,1,1);transition:opacity 250ms cubic-bezier(0.42,0,1,1);}
|
|
17
9
|
.kitt-u_inputTextContainer_i1encr9g{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;position:relative;}.kitt-u_inputTextContainer_i1encr9g > *::-ms-clear,.kitt-u_inputTextContainer_i1encr9g > *::-ms-reveal{display:none;}.kitt-u_inputTextContainer_i1encr9g > *{-webkit-transition:border-color 200ms ease-in-out,background-color 200ms ease-in-out;transition:border-color 200ms ease-in-out,background-color 200ms ease-in-out;}
|
|
18
|
-
|
|
19
|
-
.
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
.
|
|
24
|
-
|
|
25
|
-
|
|
10
|
+
/* Overlay animation styles - uses CSS variables for theme values */
|
|
11
|
+
.FullscreenModalAnimation-module_overlay-enter__L1J1X {
|
|
12
|
+
opacity: 0;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.FullscreenModalAnimation-module_overlay-enter-active__gDEVb {
|
|
16
|
+
opacity: 1;
|
|
17
|
+
transition: opacity var(--overlay-duration) var(--overlay-easing);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.FullscreenModalAnimation-module_overlay-exit__Qx1WE {
|
|
21
|
+
opacity: 1;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.FullscreenModalAnimation-module_overlay-exit-active__lFR3x {
|
|
25
|
+
opacity: 0;
|
|
26
|
+
transition: opacity var(--overlay-duration) var(--overlay-easing);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/* Content animation styles - uses CSS variables for theme values */
|
|
30
|
+
.FullscreenModalAnimation-module_content-enter__JmCWa {
|
|
31
|
+
transform: translateY(100%);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.FullscreenModalAnimation-module_content-enter-active__iaNRs {
|
|
35
|
+
transform: translateY(0);
|
|
36
|
+
transition: transform var(--content-duration) var(--content-easing);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.FullscreenModalAnimation-module_content-exit__hB0wY {
|
|
40
|
+
transform: translateY(0);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.FullscreenModalAnimation-module_content-exit-active__BPVPo {
|
|
44
|
+
transform: translateY(100%);
|
|
45
|
+
transition: transform var(--content-duration) var(--content-easing);
|
|
46
|
+
}
|
|
47
|
+
|
|
26
48
|
.kitt-u_enter_ereraf{-webkit-transform:translateY(8px);-ms-transform:translateY(8px);transform:translateY(8px);opacity:0;}
|
|
27
49
|
.kitt-u_enterActive_e1jmsjrm{-webkit-transform:translateY(0);-ms-transform:translateY(0);transform:translateY(0);opacity:1;-webkit-transition:all 300ms ease-in-out;transition:all 300ms ease-in-out;}
|
|
28
50
|
.kitt-u_exit_e1mwnccz{-webkit-transform:translateY(0);-ms-transform:translateY(0);transform:translateY(0);opacity:1;}
|
|
@@ -3,10 +3,11 @@ import { View as View$1, ScrollView as ScrollView$1, Pressable as Pressable$1, I
|
|
|
3
3
|
export { useClipboard, useContrastText, useMediaQuery, useSx, useToken } from 'native-base';
|
|
4
4
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
5
5
|
import { SpinnerGapRegularIcon, UserRegularIcon, XRegularIcon, ArrowLeftRegularIcon, CaretUpFillIcon, CaretDownFillIcon, MapPinRegularIcon, EyeClosedRegularIcon, EyeRegularIcon, CheckCircleFillIcon, CaretDownRegularIcon, CaretRightRegularIcon, InfoRegularIcon, WarningRegularIcon, CheckRegularIcon, WarningCircleRegularIcon, ArrowCounterClockwiseRegularIcon, InfoFillIcon, WarningCircleFillIcon, WarningFillIcon } from '@ornikar/kitt-icons/phosphor';
|
|
6
|
-
import { Animated, Easing, ScrollView as ScrollView$2, View as View$2, Linking, Pressable as Pressable$2,
|
|
6
|
+
import { Animated, Easing, ScrollView as ScrollView$2, View as View$2, StyleSheet, Modal, Linking, Pressable as Pressable$2, useWindowDimensions } from 'react-native';
|
|
7
7
|
export { useWindowDimensions as useWindowSize } from 'react-native';
|
|
8
8
|
import { createPortal } from 'react-dom';
|
|
9
9
|
import { CSSTransition } from 'react-transition-group';
|
|
10
|
+
import Animated$1, { useAnimatedStyle, withTiming, Easing as Easing$1, runOnJS, useSharedValue, withSpring, interpolateColor, useAnimatedProps, withDelay, withRepeat, interpolate, ReducedMotionConfig, ReduceMotion } from 'react-native-reanimated';
|
|
10
11
|
import { parse } from '@twemoji/parser';
|
|
11
12
|
import Downshift, { useSelect } from 'downshift';
|
|
12
13
|
import { getDocumentAsync } from 'expo-document-picker';
|
|
@@ -14,7 +15,6 @@ import { launchImageLibraryAsync } from 'expo-image-picker';
|
|
|
14
15
|
import { useDebouncedCallback } from 'use-debounce';
|
|
15
16
|
import { Loader } from '@googlemaps/js-api-loader';
|
|
16
17
|
import { parseNumber, getCountryCallingCode, isValidNumber } from 'libphonenumber-js';
|
|
17
|
-
import Animated$1, { useAnimatedStyle, withSpring, withTiming, useSharedValue, interpolateColor, Easing as Easing$1, useAnimatedProps, withDelay, withRepeat, interpolate, runOnJS, ReducedMotionConfig, ReduceMotion } from 'react-native-reanimated';
|
|
18
18
|
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
19
19
|
import Svg, { Circle as Circle$1 } from 'react-native-svg';
|
|
20
20
|
import { useFloating, autoUpdate, offset, autoPlacement, shift, arrow } from '@floating-ui/react-dom';
|
|
@@ -838,15 +838,15 @@ const card = {
|
|
|
838
838
|
}
|
|
839
839
|
};
|
|
840
840
|
|
|
841
|
-
const webAnimationContentDuration$
|
|
842
|
-
const webAnimationContentEasing$
|
|
841
|
+
const webAnimationContentDuration$1 = 400;
|
|
842
|
+
const webAnimationContentEasing$1 = {
|
|
843
843
|
x1: 0.77,
|
|
844
844
|
y1: 0,
|
|
845
845
|
x2: 0.175,
|
|
846
846
|
y2: 1
|
|
847
847
|
};
|
|
848
|
-
const webAnimationOverlayDuration$
|
|
849
|
-
const webAnimationOverlayEasing$
|
|
848
|
+
const webAnimationOverlayDuration$1 = 250;
|
|
849
|
+
const webAnimationOverlayEasing$1 = {
|
|
850
850
|
x1: 0.42,
|
|
851
851
|
y1: 0,
|
|
852
852
|
x2: 1,
|
|
@@ -881,12 +881,12 @@ const cardModal = {
|
|
|
881
881
|
},
|
|
882
882
|
animation: {
|
|
883
883
|
overlay: {
|
|
884
|
-
duration: webAnimationOverlayDuration$
|
|
885
|
-
easing: webAnimationOverlayEasing$
|
|
884
|
+
duration: webAnimationOverlayDuration$1,
|
|
885
|
+
easing: webAnimationOverlayEasing$1
|
|
886
886
|
},
|
|
887
887
|
content: {
|
|
888
|
-
duration: webAnimationContentDuration$
|
|
889
|
-
easing: webAnimationContentEasing$
|
|
888
|
+
duration: webAnimationContentDuration$1,
|
|
889
|
+
easing: webAnimationContentEasing$1
|
|
890
890
|
}
|
|
891
891
|
}
|
|
892
892
|
};
|
|
@@ -942,15 +942,15 @@ const choices = {
|
|
|
942
942
|
}
|
|
943
943
|
};
|
|
944
944
|
|
|
945
|
-
const webAnimationContentDuration
|
|
946
|
-
const webAnimationContentEasing
|
|
945
|
+
const webAnimationContentDuration = 400;
|
|
946
|
+
const webAnimationContentEasing = {
|
|
947
947
|
x1: 0.77,
|
|
948
948
|
y1: 0,
|
|
949
949
|
x2: 0.175,
|
|
950
950
|
y2: 1
|
|
951
951
|
};
|
|
952
|
-
const webAnimationOverlayDuration
|
|
953
|
-
const webAnimationOverlayEasing
|
|
952
|
+
const webAnimationOverlayDuration = 250;
|
|
953
|
+
const webAnimationOverlayEasing = {
|
|
954
954
|
x1: 0.42,
|
|
955
955
|
y1: 0,
|
|
956
956
|
x2: 1,
|
|
@@ -972,12 +972,12 @@ const dialogModal = {
|
|
|
972
972
|
},
|
|
973
973
|
animation: {
|
|
974
974
|
overlay: {
|
|
975
|
-
duration: webAnimationOverlayDuration
|
|
976
|
-
easing: webAnimationOverlayEasing
|
|
975
|
+
duration: webAnimationOverlayDuration,
|
|
976
|
+
easing: webAnimationOverlayEasing
|
|
977
977
|
},
|
|
978
978
|
content: {
|
|
979
|
-
duration: webAnimationContentDuration
|
|
980
|
-
easing: webAnimationContentEasing
|
|
979
|
+
duration: webAnimationContentDuration,
|
|
980
|
+
easing: webAnimationContentEasing
|
|
981
981
|
}
|
|
982
982
|
}
|
|
983
983
|
};
|
|
@@ -1886,20 +1886,6 @@ const forms = {
|
|
|
1886
1886
|
timePicker
|
|
1887
1887
|
};
|
|
1888
1888
|
|
|
1889
|
-
const webAnimationContentDuration = 600;
|
|
1890
|
-
const webAnimationContentEasing = {
|
|
1891
|
-
x1: 0.77,
|
|
1892
|
-
y1: 0,
|
|
1893
|
-
x2: 0.175,
|
|
1894
|
-
y2: 1
|
|
1895
|
-
};
|
|
1896
|
-
const webAnimationOverlayDuration = 250;
|
|
1897
|
-
const webAnimationOverlayEasing = {
|
|
1898
|
-
x1: 0.42,
|
|
1899
|
-
y1: 0,
|
|
1900
|
-
x2: 1,
|
|
1901
|
-
y2: 1
|
|
1902
|
-
};
|
|
1903
1889
|
const fullscreenModal = {
|
|
1904
1890
|
header: {
|
|
1905
1891
|
height: 56
|
|
@@ -1913,12 +1899,22 @@ const fullscreenModal = {
|
|
|
1913
1899
|
},
|
|
1914
1900
|
animation: {
|
|
1915
1901
|
overlay: {
|
|
1916
|
-
duration:
|
|
1917
|
-
easing:
|
|
1902
|
+
duration: 250,
|
|
1903
|
+
easing: {
|
|
1904
|
+
x1: 0.42,
|
|
1905
|
+
y1: 0,
|
|
1906
|
+
x2: 1,
|
|
1907
|
+
y2: 1
|
|
1908
|
+
}
|
|
1918
1909
|
},
|
|
1919
1910
|
content: {
|
|
1920
|
-
duration:
|
|
1921
|
-
easing:
|
|
1911
|
+
duration: 600,
|
|
1912
|
+
easing: {
|
|
1913
|
+
x1: 0.77,
|
|
1914
|
+
y1: 0,
|
|
1915
|
+
x2: 0.175,
|
|
1916
|
+
y2: 1
|
|
1917
|
+
}
|
|
1922
1918
|
}
|
|
1923
1919
|
}
|
|
1924
1920
|
};
|
|
@@ -4323,29 +4319,29 @@ const CardModalRotationContainer = /*#__PURE__*/forwardRef((props, ref) => {
|
|
|
4323
4319
|
});
|
|
4324
4320
|
});
|
|
4325
4321
|
|
|
4326
|
-
const contentAnimationEnter
|
|
4327
|
-
const contentAnimatioEnterActive
|
|
4328
|
-
const contentAnimatioExit
|
|
4329
|
-
const contentAnimatioExitActive
|
|
4330
|
-
const contentAnimationClassNames
|
|
4331
|
-
appear: contentAnimationEnter
|
|
4332
|
-
appearActive: contentAnimatioEnterActive
|
|
4333
|
-
enter: contentAnimationEnter
|
|
4334
|
-
enterActive: contentAnimatioEnterActive
|
|
4335
|
-
exit: contentAnimatioExit
|
|
4336
|
-
exitActive: contentAnimatioExitActive
|
|
4322
|
+
const contentAnimationEnter = "kitt-u_contentAnimationEnter_c11xxy4r";
|
|
4323
|
+
const contentAnimatioEnterActive = "kitt-u_contentAnimatioEnterActive_cl52117";
|
|
4324
|
+
const contentAnimatioExit = "kitt-u_contentAnimatioExit_cyjczep";
|
|
4325
|
+
const contentAnimatioExitActive = "kitt-u_contentAnimatioExitActive_cpsy3dt";
|
|
4326
|
+
const contentAnimationClassNames = {
|
|
4327
|
+
appear: contentAnimationEnter,
|
|
4328
|
+
appearActive: contentAnimatioEnterActive,
|
|
4329
|
+
enter: contentAnimationEnter,
|
|
4330
|
+
enterActive: contentAnimatioEnterActive,
|
|
4331
|
+
exit: contentAnimatioExit,
|
|
4332
|
+
exitActive: contentAnimatioExitActive
|
|
4337
4333
|
};
|
|
4338
|
-
const opacityEnter
|
|
4339
|
-
const opacityEnterActive
|
|
4340
|
-
const opacityExit
|
|
4341
|
-
const opacityExitActive
|
|
4342
|
-
const opacityClassNames
|
|
4343
|
-
appear: opacityEnter
|
|
4344
|
-
appearActive: opacityEnterActive
|
|
4345
|
-
enter: opacityEnter
|
|
4346
|
-
enterActive: opacityEnterActive
|
|
4347
|
-
exit: opacityExit
|
|
4348
|
-
exitActive: opacityExitActive
|
|
4334
|
+
const opacityEnter = "kitt-u_opacityEnter_o1ae40dx";
|
|
4335
|
+
const opacityEnterActive = "kitt-u_opacityEnterActive_o1t4vl7b";
|
|
4336
|
+
const opacityExit = "kitt-u_opacityExit_ogyytm1";
|
|
4337
|
+
const opacityExitActive = "kitt-u_opacityExitActive_o18xvk52";
|
|
4338
|
+
const opacityClassNames = {
|
|
4339
|
+
appear: opacityEnter,
|
|
4340
|
+
appearActive: opacityEnterActive,
|
|
4341
|
+
enter: opacityEnter,
|
|
4342
|
+
enterActive: opacityEnterActive,
|
|
4343
|
+
exit: opacityExit,
|
|
4344
|
+
exitActive: opacityExitActive
|
|
4349
4345
|
};
|
|
4350
4346
|
function CardModalAnimation({
|
|
4351
4347
|
children,
|
|
@@ -4381,7 +4377,7 @@ function CardModalAnimation({
|
|
|
4381
4377
|
...sharedProps,
|
|
4382
4378
|
nodeRef: overlayRef,
|
|
4383
4379
|
timeout: isAnimationEnabled ? animation.overlay.duration : 0,
|
|
4384
|
-
classNames: opacityClassNames
|
|
4380
|
+
classNames: opacityClassNames,
|
|
4385
4381
|
children: /*#__PURE__*/jsx(Overlay, {
|
|
4386
4382
|
ref: overlayRef,
|
|
4387
4383
|
onPress: onClose
|
|
@@ -4390,7 +4386,7 @@ function CardModalAnimation({
|
|
|
4390
4386
|
...sharedProps,
|
|
4391
4387
|
nodeRef: contentRef,
|
|
4392
4388
|
timeout: isAnimationEnabled ? animation.content.duration : 0,
|
|
4393
|
-
classNames: contentAnimationClassNames
|
|
4389
|
+
classNames: contentAnimationClassNames,
|
|
4394
4390
|
onEnter: onEnter,
|
|
4395
4391
|
onEntered: onEntered,
|
|
4396
4392
|
onExit: onExit,
|
|
@@ -4927,87 +4923,167 @@ const ChoicesElements = {
|
|
|
4927
4923
|
ButtonChoices
|
|
4928
4924
|
};
|
|
4929
4925
|
|
|
4930
|
-
|
|
4931
|
-
|
|
4932
|
-
const contentAnimatioExit = "kitt-u_contentAnimatioExit_cwjstxl";
|
|
4933
|
-
const contentAnimatioExitActive = "kitt-u_contentAnimatioExitActive_c1almbvu";
|
|
4934
|
-
const contentAnimationClassNames = {
|
|
4935
|
-
appear: contentAnimationEnter,
|
|
4936
|
-
appearActive: contentAnimatioEnterActive,
|
|
4937
|
-
enter: contentAnimationEnter,
|
|
4938
|
-
enterActive: contentAnimatioEnterActive,
|
|
4939
|
-
exit: contentAnimatioExit,
|
|
4940
|
-
exitActive: contentAnimatioExitActive
|
|
4941
|
-
};
|
|
4942
|
-
const opacityEnter$1 = "kitt-u_opacityEnter_o9rkayr";
|
|
4943
|
-
const opacityEnterActive$1 = "kitt-u_opacityEnterActive_od7zvm9";
|
|
4944
|
-
const opacityExit$1 = "kitt-u_opacityExit_opddo9j";
|
|
4945
|
-
const opacityExitActive$1 = "kitt-u_opacityExitActive_o15v6ove";
|
|
4946
|
-
const opacityClassNames$1 = {
|
|
4947
|
-
appear: opacityEnter$1,
|
|
4948
|
-
appearActive: opacityEnterActive$1,
|
|
4949
|
-
enter: opacityEnter$1,
|
|
4950
|
-
enterActive: opacityEnterActive$1,
|
|
4951
|
-
exit: opacityExit$1,
|
|
4952
|
-
exitActive: opacityExitActive$1
|
|
4953
|
-
};
|
|
4954
|
-
function DialogModalAnimation({
|
|
4926
|
+
function NativeOpacityAnimation({
|
|
4927
|
+
visible,
|
|
4955
4928
|
children,
|
|
4956
|
-
|
|
4929
|
+
onExited
|
|
4930
|
+
}) {
|
|
4931
|
+
const theme = useTheme();
|
|
4932
|
+
const hasRunAnimationRef = useRef(false);
|
|
4933
|
+
useEffect(() => {
|
|
4934
|
+
if (visible) {
|
|
4935
|
+
hasRunAnimationRef.current = true;
|
|
4936
|
+
}
|
|
4937
|
+
}, [visible]);
|
|
4938
|
+
function handleAnimationFinished() {
|
|
4939
|
+
if (!visible && hasRunAnimationRef.current) {
|
|
4940
|
+
onExited();
|
|
4941
|
+
}
|
|
4942
|
+
}
|
|
4943
|
+
const opacityStyle = useAnimatedStyle(() => {
|
|
4944
|
+
const {
|
|
4945
|
+
duration,
|
|
4946
|
+
easing
|
|
4947
|
+
} = theme.kitt.dialogModal.animation.overlay;
|
|
4948
|
+
const {
|
|
4949
|
+
x1,
|
|
4950
|
+
y1,
|
|
4951
|
+
x2,
|
|
4952
|
+
y2
|
|
4953
|
+
} = easing;
|
|
4954
|
+
return {
|
|
4955
|
+
opacity: withTiming(visible ? 1 : 0, {
|
|
4956
|
+
duration,
|
|
4957
|
+
easing: Easing$1.bezier(x1, y1, x2, y2)
|
|
4958
|
+
}, isFinished => {
|
|
4959
|
+
if (!isFinished) return;
|
|
4960
|
+
runOnJS(handleAnimationFinished)();
|
|
4961
|
+
})
|
|
4962
|
+
};
|
|
4963
|
+
}, [theme, visible, handleAnimationFinished]);
|
|
4964
|
+
return /*#__PURE__*/jsx(Animated$1.View, {
|
|
4965
|
+
style: [StyleSheet.absoluteFillObject, opacityStyle],
|
|
4966
|
+
children: children
|
|
4967
|
+
});
|
|
4968
|
+
}
|
|
4969
|
+
|
|
4970
|
+
function NativeRotationAnimation({
|
|
4957
4971
|
visible,
|
|
4958
|
-
|
|
4959
|
-
|
|
4972
|
+
children,
|
|
4973
|
+
onEntered,
|
|
4974
|
+
onExited
|
|
4975
|
+
}) {
|
|
4976
|
+
const theme = useTheme();
|
|
4977
|
+
const hasRunAnimationRef = useRef(false);
|
|
4978
|
+
const rotation = useSharedValue(0.8);
|
|
4979
|
+
useEffect(() => {
|
|
4980
|
+
if (visible) {
|
|
4981
|
+
hasRunAnimationRef.current = true;
|
|
4982
|
+
}
|
|
4983
|
+
}, [visible]);
|
|
4984
|
+
function handleAnimationFinished() {
|
|
4985
|
+
if (visible) {
|
|
4986
|
+
if (onEntered) onEntered();
|
|
4987
|
+
}
|
|
4988
|
+
if (!visible && hasRunAnimationRef.current) onExited();
|
|
4989
|
+
}
|
|
4990
|
+
const animatedStyle = useAnimatedStyle(() => {
|
|
4991
|
+
const {
|
|
4992
|
+
duration,
|
|
4993
|
+
easing
|
|
4994
|
+
} = theme.kitt.dialogModal.animation.content;
|
|
4995
|
+
const {
|
|
4996
|
+
x1,
|
|
4997
|
+
y1,
|
|
4998
|
+
x2,
|
|
4999
|
+
y2
|
|
5000
|
+
} = easing;
|
|
5001
|
+
rotation.value = withTiming(visible ? 0 : 5, {
|
|
5002
|
+
duration,
|
|
5003
|
+
easing: Easing$1.bezier(x1, y1, x2, y2)
|
|
5004
|
+
}, isFinished => {
|
|
5005
|
+
if (!isFinished) return;
|
|
5006
|
+
runOnJS(handleAnimationFinished)();
|
|
5007
|
+
});
|
|
5008
|
+
return {
|
|
5009
|
+
opacity: withTiming(visible ? 1 : 0, {
|
|
5010
|
+
duration,
|
|
5011
|
+
easing: Easing$1.bezier(x1, y1, x2, y2)
|
|
5012
|
+
}),
|
|
5013
|
+
transform: [{
|
|
5014
|
+
scale: withTiming(visible ? 1 : 0.8, {
|
|
5015
|
+
duration,
|
|
5016
|
+
easing: Easing$1.bezier(x1, y1, x2, y2)
|
|
5017
|
+
})
|
|
5018
|
+
}, {
|
|
5019
|
+
rotateZ: `${rotation.value}deg`
|
|
5020
|
+
}]
|
|
5021
|
+
};
|
|
5022
|
+
}, [theme, visible, rotation, handleAnimationFinished]);
|
|
5023
|
+
return /*#__PURE__*/jsx(Animated$1.View, {
|
|
5024
|
+
style: [animatedStyle],
|
|
5025
|
+
children: children
|
|
5026
|
+
});
|
|
5027
|
+
}
|
|
5028
|
+
|
|
5029
|
+
function DialogModalAnimation({
|
|
5030
|
+
visible,
|
|
5031
|
+
children,
|
|
4960
5032
|
onEnter,
|
|
4961
5033
|
onEntered,
|
|
4962
5034
|
onExit,
|
|
4963
5035
|
onExited,
|
|
4964
|
-
onClose
|
|
4965
|
-
...props
|
|
5036
|
+
onClose
|
|
4966
5037
|
}) {
|
|
4967
|
-
|
|
4968
|
-
|
|
4969
|
-
const
|
|
4970
|
-
|
|
4971
|
-
|
|
4972
|
-
const {
|
|
4973
|
-
animation
|
|
4974
|
-
} = theme.kitt.dialogModal;
|
|
4975
|
-
const sharedProps = {
|
|
4976
|
-
in: visible,
|
|
4977
|
-
appear,
|
|
4978
|
-
unmountOnExit
|
|
5038
|
+
const [isModalVisible, setIsModalVisible] = useState(visible);
|
|
5039
|
+
const [isContentVisible, setIsContentVisible] = useState(false);
|
|
5040
|
+
const handleAnimationExited = () => {
|
|
5041
|
+
setIsModalVisible(false);
|
|
5042
|
+
// Android doesn't handle the onDismiss callback on the modal, we need to call it manually
|
|
4979
5043
|
};
|
|
4980
|
-
|
|
4981
|
-
|
|
4982
|
-
|
|
4983
|
-
|
|
4984
|
-
|
|
4985
|
-
|
|
4986
|
-
|
|
4987
|
-
|
|
4988
|
-
|
|
4989
|
-
|
|
4990
|
-
|
|
4991
|
-
|
|
4992
|
-
|
|
4993
|
-
|
|
4994
|
-
|
|
4995
|
-
|
|
4996
|
-
|
|
4997
|
-
|
|
4998
|
-
|
|
4999
|
-
|
|
5000
|
-
|
|
5001
|
-
|
|
5002
|
-
|
|
5003
|
-
|
|
5004
|
-
|
|
5005
|
-
|
|
5006
|
-
|
|
5007
|
-
|
|
5008
|
-
|
|
5009
|
-
|
|
5010
|
-
|
|
5044
|
+
useEffect(() => {
|
|
5045
|
+
if (!(!visible && isContentVisible)) return;
|
|
5046
|
+
if (onExit) onExit();
|
|
5047
|
+
setIsContentVisible(false);
|
|
5048
|
+
}, [visible, isContentVisible, onExit]);
|
|
5049
|
+
return /*#__PURE__*/jsx(Modal, {
|
|
5050
|
+
transparent: true,
|
|
5051
|
+
supportedOrientations: ['landscape', 'portrait'],
|
|
5052
|
+
visible: isModalVisible,
|
|
5053
|
+
onShow: () => {
|
|
5054
|
+
if (onEnter) onEnter();
|
|
5055
|
+
setIsContentVisible(true);
|
|
5056
|
+
},
|
|
5057
|
+
onDismiss: () => {
|
|
5058
|
+
if (onExited) onExited();
|
|
5059
|
+
},
|
|
5060
|
+
children: /*#__PURE__*/jsxs(View
|
|
5061
|
+
// This is an ugly workaround to make the Modal calculate its height correctly on Android.
|
|
5062
|
+
// This ugly workaround is used in FullScreenModalAnimation and CardModalAnimation as well
|
|
5063
|
+
// TODO [expo@>=53]: Check if still needed
|
|
5064
|
+
, {
|
|
5065
|
+
height: undefined,
|
|
5066
|
+
position: "relative",
|
|
5067
|
+
flexGrow: 1,
|
|
5068
|
+
justifyContent: "center",
|
|
5069
|
+
alignItems: "center",
|
|
5070
|
+
children: [/*#__PURE__*/jsx(NativeOpacityAnimation, {
|
|
5071
|
+
visible: isContentVisible,
|
|
5072
|
+
onExited: handleAnimationExited,
|
|
5073
|
+
children: /*#__PURE__*/jsx(Overlay, {
|
|
5074
|
+
onPress: onClose
|
|
5075
|
+
})
|
|
5076
|
+
}), /*#__PURE__*/jsx(NativeRotationAnimation, {
|
|
5077
|
+
visible: isContentVisible,
|
|
5078
|
+
onExited: handleAnimationExited,
|
|
5079
|
+
onEntered: onEntered,
|
|
5080
|
+
children: /*#__PURE__*/jsx(View, {
|
|
5081
|
+
paddingX: "kitt.dialogModal.overlayPadding.horizontal",
|
|
5082
|
+
paddingY: "kitt.dialogModal.overlayPadding.vertical",
|
|
5083
|
+
children: children
|
|
5084
|
+
})
|
|
5085
|
+
})]
|
|
5086
|
+
})
|
|
5011
5087
|
});
|
|
5012
5088
|
}
|
|
5013
5089
|
|
|
@@ -7562,29 +7638,23 @@ function FullscreenModalFooter({
|
|
|
7562
7638
|
});
|
|
7563
7639
|
}
|
|
7564
7640
|
|
|
7565
|
-
const
|
|
7566
|
-
|
|
7567
|
-
const
|
|
7568
|
-
|
|
7569
|
-
|
|
7570
|
-
|
|
7571
|
-
|
|
7572
|
-
|
|
7573
|
-
|
|
7574
|
-
exit: slideInFromBottomExit,
|
|
7575
|
-
exitActive: slideInFromBottomExitActive
|
|
7641
|
+
const styles$1 = {"overlay-enter":"FullscreenModalAnimation-module_overlay-enter__L1J1X","overlay-enter-active":"FullscreenModalAnimation-module_overlay-enter-active__gDEVb","overlay-exit":"FullscreenModalAnimation-module_overlay-exit__Qx1WE","overlay-exit-active":"FullscreenModalAnimation-module_overlay-exit-active__lFR3x","content-enter":"FullscreenModalAnimation-module_content-enter__JmCWa","content-enter-active":"FullscreenModalAnimation-module_content-enter-active__iaNRs","content-exit":"FullscreenModalAnimation-module_content-exit__hB0wY","content-exit-active":"FullscreenModalAnimation-module_content-exit-active__BPVPo"};
|
|
7642
|
+
|
|
7643
|
+
const overlayClassNames = {
|
|
7644
|
+
appear: styles$1['overlay-enter'],
|
|
7645
|
+
appearActive: styles$1['overlay-enter-active'],
|
|
7646
|
+
enter: styles$1['overlay-enter'],
|
|
7647
|
+
enterActive: styles$1['overlay-enter-active'],
|
|
7648
|
+
exit: styles$1['overlay-exit'],
|
|
7649
|
+
exitActive: styles$1['overlay-exit-active']
|
|
7576
7650
|
};
|
|
7577
|
-
const
|
|
7578
|
-
|
|
7579
|
-
|
|
7580
|
-
|
|
7581
|
-
|
|
7582
|
-
|
|
7583
|
-
|
|
7584
|
-
enter: opacityEnter,
|
|
7585
|
-
enterActive: opacityEnterActive,
|
|
7586
|
-
exit: opacityExit,
|
|
7587
|
-
exitActive: opacityExitActive
|
|
7651
|
+
const slideInClassNames = {
|
|
7652
|
+
appear: styles$1['content-enter'],
|
|
7653
|
+
appearActive: styles$1['content-enter-active'],
|
|
7654
|
+
enter: styles$1['content-enter'],
|
|
7655
|
+
enterActive: styles$1['content-enter-active'],
|
|
7656
|
+
exit: styles$1['content-exit'],
|
|
7657
|
+
exitActive: styles$1['content-exit-active']
|
|
7588
7658
|
};
|
|
7589
7659
|
function FullscreenModalAnimation({
|
|
7590
7660
|
children,
|
|
@@ -7612,31 +7682,44 @@ function FullscreenModalAnimation({
|
|
|
7612
7682
|
appear,
|
|
7613
7683
|
unmountOnExit
|
|
7614
7684
|
};
|
|
7615
|
-
|
|
7685
|
+
|
|
7686
|
+
// CSS custom properties for theme-based animation values
|
|
7687
|
+
const overlayEasing = animation.overlay.easing;
|
|
7688
|
+
const contentEasing = animation.content.easing;
|
|
7689
|
+
const cssVariables = {
|
|
7690
|
+
'--overlay-duration': `${animation.overlay.duration}ms`,
|
|
7691
|
+
'--overlay-easing': `cubic-bezier(${overlayEasing.x1}, ${overlayEasing.y1}, ${overlayEasing.x2}, ${overlayEasing.y2})`,
|
|
7692
|
+
'--content-duration': `${animation.content.duration}ms`,
|
|
7693
|
+
'--content-easing': `cubic-bezier(${contentEasing.x1}, ${contentEasing.y1}, ${contentEasing.x2}, ${contentEasing.y2})`
|
|
7694
|
+
};
|
|
7695
|
+
return /*#__PURE__*/jsx(View, {
|
|
7616
7696
|
...props,
|
|
7617
|
-
children:
|
|
7618
|
-
|
|
7619
|
-
|
|
7620
|
-
|
|
7621
|
-
|
|
7622
|
-
|
|
7623
|
-
|
|
7624
|
-
|
|
7625
|
-
|
|
7626
|
-
|
|
7627
|
-
|
|
7628
|
-
|
|
7629
|
-
|
|
7630
|
-
|
|
7631
|
-
|
|
7632
|
-
|
|
7633
|
-
|
|
7634
|
-
|
|
7635
|
-
|
|
7636
|
-
|
|
7637
|
-
children:
|
|
7638
|
-
|
|
7639
|
-
|
|
7697
|
+
children: /*#__PURE__*/jsxs("div", {
|
|
7698
|
+
style: cssVariables,
|
|
7699
|
+
children: [/*#__PURE__*/jsx(CSSTransition, {
|
|
7700
|
+
...sharedProps,
|
|
7701
|
+
nodeRef: overlayRef,
|
|
7702
|
+
timeout: isAnimationEnabled ? animation.overlay.duration : 0,
|
|
7703
|
+
classNames: overlayClassNames,
|
|
7704
|
+
children: /*#__PURE__*/jsx(Overlay, {
|
|
7705
|
+
ref: overlayRef,
|
|
7706
|
+
onPress: onClose
|
|
7707
|
+
})
|
|
7708
|
+
}), /*#__PURE__*/jsx(CSSTransition, {
|
|
7709
|
+
...sharedProps,
|
|
7710
|
+
nodeRef: contentRef,
|
|
7711
|
+
timeout: isAnimationEnabled ? animation.content.duration : 0,
|
|
7712
|
+
classNames: slideInClassNames,
|
|
7713
|
+
onEnter: onEnter,
|
|
7714
|
+
onEntered: onEntered,
|
|
7715
|
+
onExit: onExit,
|
|
7716
|
+
onExited: onExited,
|
|
7717
|
+
children: /*#__PURE__*/jsx(View, {
|
|
7718
|
+
ref: contentRef,
|
|
7719
|
+
children: children
|
|
7720
|
+
})
|
|
7721
|
+
})]
|
|
7722
|
+
})
|
|
7640
7723
|
});
|
|
7641
7724
|
}
|
|
7642
7725
|
|