@ornikar/kitt-universal 32.2.1-canary.b6a558c2a534e5d22cad1dfac7725ddeca489e44.0 → 32.3.1-canary.e5e3462569f2f32f91e8d06437eb0642c84cb55f.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 +11 -2
- package/dist/definitions/Choices/AnimatedChoiceItemView.d.ts +2 -1
- package/dist/definitions/Choices/AnimatedChoiceItemView.d.ts.map +1 -1
- package/dist/definitions/Choices/AnimatedChoiceItemView.web.d.ts +1 -1
- package/dist/definitions/Choices/AnimatedChoiceItemView.web.d.ts.map +1 -1
- package/dist/definitions/Choices/ChoiceItem.d.ts +2 -1
- package/dist/definitions/Choices/ChoiceItem.d.ts.map +1 -1
- package/dist/definitions/Choices/ChoiceItemContainer.d.ts +2 -1
- package/dist/definitions/Choices/ChoiceItemContainer.d.ts.map +1 -1
- package/dist/definitions/Choices/Choices.d.ts +5 -5
- package/dist/definitions/Choices/Choices.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 +69 -48
- package/dist/index-metro.es.android.js.map +1 -1
- package/dist/index-metro.es.ios.js +69 -48
- package/dist/index-metro.es.ios.js.map +1 -1
- package/dist/index-node-22.17.cjs.js +70 -46
- package/dist/index-node-22.17.cjs.js.map +1 -1
- package/dist/index-node-22.17.cjs.web.css +38 -8
- package/dist/index-node-22.17.cjs.web.js +135 -104
- package/dist/index-node-22.17.cjs.web.js.map +1 -1
- package/dist/index-node-22.17.es.mjs +71 -47
- package/dist/index-node-22.17.es.mjs.map +1 -1
- package/dist/index-node-22.17.es.web.css +38 -8
- package/dist/index-node-22.17.es.web.mjs +136 -105
- package/dist/index-node-22.17.es.web.mjs.map +1 -1
- package/dist/index.es.js +72 -48
- package/dist/index.es.js.map +1 -1
- package/dist/index.es.web.js +135 -104
- package/dist/index.es.web.js.map +1 -1
- package/dist/linaria-themes-metro.es.android.js +34 -38
- package/dist/linaria-themes-metro.es.android.js.map +1 -1
- package/dist/linaria-themes-metro.es.ios.js +34 -38
- package/dist/linaria-themes-metro.es.ios.js.map +1 -1
- package/dist/linaria-themes-node-22.17.cjs.js +34 -38
- package/dist/linaria-themes-node-22.17.cjs.js.map +1 -1
- package/dist/linaria-themes-node-22.17.cjs.web.js +34 -38
- package/dist/linaria-themes-node-22.17.cjs.web.js.map +1 -1
- package/dist/linaria-themes-node-22.17.es.mjs +34 -38
- package/dist/linaria-themes-node-22.17.es.mjs.map +1 -1
- package/dist/linaria-themes-node-22.17.es.web.mjs +34 -38
- package/dist/linaria-themes-node-22.17.es.web.mjs.map +1 -1
- package/dist/linaria-themes.es.js +34 -38
- package/dist/linaria-themes.es.js.map +1 -1
- package/dist/linaria-themes.es.web.js +34 -38
- package/dist/linaria-themes.es.web.js.map +1 -1
- package/dist/styles.css +38 -8
- package/dist/tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -3,7 +3,7 @@ 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 Animated, { useSharedValue, useAnimatedStyle, interpolateColor, withSpring, withTiming, Easing as Easing$1, runOnJS, useDerivedValue, useAnimatedProps, withDelay, withRepeat, interpolate, ReducedMotionConfig, ReduceMotion } from 'react-native-reanimated';
|
|
6
|
-
import { Platform, Animated as Animated$1, Easing, StyleSheet, Modal,
|
|
6
|
+
import { Platform, Animated as Animated$1, Easing, StyleSheet, Modal, Linking, Pressable as Pressable$2, Keyboard, Text as Text$1, useWindowDimensions, ScrollView as ScrollView$2, PixelRatio } from 'react-native';
|
|
7
7
|
export { useWindowDimensions as useWindowSize } from 'react-native';
|
|
8
8
|
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';
|
|
9
9
|
import { BottomSheetView, BottomSheetScrollView, BottomSheetSectionList, BottomSheetFlatList, BottomSheetHandle, BottomSheetBackdrop, BottomSheetFooter, BottomSheetTextInput, BottomSheetModal, useBottomSheetModal } from '@gorhom/bottom-sheet';
|
|
@@ -857,15 +857,15 @@ const card = {
|
|
|
857
857
|
}
|
|
858
858
|
};
|
|
859
859
|
|
|
860
|
-
const webAnimationContentDuration$
|
|
861
|
-
const webAnimationContentEasing$
|
|
860
|
+
const webAnimationContentDuration$1 = 400;
|
|
861
|
+
const webAnimationContentEasing$1 = {
|
|
862
862
|
x1: 0.77,
|
|
863
863
|
y1: 0,
|
|
864
864
|
x2: 0.175,
|
|
865
865
|
y2: 1
|
|
866
866
|
};
|
|
867
|
-
const webAnimationOverlayDuration$
|
|
868
|
-
const webAnimationOverlayEasing$
|
|
867
|
+
const webAnimationOverlayDuration$1 = 250;
|
|
868
|
+
const webAnimationOverlayEasing$1 = {
|
|
869
869
|
x1: 0.42,
|
|
870
870
|
y1: 0,
|
|
871
871
|
x2: 1,
|
|
@@ -900,12 +900,12 @@ const cardModal = {
|
|
|
900
900
|
},
|
|
901
901
|
animation: {
|
|
902
902
|
overlay: {
|
|
903
|
-
duration: webAnimationOverlayDuration$
|
|
904
|
-
easing: webAnimationOverlayEasing$
|
|
903
|
+
duration: webAnimationOverlayDuration$1,
|
|
904
|
+
easing: webAnimationOverlayEasing$1
|
|
905
905
|
},
|
|
906
906
|
content: {
|
|
907
|
-
duration: webAnimationContentDuration$
|
|
908
|
-
easing: webAnimationContentEasing$
|
|
907
|
+
duration: webAnimationContentDuration$1,
|
|
908
|
+
easing: webAnimationContentEasing$1
|
|
909
909
|
}
|
|
910
910
|
}
|
|
911
911
|
};
|
|
@@ -961,15 +961,15 @@ const choices = {
|
|
|
961
961
|
}
|
|
962
962
|
};
|
|
963
963
|
|
|
964
|
-
const webAnimationContentDuration
|
|
965
|
-
const webAnimationContentEasing
|
|
964
|
+
const webAnimationContentDuration = 400;
|
|
965
|
+
const webAnimationContentEasing = {
|
|
966
966
|
x1: 0.77,
|
|
967
967
|
y1: 0,
|
|
968
968
|
x2: 0.175,
|
|
969
969
|
y2: 1
|
|
970
970
|
};
|
|
971
|
-
const webAnimationOverlayDuration
|
|
972
|
-
const webAnimationOverlayEasing
|
|
971
|
+
const webAnimationOverlayDuration = 250;
|
|
972
|
+
const webAnimationOverlayEasing = {
|
|
973
973
|
x1: 0.42,
|
|
974
974
|
y1: 0,
|
|
975
975
|
x2: 1,
|
|
@@ -991,12 +991,12 @@ const dialogModal = {
|
|
|
991
991
|
},
|
|
992
992
|
animation: {
|
|
993
993
|
overlay: {
|
|
994
|
-
duration: webAnimationOverlayDuration
|
|
995
|
-
easing: webAnimationOverlayEasing
|
|
994
|
+
duration: webAnimationOverlayDuration,
|
|
995
|
+
easing: webAnimationOverlayEasing
|
|
996
996
|
},
|
|
997
997
|
content: {
|
|
998
|
-
duration: webAnimationContentDuration
|
|
999
|
-
easing: webAnimationContentEasing
|
|
998
|
+
duration: webAnimationContentDuration,
|
|
999
|
+
easing: webAnimationContentEasing
|
|
1000
1000
|
}
|
|
1001
1001
|
}
|
|
1002
1002
|
};
|
|
@@ -1054,10 +1054,10 @@ const autocomplete = {
|
|
|
1054
1054
|
};
|
|
1055
1055
|
|
|
1056
1056
|
const checkbox = {
|
|
1057
|
-
borderWidth:
|
|
1058
|
-
borderRadius:
|
|
1059
|
-
height:
|
|
1060
|
-
width:
|
|
1057
|
+
borderWidth: 2,
|
|
1058
|
+
borderRadius: 5,
|
|
1059
|
+
height: 20,
|
|
1060
|
+
width: 20,
|
|
1061
1061
|
iconSize: 14,
|
|
1062
1062
|
markColor: colors.uiBackgroundLight,
|
|
1063
1063
|
textSpacing: 10,
|
|
@@ -1905,20 +1905,6 @@ const forms = {
|
|
|
1905
1905
|
timePicker
|
|
1906
1906
|
};
|
|
1907
1907
|
|
|
1908
|
-
const webAnimationContentDuration = 600;
|
|
1909
|
-
const webAnimationContentEasing = {
|
|
1910
|
-
x1: 0.77,
|
|
1911
|
-
y1: 0,
|
|
1912
|
-
x2: 0.175,
|
|
1913
|
-
y2: 1
|
|
1914
|
-
};
|
|
1915
|
-
const webAnimationOverlayDuration = 250;
|
|
1916
|
-
const webAnimationOverlayEasing = {
|
|
1917
|
-
x1: 0.42,
|
|
1918
|
-
y1: 0,
|
|
1919
|
-
x2: 1,
|
|
1920
|
-
y2: 1
|
|
1921
|
-
};
|
|
1922
1908
|
const fullscreenModal = {
|
|
1923
1909
|
header: {
|
|
1924
1910
|
height: 56
|
|
@@ -1932,12 +1918,22 @@ const fullscreenModal = {
|
|
|
1932
1918
|
},
|
|
1933
1919
|
animation: {
|
|
1934
1920
|
overlay: {
|
|
1935
|
-
duration:
|
|
1936
|
-
easing:
|
|
1921
|
+
duration: 250,
|
|
1922
|
+
easing: {
|
|
1923
|
+
x1: 0.42,
|
|
1924
|
+
y1: 0,
|
|
1925
|
+
x2: 1,
|
|
1926
|
+
y2: 1
|
|
1927
|
+
}
|
|
1937
1928
|
},
|
|
1938
1929
|
content: {
|
|
1939
|
-
duration:
|
|
1940
|
-
easing:
|
|
1930
|
+
duration: 600,
|
|
1931
|
+
easing: {
|
|
1932
|
+
x1: 0.77,
|
|
1933
|
+
y1: 0,
|
|
1934
|
+
x2: 0.175,
|
|
1935
|
+
y2: 1
|
|
1936
|
+
}
|
|
1941
1937
|
}
|
|
1942
1938
|
}
|
|
1943
1939
|
};
|
|
@@ -4814,6 +4810,7 @@ function AnimatedChoiceItemView({
|
|
|
4814
4810
|
isDisabled,
|
|
4815
4811
|
isSelected,
|
|
4816
4812
|
hasError,
|
|
4813
|
+
shouldExpand = false,
|
|
4817
4814
|
animatedStyles
|
|
4818
4815
|
}) {
|
|
4819
4816
|
const sx = useSx();
|
|
@@ -4832,7 +4829,9 @@ function AnimatedChoiceItemView({
|
|
|
4832
4829
|
isHovered,
|
|
4833
4830
|
isPressed
|
|
4834
4831
|
}),
|
|
4835
|
-
padding: size === 'small' ? 'kitt.2' : 'kitt.4'
|
|
4832
|
+
padding: size === 'small' ? 'kitt.2' : 'kitt.4',
|
|
4833
|
+
flexGrow: shouldExpand ? 1 : undefined,
|
|
4834
|
+
flexShrink: shouldExpand ? 1 : undefined
|
|
4836
4835
|
});
|
|
4837
4836
|
return /*#__PURE__*/jsx(Animated.View, {
|
|
4838
4837
|
style: [style, animatedStyles],
|
|
@@ -4896,6 +4895,7 @@ function ChoiceItem({
|
|
|
4896
4895
|
value,
|
|
4897
4896
|
selected,
|
|
4898
4897
|
disabled,
|
|
4898
|
+
shouldExpand = false,
|
|
4899
4899
|
children,
|
|
4900
4900
|
isPressedInternal,
|
|
4901
4901
|
isHoveredInternal,
|
|
@@ -4935,6 +4935,8 @@ function ChoiceItem({
|
|
|
4935
4935
|
checked: selected
|
|
4936
4936
|
},
|
|
4937
4937
|
style: style,
|
|
4938
|
+
flexGrow: shouldExpand ? 1 : undefined,
|
|
4939
|
+
flexShrink: shouldExpand ? 1 : undefined,
|
|
4938
4940
|
onBlur: onBlur,
|
|
4939
4941
|
onFocus: onFocus,
|
|
4940
4942
|
onPress: e => {
|
|
@@ -4954,6 +4956,8 @@ function ChoiceItem({
|
|
|
4954
4956
|
});
|
|
4955
4957
|
return /*#__PURE__*/jsxs(VStack, {
|
|
4956
4958
|
space: "kitt.2",
|
|
4959
|
+
flexGrow: shouldExpand ? 1 : undefined,
|
|
4960
|
+
flexShrink: shouldExpand ? 1 : undefined,
|
|
4957
4961
|
children: [/*#__PURE__*/jsxs(AnimatedChoiceItemView, {
|
|
4958
4962
|
animatedStyles: backgroundStyles,
|
|
4959
4963
|
isHovered: isHovered || isHoveredInternal,
|
|
@@ -4961,10 +4965,13 @@ function ChoiceItem({
|
|
|
4961
4965
|
isSelected: selected,
|
|
4962
4966
|
isPressed: isPressed || isPressedInternal,
|
|
4963
4967
|
hasError: hasError,
|
|
4968
|
+
shouldExpand: shouldExpand,
|
|
4964
4969
|
size: size,
|
|
4965
4970
|
children: [/*#__PURE__*/jsxs(Stack, {
|
|
4966
4971
|
alignItems: "center",
|
|
4967
4972
|
space: "kitt.2",
|
|
4973
|
+
flexGrow: shouldExpand ? 1 : undefined,
|
|
4974
|
+
flexShrink: shouldExpand ? 1 : undefined,
|
|
4968
4975
|
children: [icon ? /*#__PURE__*/jsx(TypographyIcon, {
|
|
4969
4976
|
color: textColor,
|
|
4970
4977
|
icon: icon
|
|
@@ -4993,36 +5000,49 @@ function ChoiceItem({
|
|
|
4993
5000
|
function ChoiceItemContainer({
|
|
4994
5001
|
children,
|
|
4995
5002
|
direction,
|
|
5003
|
+
shouldExpand,
|
|
4996
5004
|
isLast
|
|
4997
5005
|
}) {
|
|
4998
5006
|
const currentItemMarginValue = isLast ? undefined : 'kitt.3';
|
|
4999
|
-
const
|
|
5007
|
+
const directionFlexProps = direction === 'row' ? {
|
|
5000
5008
|
flexGrow: 1,
|
|
5001
5009
|
flexShrink: 1,
|
|
5002
5010
|
flexBasis: 0
|
|
5003
5011
|
} : {};
|
|
5012
|
+
const shouldExpandFlexProps = shouldExpand ? {
|
|
5013
|
+
flexGrow: 1,
|
|
5014
|
+
flexShrink: 1
|
|
5015
|
+
} : {};
|
|
5004
5016
|
return /*#__PURE__*/jsx(View, {
|
|
5005
5017
|
marginRight: direction === 'row' ? currentItemMarginValue : undefined,
|
|
5006
5018
|
marginBottom: direction === 'column' ? currentItemMarginValue : undefined,
|
|
5007
|
-
...
|
|
5019
|
+
...directionFlexProps,
|
|
5020
|
+
...shouldExpandFlexProps,
|
|
5008
5021
|
children: children
|
|
5009
5022
|
});
|
|
5010
5023
|
}
|
|
5011
5024
|
|
|
5012
5025
|
function ChoicesContainer({
|
|
5013
5026
|
direction,
|
|
5027
|
+
shouldExpand,
|
|
5014
5028
|
contentContainerStyle,
|
|
5015
5029
|
...props
|
|
5016
5030
|
}) {
|
|
5031
|
+
const shouldExpandFlexProps = shouldExpand ? {
|
|
5032
|
+
flexGrow: 1,
|
|
5033
|
+
flexShrink: 1
|
|
5034
|
+
} : {};
|
|
5017
5035
|
if (direction === 'row') {
|
|
5018
|
-
return /*#__PURE__*/jsx(ScrollView
|
|
5036
|
+
return /*#__PURE__*/jsx(ScrollView, {
|
|
5019
5037
|
horizontal: true,
|
|
5020
|
-
contentContainerStyle: contentContainerStyle,
|
|
5021
|
-
...props
|
|
5038
|
+
contentContainerStyle: shouldExpand ? shouldExpandFlexProps : contentContainerStyle,
|
|
5039
|
+
...props,
|
|
5040
|
+
...shouldExpandFlexProps
|
|
5022
5041
|
});
|
|
5023
5042
|
}
|
|
5024
|
-
return /*#__PURE__*/jsx(View
|
|
5025
|
-
...props
|
|
5043
|
+
return /*#__PURE__*/jsx(View, {
|
|
5044
|
+
...props,
|
|
5045
|
+
...shouldExpandFlexProps
|
|
5026
5046
|
});
|
|
5027
5047
|
}
|
|
5028
5048
|
|
|
@@ -5034,6 +5054,7 @@ function Choices({
|
|
|
5034
5054
|
type,
|
|
5035
5055
|
direction = 'column',
|
|
5036
5056
|
disabled,
|
|
5057
|
+
shouldExpand = false,
|
|
5037
5058
|
children,
|
|
5038
5059
|
value,
|
|
5039
5060
|
onPress,
|
|
@@ -5050,6 +5071,7 @@ function Choices({
|
|
|
5050
5071
|
const sharedProps = {
|
|
5051
5072
|
type,
|
|
5052
5073
|
disabled,
|
|
5074
|
+
shouldExpand,
|
|
5053
5075
|
onPress: !isForm ? onPress : undefined,
|
|
5054
5076
|
onChange: isForm ? newValue => {
|
|
5055
5077
|
setCurrentValue(newValue);
|
|
@@ -5061,6 +5083,7 @@ function Choices({
|
|
|
5061
5083
|
};
|
|
5062
5084
|
return /*#__PURE__*/jsx(ChoicesContainer, {
|
|
5063
5085
|
direction: direction,
|
|
5086
|
+
shouldExpand: shouldExpand,
|
|
5064
5087
|
testID: testID,
|
|
5065
5088
|
id: id,
|
|
5066
5089
|
style: style,
|
|
@@ -5072,6 +5095,7 @@ function Choices({
|
|
|
5072
5095
|
});
|
|
5073
5096
|
return /*#__PURE__*/jsx(ChoiceItemContainer, {
|
|
5074
5097
|
direction: direction,
|
|
5098
|
+
shouldExpand: shouldExpand,
|
|
5075
5099
|
isLast: index === childrenArray.length - 1,
|
|
5076
5100
|
children: element
|
|
5077
5101
|
}, child.key);
|