@ornikar/kitt-universal 31.4.0 → 32.0.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.
Files changed (43) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/dist/definitions/CardModal/CardModalAnimation/OpacityAnimation.d.ts +8 -0
  3. package/dist/definitions/CardModal/CardModalAnimation/OpacityAnimation.d.ts.map +1 -0
  4. package/dist/definitions/CardModal/CardModalAnimation/{NativeRotationAnimation.d.ts → RotationAnimation.d.ts} +3 -3
  5. package/dist/definitions/CardModal/CardModalAnimation/RotationAnimation.d.ts.map +1 -0
  6. package/dist/definitions/DialogModal/DialogModalAnimation/NativeOpacityAnimation.d.ts.map +1 -1
  7. package/dist/definitions/DialogModal/DialogModalAnimation/NativeRotationAnimation.d.ts.map +1 -1
  8. package/dist/definitions/forms/InputAddress/InputAddress.d.ts +12 -8
  9. package/dist/definitions/forms/InputAddress/InputAddress.d.ts.map +1 -1
  10. package/dist/definitions/forms/InputAddress/InputAddressLegacy.d.ts +15 -0
  11. package/dist/definitions/forms/InputAddress/InputAddressLegacy.d.ts.map +1 -0
  12. package/dist/definitions/forms/InputAddress/InputAddressOption.d.ts +5 -4
  13. package/dist/definitions/forms/InputAddress/InputAddressOption.d.ts.map +1 -1
  14. package/dist/definitions/forms/InputAddress/InputAddressOptionLegacy.d.ts +7 -0
  15. package/dist/definitions/forms/InputAddress/InputAddressOptionLegacy.d.ts.map +1 -0
  16. package/dist/definitions/index.d.ts +4 -1
  17. package/dist/definitions/index.d.ts.map +1 -1
  18. package/dist/index-metro.es.android.js +161 -78
  19. package/dist/index-metro.es.android.js.map +1 -1
  20. package/dist/index-metro.es.ios.js +161 -78
  21. package/dist/index-metro.es.ios.js.map +1 -1
  22. package/dist/index-node-22.17.cjs.js +96 -13
  23. package/dist/index-node-22.17.cjs.js.map +1 -1
  24. package/dist/index-node-22.17.cjs.web.css +0 -8
  25. package/dist/index-node-22.17.cjs.web.js +261 -104
  26. package/dist/index-node-22.17.cjs.web.js.map +1 -1
  27. package/dist/index-node-22.17.es.mjs +96 -14
  28. package/dist/index-node-22.17.es.mjs.map +1 -1
  29. package/dist/index-node-22.17.es.web.css +0 -8
  30. package/dist/index-node-22.17.es.web.mjs +261 -105
  31. package/dist/index-node-22.17.es.web.mjs.map +1 -1
  32. package/dist/index.es.js +162 -78
  33. package/dist/index.es.js.map +1 -1
  34. package/dist/index.es.web.js +283 -126
  35. package/dist/index.es.web.js.map +1 -1
  36. package/dist/styles.css +0 -8
  37. package/dist/tsbuildinfo +1 -1
  38. package/package.json +1 -1
  39. package/dist/definitions/CardModal/CardModalAnimation/NativeOpacityAnimation.d.ts +0 -8
  40. package/dist/definitions/CardModal/CardModalAnimation/NativeOpacityAnimation.d.ts.map +0 -1
  41. package/dist/definitions/CardModal/CardModalAnimation/NativeRotationAnimation.d.ts.map +0 -1
  42. package/dist/definitions/DialogModal/DialogModalAnimation/DialogModalAnimation.web.d.ts +0 -4
  43. package/dist/definitions/DialogModal/DialogModalAnimation/DialogModalAnimation.web.d.ts.map +0 -1
@@ -6,14 +6,6 @@
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
10
  .kitt-u_slideInFromBottomEnter_s1717rto{-webkit-transform:translateY(100%);-ms-transform:translateY(100%);transform:translateY(100%);}
19
11
  .kitt-u_slideInFromBottomEnterActive_sux6xgc{-webkit-transform:translateY(0);-ms-transform:translateY(0);transform:translateY(0);-webkit-transition:-webkit-transform 600ms cubic-bezier(0.77,0,0.175,1);-webkit-transition:transform 600ms cubic-bezier(0.77,0,0.175,1);transition:transform 600ms cubic-bezier(0.77,0,0.175,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, StyleSheet, useWindowDimensions } from 'react-native';
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';
@@ -4323,29 +4323,29 @@ const CardModalRotationContainer = /*#__PURE__*/forwardRef((props, ref) => {
4323
4323
  });
4324
4324
  });
4325
4325
 
4326
- const contentAnimationEnter$1 = "kitt-u_contentAnimationEnter_c11xxy4r";
4327
- const contentAnimatioEnterActive$1 = "kitt-u_contentAnimatioEnterActive_cl52117";
4328
- const contentAnimatioExit$1 = "kitt-u_contentAnimatioExit_cyjczep";
4329
- const contentAnimatioExitActive$1 = "kitt-u_contentAnimatioExitActive_cpsy3dt";
4330
- const contentAnimationClassNames$1 = {
4331
- appear: contentAnimationEnter$1,
4332
- appearActive: contentAnimatioEnterActive$1,
4333
- enter: contentAnimationEnter$1,
4334
- enterActive: contentAnimatioEnterActive$1,
4335
- exit: contentAnimatioExit$1,
4336
- exitActive: contentAnimatioExitActive$1
4326
+ const contentAnimationEnter = "kitt-u_contentAnimationEnter_c11xxy4r";
4327
+ const contentAnimatioEnterActive = "kitt-u_contentAnimatioEnterActive_cl52117";
4328
+ const contentAnimatioExit = "kitt-u_contentAnimatioExit_cyjczep";
4329
+ const contentAnimatioExitActive = "kitt-u_contentAnimatioExitActive_cpsy3dt";
4330
+ const contentAnimationClassNames = {
4331
+ appear: contentAnimationEnter,
4332
+ appearActive: contentAnimatioEnterActive,
4333
+ enter: contentAnimationEnter,
4334
+ enterActive: contentAnimatioEnterActive,
4335
+ exit: contentAnimatioExit,
4336
+ exitActive: contentAnimatioExitActive
4337
4337
  };
4338
- const opacityEnter$2 = "kitt-u_opacityEnter_o1ae40dx";
4339
- const opacityEnterActive$2 = "kitt-u_opacityEnterActive_o1t4vl7b";
4340
- const opacityExit$2 = "kitt-u_opacityExit_ogyytm1";
4341
- const opacityExitActive$2 = "kitt-u_opacityExitActive_o18xvk52";
4342
- const opacityClassNames$2 = {
4343
- appear: opacityEnter$2,
4344
- appearActive: opacityEnterActive$2,
4345
- enter: opacityEnter$2,
4346
- enterActive: opacityEnterActive$2,
4347
- exit: opacityExit$2,
4348
- exitActive: opacityExitActive$2
4338
+ const opacityEnter$1 = "kitt-u_opacityEnter_o1ae40dx";
4339
+ const opacityEnterActive$1 = "kitt-u_opacityEnterActive_o1t4vl7b";
4340
+ const opacityExit$1 = "kitt-u_opacityExit_ogyytm1";
4341
+ const opacityExitActive$1 = "kitt-u_opacityExitActive_o18xvk52";
4342
+ const opacityClassNames$1 = {
4343
+ appear: opacityEnter$1,
4344
+ appearActive: opacityEnterActive$1,
4345
+ enter: opacityEnter$1,
4346
+ enterActive: opacityEnterActive$1,
4347
+ exit: opacityExit$1,
4348
+ exitActive: opacityExitActive$1
4349
4349
  };
4350
4350
  function CardModalAnimation({
4351
4351
  children,
@@ -4381,7 +4381,7 @@ function CardModalAnimation({
4381
4381
  ...sharedProps,
4382
4382
  nodeRef: overlayRef,
4383
4383
  timeout: isAnimationEnabled ? animation.overlay.duration : 0,
4384
- classNames: opacityClassNames$2,
4384
+ classNames: opacityClassNames$1,
4385
4385
  children: /*#__PURE__*/jsx(Overlay, {
4386
4386
  ref: overlayRef,
4387
4387
  onPress: onClose
@@ -4390,7 +4390,7 @@ function CardModalAnimation({
4390
4390
  ...sharedProps,
4391
4391
  nodeRef: contentRef,
4392
4392
  timeout: isAnimationEnabled ? animation.content.duration : 0,
4393
- classNames: contentAnimationClassNames$1,
4393
+ classNames: contentAnimationClassNames,
4394
4394
  onEnter: onEnter,
4395
4395
  onEntered: onEntered,
4396
4396
  onExit: onExit,
@@ -4927,87 +4927,167 @@ const ChoicesElements = {
4927
4927
  ButtonChoices
4928
4928
  };
4929
4929
 
4930
- const contentAnimationEnter = "kitt-u_contentAnimationEnter_c1i0gle8";
4931
- const contentAnimatioEnterActive = "kitt-u_contentAnimatioEnterActive_c1jmfkjw";
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({
4930
+ function NativeOpacityAnimation({
4931
+ visible,
4955
4932
  children,
4956
- appear = true,
4933
+ onExited
4934
+ }) {
4935
+ const theme = useTheme();
4936
+ const hasRunAnimationRef = useRef(false);
4937
+ useEffect(() => {
4938
+ if (visible) {
4939
+ hasRunAnimationRef.current = true;
4940
+ }
4941
+ }, [visible]);
4942
+ function handleAnimationFinished() {
4943
+ if (!visible && hasRunAnimationRef.current) {
4944
+ onExited();
4945
+ }
4946
+ }
4947
+ const opacityStyle = useAnimatedStyle(() => {
4948
+ const {
4949
+ duration,
4950
+ easing
4951
+ } = theme.kitt.dialogModal.animation.overlay;
4952
+ const {
4953
+ x1,
4954
+ y1,
4955
+ x2,
4956
+ y2
4957
+ } = easing;
4958
+ return {
4959
+ opacity: withTiming(visible ? 1 : 0, {
4960
+ duration,
4961
+ easing: Easing$1.bezier(x1, y1, x2, y2)
4962
+ }, isFinished => {
4963
+ if (!isFinished) return;
4964
+ runOnJS(handleAnimationFinished)();
4965
+ })
4966
+ };
4967
+ }, [theme, visible, handleAnimationFinished]);
4968
+ return /*#__PURE__*/jsx(Animated$1.View, {
4969
+ style: [StyleSheet.absoluteFillObject, opacityStyle],
4970
+ children: children
4971
+ });
4972
+ }
4973
+
4974
+ function NativeRotationAnimation({
4957
4975
  visible,
4958
- unmountOnExit = true,
4959
- isAnimationEnabled = true,
4976
+ children,
4977
+ onEntered,
4978
+ onExited
4979
+ }) {
4980
+ const theme = useTheme();
4981
+ const hasRunAnimationRef = useRef(false);
4982
+ const rotation = useSharedValue(0.8);
4983
+ useEffect(() => {
4984
+ if (visible) {
4985
+ hasRunAnimationRef.current = true;
4986
+ }
4987
+ }, [visible]);
4988
+ function handleAnimationFinished() {
4989
+ if (visible) {
4990
+ if (onEntered) onEntered();
4991
+ }
4992
+ if (!visible && hasRunAnimationRef.current) onExited();
4993
+ }
4994
+ const animatedStyle = useAnimatedStyle(() => {
4995
+ const {
4996
+ duration,
4997
+ easing
4998
+ } = theme.kitt.dialogModal.animation.content;
4999
+ const {
5000
+ x1,
5001
+ y1,
5002
+ x2,
5003
+ y2
5004
+ } = easing;
5005
+ rotation.value = withTiming(visible ? 0 : 5, {
5006
+ duration,
5007
+ easing: Easing$1.bezier(x1, y1, x2, y2)
5008
+ }, isFinished => {
5009
+ if (!isFinished) return;
5010
+ runOnJS(handleAnimationFinished)();
5011
+ });
5012
+ return {
5013
+ opacity: withTiming(visible ? 1 : 0, {
5014
+ duration,
5015
+ easing: Easing$1.bezier(x1, y1, x2, y2)
5016
+ }),
5017
+ transform: [{
5018
+ scale: withTiming(visible ? 1 : 0.8, {
5019
+ duration,
5020
+ easing: Easing$1.bezier(x1, y1, x2, y2)
5021
+ })
5022
+ }, {
5023
+ rotateZ: `${rotation.value}deg`
5024
+ }]
5025
+ };
5026
+ }, [theme, visible, rotation, handleAnimationFinished]);
5027
+ return /*#__PURE__*/jsx(Animated$1.View, {
5028
+ style: [animatedStyle],
5029
+ children: children
5030
+ });
5031
+ }
5032
+
5033
+ function DialogModalAnimation({
5034
+ visible,
5035
+ children,
4960
5036
  onEnter,
4961
5037
  onEntered,
4962
5038
  onExit,
4963
5039
  onExited,
4964
- onClose,
4965
- ...props
5040
+ onClose
4966
5041
  }) {
4967
- // React 19 has removed the ReactDOM.findDOMNode method. We need to use refs to access DOM nodes in CSSTransition.
4968
- // See https://github.com/reactjs/react-transition-group/issues/918
4969
- const overlayRef = useRef(null);
4970
- const contentRef = useRef(null);
4971
- const theme = useTheme();
4972
- const {
4973
- animation
4974
- } = theme.kitt.dialogModal;
4975
- const sharedProps = {
4976
- in: visible,
4977
- appear,
4978
- unmountOnExit
5042
+ const [isModalVisible, setIsModalVisible] = useState(visible);
5043
+ const [isContentVisible, setIsContentVisible] = useState(false);
5044
+ const handleAnimationExited = () => {
5045
+ setIsModalVisible(false);
5046
+ // Android doesn't handle the onDismiss callback on the modal, we need to call it manually
4979
5047
  };
4980
- return /*#__PURE__*/jsxs(View, {
4981
- ...props,
4982
- height: "100%",
4983
- justifyContent: "center",
4984
- children: [/*#__PURE__*/jsx(CSSTransition, {
4985
- ...sharedProps,
4986
- nodeRef: overlayRef,
4987
- timeout: isAnimationEnabled ? animation.overlay.duration : 0,
4988
- classNames: opacityClassNames$1,
4989
- children: /*#__PURE__*/jsx(Overlay, {
4990
- ref: overlayRef,
4991
- onPress: onClose
4992
- })
4993
- }), /*#__PURE__*/jsx(CSSTransition, {
4994
- ...sharedProps,
4995
- nodeRef: contentRef,
4996
- timeout: isAnimationEnabled ? animation.content.duration : 0,
4997
- classNames: contentAnimationClassNames,
4998
- onEnter: onEnter,
4999
- onEntered: onEntered,
5000
- onExit: onExit,
5001
- onExited: onExited,
5002
- children: /*#__PURE__*/jsx(View, {
5003
- ref: contentRef,
5004
- alignItems: "center",
5005
- paddingX: "kitt.dialogModal.overlayPadding.horizontal",
5006
- paddingY: "kitt.dialogModal.overlayPadding.vertical",
5007
- margin: "auto",
5008
- children: children
5009
- })
5010
- })]
5048
+ useEffect(() => {
5049
+ if (!(!visible && isContentVisible)) return;
5050
+ if (onExit) onExit();
5051
+ setIsContentVisible(false);
5052
+ }, [visible, isContentVisible, onExit]);
5053
+ return /*#__PURE__*/jsx(Modal, {
5054
+ transparent: true,
5055
+ supportedOrientations: ['landscape', 'portrait'],
5056
+ visible: isModalVisible,
5057
+ onShow: () => {
5058
+ if (onEnter) onEnter();
5059
+ setIsContentVisible(true);
5060
+ },
5061
+ onDismiss: () => {
5062
+ if (onExited) onExited();
5063
+ },
5064
+ children: /*#__PURE__*/jsxs(View
5065
+ // This is an ugly workaround to make the Modal calculate its height correctly on Android.
5066
+ // This ugly workaround is used in FullScreenModalAnimation and CardModalAnimation as well
5067
+ // TODO [expo@>=53]: Check if still needed
5068
+ , {
5069
+ height: undefined,
5070
+ position: "relative",
5071
+ flexGrow: 1,
5072
+ justifyContent: "center",
5073
+ alignItems: "center",
5074
+ children: [/*#__PURE__*/jsx(NativeOpacityAnimation, {
5075
+ visible: isContentVisible,
5076
+ onExited: handleAnimationExited,
5077
+ children: /*#__PURE__*/jsx(Overlay, {
5078
+ onPress: onClose
5079
+ })
5080
+ }), /*#__PURE__*/jsx(NativeRotationAnimation, {
5081
+ visible: isContentVisible,
5082
+ onExited: handleAnimationExited,
5083
+ onEntered: onEntered,
5084
+ children: /*#__PURE__*/jsx(View, {
5085
+ paddingX: "kitt.dialogModal.overlayPadding.horizontal",
5086
+ paddingY: "kitt.dialogModal.overlayPadding.vertical",
5087
+ children: children
5088
+ })
5089
+ })]
5090
+ })
5011
5091
  });
5012
5092
  }
5013
5093
 
@@ -6237,6 +6317,82 @@ function ImagePicker({
6237
6317
  });
6238
6318
  }
6239
6319
 
6320
+ function InputAddressOption({
6321
+ item,
6322
+ mainText,
6323
+ secondaryText
6324
+ }) {
6325
+ const sharedTransform = {
6326
+ style: {
6327
+ transform: 'translateY(4px)'
6328
+ }
6329
+ };
6330
+ return /*#__PURE__*/jsx(Autocomplete.Option, {
6331
+ item: item,
6332
+ testID: "kitt.InputAddressOption.item",
6333
+ children: /*#__PURE__*/jsxs(HStack, {
6334
+ space: "kitt.2",
6335
+ children: [/*#__PURE__*/jsx(View, {
6336
+ _web: sharedTransform,
6337
+ _ios: sharedTransform,
6338
+ _android: sharedTransform,
6339
+ children: /*#__PURE__*/jsx(TypographyIcon, {
6340
+ icon: /*#__PURE__*/jsx(MapPinRegularIcon, {}),
6341
+ color: "black"
6342
+ })
6343
+ }), /*#__PURE__*/jsx(View, {
6344
+ flexShrink: 1,
6345
+ children: /*#__PURE__*/jsxs(Typography.Text, {
6346
+ children: [/*#__PURE__*/jsx(Typography.Text, {
6347
+ variant: "bold",
6348
+ children: mainText
6349
+ }), secondaryText ? /*#__PURE__*/jsxs(Typography.Text, {
6350
+ color: "black-light",
6351
+ variant: "bold",
6352
+ children: [' ', secondaryText]
6353
+ }) : null]
6354
+ })
6355
+ })]
6356
+ })
6357
+ });
6358
+ }
6359
+
6360
+ function InputAddress({
6361
+ errorElement,
6362
+ initialValue,
6363
+ emptyResultsElement,
6364
+ onChange,
6365
+ items,
6366
+ isLoading,
6367
+ hasError,
6368
+ onInputChange,
6369
+ onSelectItem,
6370
+ convertInitialValue,
6371
+ renderItem,
6372
+ ...props
6373
+ }) {
6374
+ const formattedInitialValue = initialValue ? convertInitialValue(initialValue) : undefined;
6375
+ return /*#__PURE__*/jsx(Autocomplete, {
6376
+ ...props,
6377
+ initialValue: formattedInitialValue,
6378
+ right: isLoading ? /*#__PURE__*/jsx(Icon, {
6379
+ icon: /*#__PURE__*/jsx(LoaderIcon, {}),
6380
+ color: "kitt.black"
6381
+ }) : undefined,
6382
+ errorElement: hasError ? errorElement : null,
6383
+ emptyResultsElement: items.length === 0 ? emptyResultsElement : null,
6384
+ onInputChange: value => onInputChange(value),
6385
+ onChange: item => onSelectItem(item, onChange),
6386
+ children: items.map(item => {
6387
+ const itemElement = renderItem(item);
6388
+ return /*#__PURE__*/cloneElement(itemElement, {
6389
+ item
6390
+ });
6391
+ })
6392
+ });
6393
+ }
6394
+ InputAddress.Option = InputAddressOption;
6395
+
6240
6396
  const GoogleMapsApiKeyContext = /*#__PURE__*/createContext(undefined);
6241
6397
  function GoogleMapsApiKeyProvider({
6242
6398
  children,
@@ -6562,7 +6718,7 @@ function useGoogleMapsAutocomplete() {
6562
6718
  return context;
6563
6719
  }
6564
6720
 
6565
- function InputAddressOption({
6721
+ function InputAddressOptionLegacy({
6566
6722
  item
6567
6723
  }) {
6568
6724
  const sharedTransform = {
@@ -6572,7 +6728,7 @@ function InputAddressOption({
6572
6728
  };
6573
6729
  return /*#__PURE__*/jsx(Autocomplete.Option, {
6574
6730
  item: item,
6575
- testID: "kitt.InputAddressOption.item",
6731
+ testID: "kitt.InputAddressOptionLegacy.item",
6576
6732
  children: /*#__PURE__*/jsxs(HStack, {
6577
6733
  space: "kitt.2",
6578
6734
  children: [/*#__PURE__*/jsx(View, {
@@ -6633,7 +6789,7 @@ function formatInitialValueToAutocompletePrediction(address, placeId) {
6633
6789
  };
6634
6790
  }
6635
6791
 
6636
- function InputAddress({
6792
+ function InputAddressLegacy({
6637
6793
  initialValue,
6638
6794
  itemToString = defaultItemToString,
6639
6795
  errorElement,
@@ -6666,12 +6822,12 @@ function InputAddress({
6666
6822
  onChange: v => {
6667
6823
  onSelectItem(v, onChange);
6668
6824
  },
6669
- children: state.items.map(item => /*#__PURE__*/jsx(InputAddressOption, {
6825
+ children: state.items.map(item => /*#__PURE__*/jsx(InputAddressOptionLegacy, {
6670
6826
  item: item
6671
6827
  }, item.place_id))
6672
6828
  });
6673
6829
  }
6674
- InputAddress.Option = InputAddressOption;
6830
+ InputAddressLegacy.Option = InputAddressOptionLegacy;
6675
6831
 
6676
6832
  const InputEmail = /*#__PURE__*/forwardRef((props, ref) => {
6677
6833
  return /*#__PURE__*/jsx(InputText, {
@@ -13635,5 +13791,5 @@ function VerticalSteps({
13635
13791
  VerticalSteps.Step = Step;
13636
13792
  VerticalSteps.BorderlessStep = BorderlessStep;
13637
13793
 
13638
- export { ActionCard, Actions, Autocomplete, Avatar, BottomSheet, Button, ButtonBadge, CardModal, Center, Checkbox, ChoicesElements, ChromaticReducedMotionDecorator, CloseIconButton, DatePicker, DialogModal, DocumentPicker, Emoji, ExternalAppLink, ExternalLink, FilePicker, FlatList, Flex, FullscreenModal, GoogleMapsApiKeyProvider, GoogleMapsAutocompleteProvider, GroupTags, HStack, Highlight, Icon, IconButton, Image, ImagePicker, InfoCard, InputAddress, InputEmail, InputFeedback, InputField, InputIban, InputIcon, InputNumber, InputPassword, InputPhone, InputPressable, InputTag, InputText, KittBreakpointNameEnum, KittBreakpoints, KittBreakpointsMax, KittMapConfigProvider, KittNativeBaseProvider, KittThemeDecorator, KittThemeProvider, Label, ListItem, LoaderIcon, MapMarker, MapMarkerVariantEnum, MatchWindowSize, Message, ModalBehaviour, NativeOnlyFlatList, NavigationBottomSheet, NavigationModal, Notification, Overlay, PageLoader, Picker, Pressable, RadioWithRef as Radio, RadioButtonGroup, ScrollView, DeprecatedSection as Section, SectionList, SegmentedProgressBar, Skeleton, SpinningIcon, Stack, StaticMap, Sticker, Story, StoryBlock, StoryContainer, StoryDecorator, StoryGrid, StorySection, StoryTitle, StyleWebWrapper, SwitchBreakpoints, TabBar, Tag, TextArea, TimePicker, ToastComponent, Toggle, Tooltip, TopNavBar, Typography, TypographyEmoji, TypographyIcon, TypographyLink, VStack, VerticalSteps, View, createChoicesComponent, createResponsiveStyleFromProp, getStaticMapImageUrl, getValueForBreakpoint, hex2rgba, matchWindowSize, storyPadding, theme, useBottomSheet, useBreakpointValue, useCurrentBreakpointName, useGetStaticMapImageUrl, useKittMapConfig, useKittTheme, useMatchWindowSize, useOpenExternalLink, useStaticBottomSheet, useStoryBlockColor, useTheme };
13794
+ export { ActionCard, Actions, Autocomplete, Avatar, BottomSheet, Button, ButtonBadge, CardModal, Center, Checkbox, ChoicesElements, ChromaticReducedMotionDecorator, CloseIconButton, DatePicker, DialogModal, DocumentPicker, Emoji, ExternalAppLink, ExternalLink, FilePicker, FlatList, Flex, FullscreenModal, GoogleMapsApiKeyProvider, GoogleMapsAutocompleteProvider, GroupTags, HStack, Highlight, Icon, IconButton, Image, ImagePicker, InfoCard, InputAddress, InputAddressLegacy, InputEmail, InputFeedback, InputField, InputIban, InputIcon, InputNumber, InputPassword, InputPhone, InputPressable, InputTag, InputText, KittBreakpointNameEnum, KittBreakpoints, KittBreakpointsMax, KittMapConfigProvider, KittNativeBaseProvider, KittThemeDecorator, KittThemeProvider, Label, ListItem, LoaderIcon, MapMarker, MapMarkerVariantEnum, MatchWindowSize, Message, ModalBehaviour, NativeOnlyFlatList, NavigationBottomSheet, NavigationModal, Notification, Overlay, PageLoader, Picker, Pressable, RadioWithRef as Radio, RadioButtonGroup, ScrollView, DeprecatedSection as Section, SectionList, SegmentedProgressBar, Skeleton, SpinningIcon, Stack, StaticMap, Sticker, Story, StoryBlock, StoryContainer, StoryDecorator, StoryGrid, StorySection, StoryTitle, StyleWebWrapper, SwitchBreakpoints, TabBar, Tag, TextArea, TimePicker, ToastComponent, Toggle, Tooltip, TopNavBar, Typography, TypographyEmoji, TypographyIcon, TypographyLink, VStack, VerticalSteps, View, createChoicesComponent, createResponsiveStyleFromProp, getStaticMapImageUrl, getValueForBreakpoint, hex2rgba, matchWindowSize, storyPadding, theme, useBottomSheet, useBreakpointValue, useCurrentBreakpointName, useGetStaticMapImageUrl, useKittMapConfig, useKittTheme, useMatchWindowSize, useOpenExternalLink, useStaticBottomSheet, useStoryBlockColor, useTheme };
13639
13795
  //# sourceMappingURL=index-node-22.17.es.web.mjs.map