@ornikar/kitt-universal 32.1.1-canary.28d1f9f68cb643b8c67559f72df59006a88da1e9.0 → 32.3.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 +10 -2
- package/dist/definitions/Choices/AnimatedChoiceItemView.d.ts +1 -2
- 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 +1 -2
- package/dist/definitions/Choices/ChoiceItem.d.ts.map +1 -1
- package/dist/definitions/Choices/ChoiceItemContainer.d.ts +1 -2
- 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 +40 -69
- package/dist/index-metro.es.android.js.map +1 -1
- package/dist/index-metro.es.ios.js +40 -69
- package/dist/index-metro.es.ios.js.map +1 -1
- package/dist/index-node-22.17.cjs.js +38 -70
- 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 +103 -128
- package/dist/index-node-22.17.cjs.web.js.map +1 -1
- package/dist/index-node-22.17.es.mjs +39 -71
- 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 +104 -129
- package/dist/index-node-22.17.es.web.mjs.map +1 -1
- package/dist/index.es.js +40 -72
- package/dist/index.es.js.map +1 -1
- package/dist/index.es.web.js +103 -128
- 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 -8
- package/dist/tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -7,7 +7,7 @@ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
|
7
7
|
import _objectDestructuringEmpty from '@babel/runtime/helpers/objectDestructuringEmpty';
|
|
8
8
|
import _extends from '@babel/runtime/helpers/extends';
|
|
9
9
|
import Animated, { useSharedValue, useAnimatedStyle, interpolateColor, withSpring, withTiming, Easing as Easing$1, runOnJS, useDerivedValue, useAnimatedProps, withDelay, withRepeat, interpolate, ReducedMotionConfig, ReduceMotion } from 'react-native-reanimated';
|
|
10
|
-
import { Platform, Animated as Animated$1, Easing, StyleSheet, Modal, Linking, Pressable as Pressable$2, Keyboard, Text as Text$1, useWindowDimensions,
|
|
10
|
+
import { Platform, Animated as Animated$1, Easing, StyleSheet, Modal, ScrollView as ScrollView$2, View as View$2, Linking, Pressable as Pressable$2, Keyboard, Text as Text$1, useWindowDimensions, PixelRatio } from 'react-native';
|
|
11
11
|
export { useWindowDimensions as useWindowSize } from 'react-native';
|
|
12
12
|
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';
|
|
13
13
|
import { BottomSheetView, BottomSheetScrollView, BottomSheetSectionList, BottomSheetFlatList, BottomSheetHandle, BottomSheetBackdrop, BottomSheetFooter, BottomSheetTextInput, BottomSheetModal, useBottomSheetModal } from '@gorhom/bottom-sheet';
|
|
@@ -860,15 +860,15 @@ const card = {
|
|
|
860
860
|
}
|
|
861
861
|
};
|
|
862
862
|
|
|
863
|
-
const webAnimationContentDuration$
|
|
864
|
-
const webAnimationContentEasing$
|
|
863
|
+
const webAnimationContentDuration$1 = 400;
|
|
864
|
+
const webAnimationContentEasing$1 = {
|
|
865
865
|
x1: 0.77,
|
|
866
866
|
y1: 0,
|
|
867
867
|
x2: 0.175,
|
|
868
868
|
y2: 1
|
|
869
869
|
};
|
|
870
|
-
const webAnimationOverlayDuration$
|
|
871
|
-
const webAnimationOverlayEasing$
|
|
870
|
+
const webAnimationOverlayDuration$1 = 250;
|
|
871
|
+
const webAnimationOverlayEasing$1 = {
|
|
872
872
|
x1: 0.42,
|
|
873
873
|
y1: 0,
|
|
874
874
|
x2: 1,
|
|
@@ -903,12 +903,12 @@ const cardModal = {
|
|
|
903
903
|
},
|
|
904
904
|
animation: {
|
|
905
905
|
overlay: {
|
|
906
|
-
duration: webAnimationOverlayDuration$
|
|
907
|
-
easing: webAnimationOverlayEasing$
|
|
906
|
+
duration: webAnimationOverlayDuration$1,
|
|
907
|
+
easing: webAnimationOverlayEasing$1
|
|
908
908
|
},
|
|
909
909
|
content: {
|
|
910
|
-
duration: webAnimationContentDuration$
|
|
911
|
-
easing: webAnimationContentEasing$
|
|
910
|
+
duration: webAnimationContentDuration$1,
|
|
911
|
+
easing: webAnimationContentEasing$1
|
|
912
912
|
}
|
|
913
913
|
}
|
|
914
914
|
};
|
|
@@ -964,15 +964,15 @@ const choices = {
|
|
|
964
964
|
}
|
|
965
965
|
};
|
|
966
966
|
|
|
967
|
-
const webAnimationContentDuration
|
|
968
|
-
const webAnimationContentEasing
|
|
967
|
+
const webAnimationContentDuration = 400;
|
|
968
|
+
const webAnimationContentEasing = {
|
|
969
969
|
x1: 0.77,
|
|
970
970
|
y1: 0,
|
|
971
971
|
x2: 0.175,
|
|
972
972
|
y2: 1
|
|
973
973
|
};
|
|
974
|
-
const webAnimationOverlayDuration
|
|
975
|
-
const webAnimationOverlayEasing
|
|
974
|
+
const webAnimationOverlayDuration = 250;
|
|
975
|
+
const webAnimationOverlayEasing = {
|
|
976
976
|
x1: 0.42,
|
|
977
977
|
y1: 0,
|
|
978
978
|
x2: 1,
|
|
@@ -994,12 +994,12 @@ const dialogModal = {
|
|
|
994
994
|
},
|
|
995
995
|
animation: {
|
|
996
996
|
overlay: {
|
|
997
|
-
duration: webAnimationOverlayDuration
|
|
998
|
-
easing: webAnimationOverlayEasing
|
|
997
|
+
duration: webAnimationOverlayDuration,
|
|
998
|
+
easing: webAnimationOverlayEasing
|
|
999
999
|
},
|
|
1000
1000
|
content: {
|
|
1001
|
-
duration: webAnimationContentDuration
|
|
1002
|
-
easing: webAnimationContentEasing
|
|
1001
|
+
duration: webAnimationContentDuration,
|
|
1002
|
+
easing: webAnimationContentEasing
|
|
1003
1003
|
}
|
|
1004
1004
|
}
|
|
1005
1005
|
};
|
|
@@ -1908,20 +1908,6 @@ const forms = {
|
|
|
1908
1908
|
timePicker
|
|
1909
1909
|
};
|
|
1910
1910
|
|
|
1911
|
-
const webAnimationContentDuration = 600;
|
|
1912
|
-
const webAnimationContentEasing = {
|
|
1913
|
-
x1: 0.77,
|
|
1914
|
-
y1: 0,
|
|
1915
|
-
x2: 0.175,
|
|
1916
|
-
y2: 1
|
|
1917
|
-
};
|
|
1918
|
-
const webAnimationOverlayDuration = 250;
|
|
1919
|
-
const webAnimationOverlayEasing = {
|
|
1920
|
-
x1: 0.42,
|
|
1921
|
-
y1: 0,
|
|
1922
|
-
x2: 1,
|
|
1923
|
-
y2: 1
|
|
1924
|
-
};
|
|
1925
1911
|
const fullscreenModal = {
|
|
1926
1912
|
header: {
|
|
1927
1913
|
height: 56
|
|
@@ -1935,12 +1921,22 @@ const fullscreenModal = {
|
|
|
1935
1921
|
},
|
|
1936
1922
|
animation: {
|
|
1937
1923
|
overlay: {
|
|
1938
|
-
duration:
|
|
1939
|
-
easing:
|
|
1924
|
+
duration: 250,
|
|
1925
|
+
easing: {
|
|
1926
|
+
x1: 0.42,
|
|
1927
|
+
y1: 0,
|
|
1928
|
+
x2: 1,
|
|
1929
|
+
y2: 1
|
|
1930
|
+
}
|
|
1940
1931
|
},
|
|
1941
1932
|
content: {
|
|
1942
|
-
duration:
|
|
1943
|
-
easing:
|
|
1933
|
+
duration: 600,
|
|
1934
|
+
easing: {
|
|
1935
|
+
x1: 0.77,
|
|
1936
|
+
y1: 0,
|
|
1937
|
+
x2: 0.175,
|
|
1938
|
+
y2: 1
|
|
1939
|
+
}
|
|
1944
1940
|
}
|
|
1945
1941
|
}
|
|
1946
1942
|
};
|
|
@@ -4811,7 +4807,6 @@ function AnimatedChoiceItemView({
|
|
|
4811
4807
|
isDisabled,
|
|
4812
4808
|
isSelected,
|
|
4813
4809
|
hasError,
|
|
4814
|
-
shouldExpand = false,
|
|
4815
4810
|
animatedStyles
|
|
4816
4811
|
}) {
|
|
4817
4812
|
const sx = useSx();
|
|
@@ -4830,9 +4825,7 @@ function AnimatedChoiceItemView({
|
|
|
4830
4825
|
isHovered,
|
|
4831
4826
|
isPressed
|
|
4832
4827
|
}),
|
|
4833
|
-
padding: size === 'small' ? 'kitt.2' : 'kitt.4'
|
|
4834
|
-
flexGrow: shouldExpand ? 1 : undefined,
|
|
4835
|
-
flexShrink: shouldExpand ? 1 : undefined
|
|
4828
|
+
padding: size === 'small' ? 'kitt.2' : 'kitt.4'
|
|
4836
4829
|
});
|
|
4837
4830
|
return /*#__PURE__*/jsx(Animated.View, {
|
|
4838
4831
|
style: [style, animatedStyles],
|
|
@@ -4896,7 +4889,6 @@ function ChoiceItem({
|
|
|
4896
4889
|
value,
|
|
4897
4890
|
selected,
|
|
4898
4891
|
disabled,
|
|
4899
|
-
shouldExpand = false,
|
|
4900
4892
|
children,
|
|
4901
4893
|
isPressedInternal,
|
|
4902
4894
|
isHoveredInternal,
|
|
@@ -4936,8 +4928,6 @@ function ChoiceItem({
|
|
|
4936
4928
|
checked: selected
|
|
4937
4929
|
},
|
|
4938
4930
|
style: style,
|
|
4939
|
-
flexGrow: shouldExpand ? 1 : undefined,
|
|
4940
|
-
flexShrink: shouldExpand ? 1 : undefined,
|
|
4941
4931
|
onBlur: onBlur,
|
|
4942
4932
|
onFocus: onFocus,
|
|
4943
4933
|
onPress: e => {
|
|
@@ -4957,8 +4947,6 @@ function ChoiceItem({
|
|
|
4957
4947
|
});
|
|
4958
4948
|
return /*#__PURE__*/jsxs(VStack, {
|
|
4959
4949
|
space: "kitt.2",
|
|
4960
|
-
flexGrow: shouldExpand ? 1 : undefined,
|
|
4961
|
-
flexShrink: shouldExpand ? 1 : undefined,
|
|
4962
4950
|
children: [/*#__PURE__*/jsxs(AnimatedChoiceItemView, {
|
|
4963
4951
|
animatedStyles: backgroundStyles,
|
|
4964
4952
|
isHovered: isHovered || isHoveredInternal,
|
|
@@ -4966,13 +4954,10 @@ function ChoiceItem({
|
|
|
4966
4954
|
isSelected: selected,
|
|
4967
4955
|
isPressed: isPressed || isPressedInternal,
|
|
4968
4956
|
hasError: hasError,
|
|
4969
|
-
shouldExpand: shouldExpand,
|
|
4970
4957
|
size: size,
|
|
4971
4958
|
children: [/*#__PURE__*/jsxs(Stack, {
|
|
4972
4959
|
alignItems: "center",
|
|
4973
4960
|
space: "kitt.2",
|
|
4974
|
-
flexGrow: shouldExpand ? 1 : undefined,
|
|
4975
|
-
flexShrink: shouldExpand ? 1 : undefined,
|
|
4976
4961
|
children: [icon ? /*#__PURE__*/jsx(TypographyIcon, {
|
|
4977
4962
|
color: textColor,
|
|
4978
4963
|
icon: icon
|
|
@@ -5001,46 +4986,36 @@ function ChoiceItem({
|
|
|
5001
4986
|
function ChoiceItemContainer({
|
|
5002
4987
|
children,
|
|
5003
4988
|
direction,
|
|
5004
|
-
shouldExpand,
|
|
5005
4989
|
isLast
|
|
5006
4990
|
}) {
|
|
5007
4991
|
const currentItemMarginValue = isLast ? undefined : 'kitt.3';
|
|
5008
|
-
const
|
|
4992
|
+
const flexProps = direction === 'row' ? {
|
|
5009
4993
|
flexGrow: 1,
|
|
5010
4994
|
flexShrink: 1,
|
|
5011
4995
|
flexBasis: 0
|
|
5012
4996
|
} : {};
|
|
5013
|
-
|
|
5014
|
-
flexGrow: 1,
|
|
5015
|
-
flexShrink: 1
|
|
5016
|
-
} : {};
|
|
5017
|
-
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread(_objectSpread({
|
|
4997
|
+
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({
|
|
5018
4998
|
marginRight: direction === 'row' ? currentItemMarginValue : undefined,
|
|
5019
4999
|
marginBottom: direction === 'column' ? currentItemMarginValue : undefined
|
|
5020
|
-
},
|
|
5000
|
+
}, flexProps), {}, {
|
|
5021
5001
|
children: children
|
|
5022
5002
|
}));
|
|
5023
5003
|
}
|
|
5024
5004
|
|
|
5025
|
-
const _excluded$G = ["direction", "
|
|
5005
|
+
const _excluded$G = ["direction", "contentContainerStyle"];
|
|
5026
5006
|
function ChoicesContainer(_ref) {
|
|
5027
5007
|
let {
|
|
5028
5008
|
direction,
|
|
5029
|
-
shouldExpand,
|
|
5030
5009
|
contentContainerStyle
|
|
5031
5010
|
} = _ref,
|
|
5032
5011
|
props = _objectWithoutProperties(_ref, _excluded$G);
|
|
5033
|
-
const shouldExpandFlexProps = shouldExpand ? {
|
|
5034
|
-
flexGrow: 1,
|
|
5035
|
-
flexShrink: 1
|
|
5036
|
-
} : {};
|
|
5037
5012
|
if (direction === 'row') {
|
|
5038
|
-
return /*#__PURE__*/jsx(ScrollView, _objectSpread(
|
|
5013
|
+
return /*#__PURE__*/jsx(ScrollView$2, _objectSpread({
|
|
5039
5014
|
horizontal: true,
|
|
5040
|
-
contentContainerStyle:
|
|
5041
|
-
}, props)
|
|
5015
|
+
contentContainerStyle: contentContainerStyle
|
|
5016
|
+
}, props));
|
|
5042
5017
|
}
|
|
5043
|
-
return /*#__PURE__*/jsx(View, _objectSpread(
|
|
5018
|
+
return /*#__PURE__*/jsx(View$2, _objectSpread({}, props));
|
|
5044
5019
|
}
|
|
5045
5020
|
|
|
5046
5021
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
@@ -5051,7 +5026,6 @@ function Choices({
|
|
|
5051
5026
|
type,
|
|
5052
5027
|
direction = 'column',
|
|
5053
5028
|
disabled,
|
|
5054
|
-
shouldExpand = false,
|
|
5055
5029
|
children,
|
|
5056
5030
|
value,
|
|
5057
5031
|
onPress,
|
|
@@ -5068,7 +5042,6 @@ function Choices({
|
|
|
5068
5042
|
const sharedProps = {
|
|
5069
5043
|
type,
|
|
5070
5044
|
disabled,
|
|
5071
|
-
shouldExpand,
|
|
5072
5045
|
onPress: !isForm ? onPress : undefined,
|
|
5073
5046
|
onChange: isForm ? newValue => {
|
|
5074
5047
|
setCurrentValue(newValue);
|
|
@@ -5080,7 +5053,6 @@ function Choices({
|
|
|
5080
5053
|
};
|
|
5081
5054
|
return /*#__PURE__*/jsx(ChoicesContainer, {
|
|
5082
5055
|
direction: direction,
|
|
5083
|
-
shouldExpand: shouldExpand,
|
|
5084
5056
|
testID: testID,
|
|
5085
5057
|
id: id,
|
|
5086
5058
|
style: style,
|
|
@@ -5091,7 +5063,6 @@ function Choices({
|
|
|
5091
5063
|
}, sharedProps));
|
|
5092
5064
|
return /*#__PURE__*/jsx(ChoiceItemContainer, {
|
|
5093
5065
|
direction: direction,
|
|
5094
|
-
shouldExpand: shouldExpand,
|
|
5095
5066
|
isLast: index === childrenArray.length - 1,
|
|
5096
5067
|
children: element
|
|
5097
5068
|
}, child.key);
|