@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.
Files changed (51) hide show
  1. package/CHANGELOG.md +11 -2
  2. package/dist/definitions/Choices/AnimatedChoiceItemView.d.ts +2 -1
  3. package/dist/definitions/Choices/AnimatedChoiceItemView.d.ts.map +1 -1
  4. package/dist/definitions/Choices/AnimatedChoiceItemView.web.d.ts +1 -1
  5. package/dist/definitions/Choices/AnimatedChoiceItemView.web.d.ts.map +1 -1
  6. package/dist/definitions/Choices/ChoiceItem.d.ts +2 -1
  7. package/dist/definitions/Choices/ChoiceItem.d.ts.map +1 -1
  8. package/dist/definitions/Choices/ChoiceItemContainer.d.ts +2 -1
  9. package/dist/definitions/Choices/ChoiceItemContainer.d.ts.map +1 -1
  10. package/dist/definitions/Choices/Choices.d.ts +5 -5
  11. package/dist/definitions/Choices/Choices.d.ts.map +1 -1
  12. package/dist/definitions/FullscreenModal/FullscreenModalAnimation.web.d.ts.map +1 -1
  13. package/dist/definitions/themes/late-ocean/fullscreenModal.d.ts +0 -14
  14. package/dist/definitions/themes/late-ocean/fullscreenModal.d.ts.map +1 -1
  15. package/dist/index-metro.es.android.js +69 -48
  16. package/dist/index-metro.es.android.js.map +1 -1
  17. package/dist/index-metro.es.ios.js +69 -48
  18. package/dist/index-metro.es.ios.js.map +1 -1
  19. package/dist/index-node-22.17.cjs.js +70 -46
  20. package/dist/index-node-22.17.cjs.js.map +1 -1
  21. package/dist/index-node-22.17.cjs.web.css +38 -8
  22. package/dist/index-node-22.17.cjs.web.js +135 -104
  23. package/dist/index-node-22.17.cjs.web.js.map +1 -1
  24. package/dist/index-node-22.17.es.mjs +71 -47
  25. package/dist/index-node-22.17.es.mjs.map +1 -1
  26. package/dist/index-node-22.17.es.web.css +38 -8
  27. package/dist/index-node-22.17.es.web.mjs +136 -105
  28. package/dist/index-node-22.17.es.web.mjs.map +1 -1
  29. package/dist/index.es.js +72 -48
  30. package/dist/index.es.js.map +1 -1
  31. package/dist/index.es.web.js +135 -104
  32. package/dist/index.es.web.js.map +1 -1
  33. package/dist/linaria-themes-metro.es.android.js +34 -38
  34. package/dist/linaria-themes-metro.es.android.js.map +1 -1
  35. package/dist/linaria-themes-metro.es.ios.js +34 -38
  36. package/dist/linaria-themes-metro.es.ios.js.map +1 -1
  37. package/dist/linaria-themes-node-22.17.cjs.js +34 -38
  38. package/dist/linaria-themes-node-22.17.cjs.js.map +1 -1
  39. package/dist/linaria-themes-node-22.17.cjs.web.js +34 -38
  40. package/dist/linaria-themes-node-22.17.cjs.web.js.map +1 -1
  41. package/dist/linaria-themes-node-22.17.es.mjs +34 -38
  42. package/dist/linaria-themes-node-22.17.es.mjs.map +1 -1
  43. package/dist/linaria-themes-node-22.17.es.web.mjs +34 -38
  44. package/dist/linaria-themes-node-22.17.es.web.mjs.map +1 -1
  45. package/dist/linaria-themes.es.js +34 -38
  46. package/dist/linaria-themes.es.js.map +1 -1
  47. package/dist/linaria-themes.es.web.js +34 -38
  48. package/dist/linaria-themes.es.web.js.map +1 -1
  49. package/dist/styles.css +38 -8
  50. package/dist/tsbuildinfo +1 -1
  51. package/package.json +1 -1
package/dist/index.es.js CHANGED
@@ -8,7 +8,7 @@ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
8
8
  import _objectDestructuringEmpty from '@babel/runtime/helpers/objectDestructuringEmpty';
9
9
  import _extends from '@babel/runtime/helpers/extends';
10
10
  import Animated, { useSharedValue, useAnimatedStyle, interpolateColor, withSpring, withTiming, Easing as Easing$1, runOnJS, useDerivedValue, useAnimatedProps, withDelay, withRepeat, interpolate, ReducedMotionConfig, ReduceMotion } from 'react-native-reanimated';
11
- 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
+ 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';
12
12
  export { useWindowDimensions as useWindowSize } from 'react-native';
13
13
  import _typeof from '@babel/runtime/helpers/typeof';
14
14
  import _regeneratorRuntime from '@babel/runtime/helpers/regeneratorRuntime';
@@ -875,15 +875,15 @@ var card = {
875
875
  }
876
876
  };
877
877
 
878
- var webAnimationContentDuration$2 = 400;
879
- var webAnimationContentEasing$2 = {
878
+ var webAnimationContentDuration$1 = 400;
879
+ var webAnimationContentEasing$1 = {
880
880
  x1: 0.77,
881
881
  y1: 0,
882
882
  x2: 0.175,
883
883
  y2: 1
884
884
  };
885
- var webAnimationOverlayDuration$2 = 250;
886
- var webAnimationOverlayEasing$2 = {
885
+ var webAnimationOverlayDuration$1 = 250;
886
+ var webAnimationOverlayEasing$1 = {
887
887
  x1: 0.42,
888
888
  y1: 0,
889
889
  x2: 1,
@@ -918,12 +918,12 @@ var cardModal = {
918
918
  },
919
919
  animation: {
920
920
  overlay: {
921
- duration: webAnimationOverlayDuration$2,
922
- easing: webAnimationOverlayEasing$2
921
+ duration: webAnimationOverlayDuration$1,
922
+ easing: webAnimationOverlayEasing$1
923
923
  },
924
924
  content: {
925
- duration: webAnimationContentDuration$2,
926
- easing: webAnimationContentEasing$2
925
+ duration: webAnimationContentDuration$1,
926
+ easing: webAnimationContentEasing$1
927
927
  }
928
928
  }
929
929
  };
@@ -979,15 +979,15 @@ var choices = {
979
979
  }
980
980
  };
981
981
 
982
- var webAnimationContentDuration$1 = 400;
983
- var webAnimationContentEasing$1 = {
982
+ var webAnimationContentDuration = 400;
983
+ var webAnimationContentEasing = {
984
984
  x1: 0.77,
985
985
  y1: 0,
986
986
  x2: 0.175,
987
987
  y2: 1
988
988
  };
989
- var webAnimationOverlayDuration$1 = 250;
990
- var webAnimationOverlayEasing$1 = {
989
+ var webAnimationOverlayDuration = 250;
990
+ var webAnimationOverlayEasing = {
991
991
  x1: 0.42,
992
992
  y1: 0,
993
993
  x2: 1,
@@ -1009,12 +1009,12 @@ var dialogModal = {
1009
1009
  },
1010
1010
  animation: {
1011
1011
  overlay: {
1012
- duration: webAnimationOverlayDuration$1,
1013
- easing: webAnimationOverlayEasing$1
1012
+ duration: webAnimationOverlayDuration,
1013
+ easing: webAnimationOverlayEasing
1014
1014
  },
1015
1015
  content: {
1016
- duration: webAnimationContentDuration$1,
1017
- easing: webAnimationContentEasing$1
1016
+ duration: webAnimationContentDuration,
1017
+ easing: webAnimationContentEasing
1018
1018
  }
1019
1019
  }
1020
1020
  };
@@ -1072,10 +1072,10 @@ var autocomplete = {
1072
1072
  };
1073
1073
 
1074
1074
  var checkbox = {
1075
- borderWidth: 1,
1076
- borderRadius: 4,
1077
- height: 24,
1078
- width: 24,
1075
+ borderWidth: 2,
1076
+ borderRadius: 5,
1077
+ height: 20,
1078
+ width: 20,
1079
1079
  iconSize: 14,
1080
1080
  markColor: colors.uiBackgroundLight,
1081
1081
  textSpacing: 10,
@@ -1923,20 +1923,6 @@ var forms = {
1923
1923
  timePicker: timePicker
1924
1924
  };
1925
1925
 
1926
- var webAnimationContentDuration = 600;
1927
- var webAnimationContentEasing = {
1928
- x1: 0.77,
1929
- y1: 0,
1930
- x2: 0.175,
1931
- y2: 1
1932
- };
1933
- var webAnimationOverlayDuration = 250;
1934
- var webAnimationOverlayEasing = {
1935
- x1: 0.42,
1936
- y1: 0,
1937
- x2: 1,
1938
- y2: 1
1939
- };
1940
1926
  var fullscreenModal = {
1941
1927
  header: {
1942
1928
  height: 56
@@ -1950,12 +1936,22 @@ var fullscreenModal = {
1950
1936
  },
1951
1937
  animation: {
1952
1938
  overlay: {
1953
- duration: webAnimationOverlayDuration,
1954
- easing: webAnimationOverlayEasing
1939
+ duration: 250,
1940
+ easing: {
1941
+ x1: 0.42,
1942
+ y1: 0,
1943
+ x2: 1,
1944
+ y2: 1
1945
+ }
1955
1946
  },
1956
1947
  content: {
1957
- duration: webAnimationContentDuration,
1958
- easing: webAnimationContentEasing
1948
+ duration: 600,
1949
+ easing: {
1950
+ x1: 0.77,
1951
+ y1: 0,
1952
+ x2: 0.175,
1953
+ y2: 1
1954
+ }
1959
1955
  }
1960
1956
  }
1961
1957
  };
@@ -4861,6 +4857,8 @@ function AnimatedChoiceItemView(_ref) {
4861
4857
  isDisabled = _ref.isDisabled,
4862
4858
  isSelected = _ref.isSelected,
4863
4859
  hasError = _ref.hasError,
4860
+ _ref$shouldExpand = _ref.shouldExpand,
4861
+ shouldExpand = _ref$shouldExpand === void 0 ? false : _ref$shouldExpand,
4864
4862
  animatedStyles = _ref.animatedStyles;
4865
4863
  var sx = useSx();
4866
4864
  var style = sx({
@@ -4878,7 +4876,9 @@ function AnimatedChoiceItemView(_ref) {
4878
4876
  isHovered: isHovered,
4879
4877
  isPressed: isPressed
4880
4878
  }),
4881
- padding: size === 'small' ? 'kitt.2' : 'kitt.4'
4879
+ padding: size === 'small' ? 'kitt.2' : 'kitt.4',
4880
+ flexGrow: shouldExpand ? 1 : undefined,
4881
+ flexShrink: shouldExpand ? 1 : undefined
4882
4882
  });
4883
4883
  return /*#__PURE__*/jsx(Animated.View, {
4884
4884
  style: [style, animatedStyles],
@@ -4941,6 +4941,8 @@ function ChoiceItem(_ref) {
4941
4941
  value = _ref.value,
4942
4942
  selected = _ref.selected,
4943
4943
  disabled = _ref.disabled,
4944
+ _ref$shouldExpand = _ref.shouldExpand,
4945
+ shouldExpand = _ref$shouldExpand === void 0 ? false : _ref$shouldExpand,
4944
4946
  _children = _ref.children,
4945
4947
  isPressedInternal = _ref.isPressedInternal,
4946
4948
  isHoveredInternal = _ref.isHoveredInternal,
@@ -4978,6 +4980,8 @@ function ChoiceItem(_ref) {
4978
4980
  checked: selected
4979
4981
  },
4980
4982
  style: style,
4983
+ flexGrow: shouldExpand ? 1 : undefined,
4984
+ flexShrink: shouldExpand ? 1 : undefined,
4981
4985
  onBlur: onBlur,
4982
4986
  onFocus: onFocus,
4983
4987
  onPress: function (e) {
@@ -4996,6 +5000,8 @@ function ChoiceItem(_ref) {
4996
5000
  });
4997
5001
  return /*#__PURE__*/jsxs(VStack, {
4998
5002
  space: "kitt.2",
5003
+ flexGrow: shouldExpand ? 1 : undefined,
5004
+ flexShrink: shouldExpand ? 1 : undefined,
4999
5005
  children: [/*#__PURE__*/jsxs(AnimatedChoiceItemView, {
5000
5006
  animatedStyles: backgroundStyles,
5001
5007
  isHovered: isHovered || isHoveredInternal,
@@ -5003,10 +5009,13 @@ function ChoiceItem(_ref) {
5003
5009
  isSelected: selected,
5004
5010
  isPressed: isPressed || isPressedInternal,
5005
5011
  hasError: hasError,
5012
+ shouldExpand: shouldExpand,
5006
5013
  size: size,
5007
5014
  children: [/*#__PURE__*/jsxs(Stack, {
5008
5015
  alignItems: "center",
5009
5016
  space: "kitt.2",
5017
+ flexGrow: shouldExpand ? 1 : undefined,
5018
+ flexShrink: shouldExpand ? 1 : undefined,
5010
5019
  children: [icon ? /*#__PURE__*/jsx(TypographyIcon, {
5011
5020
  color: textColor,
5012
5021
  icon: icon
@@ -5035,33 +5044,43 @@ function ChoiceItem(_ref) {
5035
5044
  function ChoiceItemContainer(_ref) {
5036
5045
  var children = _ref.children,
5037
5046
  direction = _ref.direction,
5047
+ shouldExpand = _ref.shouldExpand,
5038
5048
  isLast = _ref.isLast;
5039
5049
  var currentItemMarginValue = isLast ? undefined : 'kitt.3';
5040
- var flexProps = direction === 'row' ? {
5050
+ var directionFlexProps = direction === 'row' ? {
5041
5051
  flexGrow: 1,
5042
5052
  flexShrink: 1,
5043
5053
  flexBasis: 0
5044
5054
  } : {};
5045
- return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({
5055
+ var shouldExpandFlexProps = shouldExpand ? {
5056
+ flexGrow: 1,
5057
+ flexShrink: 1
5058
+ } : {};
5059
+ return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread(_objectSpread({
5046
5060
  marginRight: direction === 'row' ? currentItemMarginValue : undefined,
5047
5061
  marginBottom: direction === 'column' ? currentItemMarginValue : undefined
5048
- }, flexProps), {}, {
5062
+ }, directionFlexProps), shouldExpandFlexProps), {}, {
5049
5063
  children: children
5050
5064
  }));
5051
5065
  }
5052
5066
 
5053
- var _excluded$G = ["direction", "contentContainerStyle"];
5067
+ var _excluded$G = ["direction", "shouldExpand", "contentContainerStyle"];
5054
5068
  function ChoicesContainer(_ref) {
5055
5069
  var direction = _ref.direction,
5070
+ shouldExpand = _ref.shouldExpand,
5056
5071
  contentContainerStyle = _ref.contentContainerStyle,
5057
5072
  props = _objectWithoutProperties(_ref, _excluded$G);
5073
+ var shouldExpandFlexProps = shouldExpand ? {
5074
+ flexGrow: 1,
5075
+ flexShrink: 1
5076
+ } : {};
5058
5077
  if (direction === 'row') {
5059
- return /*#__PURE__*/jsx(ScrollView$2, _objectSpread({
5078
+ return /*#__PURE__*/jsx(ScrollView, _objectSpread(_objectSpread({
5060
5079
  horizontal: true,
5061
- contentContainerStyle: contentContainerStyle
5062
- }, props));
5080
+ contentContainerStyle: shouldExpand ? shouldExpandFlexProps : contentContainerStyle
5081
+ }, props), shouldExpandFlexProps));
5063
5082
  }
5064
- return /*#__PURE__*/jsx(View$2, _objectSpread({}, props));
5083
+ return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({}, props), shouldExpandFlexProps));
5065
5084
  }
5066
5085
 
5067
5086
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
@@ -5073,6 +5092,8 @@ function Choices(_ref2) {
5073
5092
  _ref2$direction = _ref2.direction,
5074
5093
  direction = _ref2$direction === void 0 ? 'column' : _ref2$direction,
5075
5094
  disabled = _ref2.disabled,
5095
+ _ref2$shouldExpand = _ref2.shouldExpand,
5096
+ shouldExpand = _ref2$shouldExpand === void 0 ? false : _ref2$shouldExpand,
5076
5097
  children = _ref2.children,
5077
5098
  value = _ref2.value,
5078
5099
  onPress = _ref2.onPress,
@@ -5091,6 +5112,7 @@ function Choices(_ref2) {
5091
5112
  var sharedProps = {
5092
5113
  type: type,
5093
5114
  disabled: disabled,
5115
+ shouldExpand: shouldExpand,
5094
5116
  onPress: !isForm ? onPress : undefined,
5095
5117
  onChange: isForm ? function (newValue) {
5096
5118
  setCurrentValue(newValue);
@@ -5102,6 +5124,7 @@ function Choices(_ref2) {
5102
5124
  };
5103
5125
  return /*#__PURE__*/jsx(ChoicesContainer, {
5104
5126
  direction: direction,
5127
+ shouldExpand: shouldExpand,
5105
5128
  testID: testID,
5106
5129
  id: id,
5107
5130
  style: style,
@@ -5112,6 +5135,7 @@ function Choices(_ref2) {
5112
5135
  }, sharedProps));
5113
5136
  return /*#__PURE__*/jsx(ChoiceItemContainer, {
5114
5137
  direction: direction,
5138
+ shouldExpand: shouldExpand,
5115
5139
  isLast: index === childrenArray.length - 1,
5116
5140
  children: element
5117
5141
  }, child.key);