@ornikar/kitt-universal 32.3.1-canary.ddff29bdf3ffa500cf7658e5206d5069b23f4b45.0 → 32.4.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 (58) hide show
  1. package/CHANGELOG.md +3 -8
  2. package/dist/definitions/Button/AnimatedContainer.d.ts.map +1 -1
  3. package/dist/definitions/Button/AnimatedContainer.web.d.ts.map +1 -1
  4. package/dist/definitions/Button/Button.d.ts.map +1 -1
  5. package/dist/definitions/Choices/AnimatedChoiceItemView.d.ts +2 -1
  6. package/dist/definitions/Choices/AnimatedChoiceItemView.d.ts.map +1 -1
  7. package/dist/definitions/Choices/AnimatedChoiceItemView.web.d.ts +1 -1
  8. package/dist/definitions/Choices/AnimatedChoiceItemView.web.d.ts.map +1 -1
  9. package/dist/definitions/Choices/ChoiceItem.d.ts +2 -1
  10. package/dist/definitions/Choices/ChoiceItem.d.ts.map +1 -1
  11. package/dist/definitions/Choices/ChoiceItemContainer.d.ts +2 -1
  12. package/dist/definitions/Choices/ChoiceItemContainer.d.ts.map +1 -1
  13. package/dist/definitions/Choices/Choices.d.ts +5 -5
  14. package/dist/definitions/Choices/Choices.d.ts.map +1 -1
  15. package/dist/definitions/native-base/KittNativeBaseProvider.d.ts +3 -9
  16. package/dist/definitions/native-base/KittNativeBaseProvider.d.ts.map +1 -1
  17. package/dist/definitions/themes/default.d.ts +0 -5
  18. package/dist/definitions/themes/default.d.ts.map +1 -1
  19. package/dist/definitions/themes/late-ocean/button.d.ts +0 -3
  20. package/dist/definitions/themes/late-ocean/button.d.ts.map +1 -1
  21. package/dist/definitions/themes/late-ocean/typography.d.ts +0 -5
  22. package/dist/definitions/themes/late-ocean/typography.d.ts.map +1 -1
  23. package/dist/definitions/typography/Typography.d.ts +1 -1
  24. package/dist/definitions/typography/Typography.d.ts.map +1 -1
  25. package/dist/index-metro.es.android.js +49 -41
  26. package/dist/index-metro.es.android.js.map +1 -1
  27. package/dist/index-metro.es.ios.js +49 -41
  28. package/dist/index-metro.es.ios.js.map +1 -1
  29. package/dist/index-node-22.17.cjs.js +50 -39
  30. package/dist/index-node-22.17.cjs.js.map +1 -1
  31. package/dist/index-node-22.17.cjs.web.js +49 -39
  32. package/dist/index-node-22.17.cjs.web.js.map +1 -1
  33. package/dist/index-node-22.17.es.mjs +51 -40
  34. package/dist/index-node-22.17.es.mjs.map +1 -1
  35. package/dist/index-node-22.17.es.web.mjs +50 -40
  36. package/dist/index-node-22.17.es.web.mjs.map +1 -1
  37. package/dist/index.es.js +52 -41
  38. package/dist/index.es.js.map +1 -1
  39. package/dist/index.es.web.js +51 -41
  40. package/dist/index.es.web.js.map +1 -1
  41. package/dist/linaria-themes-metro.es.android.js +10 -19
  42. package/dist/linaria-themes-metro.es.android.js.map +1 -1
  43. package/dist/linaria-themes-metro.es.ios.js +10 -19
  44. package/dist/linaria-themes-metro.es.ios.js.map +1 -1
  45. package/dist/linaria-themes-node-22.17.cjs.js +10 -19
  46. package/dist/linaria-themes-node-22.17.cjs.js.map +1 -1
  47. package/dist/linaria-themes-node-22.17.cjs.web.js +10 -19
  48. package/dist/linaria-themes-node-22.17.cjs.web.js.map +1 -1
  49. package/dist/linaria-themes-node-22.17.es.mjs +10 -19
  50. package/dist/linaria-themes-node-22.17.es.mjs.map +1 -1
  51. package/dist/linaria-themes-node-22.17.es.web.mjs +10 -19
  52. package/dist/linaria-themes-node-22.17.es.web.mjs.map +1 -1
  53. package/dist/linaria-themes.es.js +10 -19
  54. package/dist/linaria-themes.es.js.map +1 -1
  55. package/dist/linaria-themes.es.web.js +10 -19
  56. package/dist/linaria-themes.es.web.js.map +1 -1
  57. package/dist/tsbuildinfo +1 -1
  58. package/package.json +1 -1
@@ -680,10 +680,6 @@ const button = {
680
680
  default: 40,
681
681
  medium: 48
682
682
  },
683
- minHeight: {
684
- default: 40,
685
- medium: 48
686
- },
687
683
  maxHeight: 48,
688
684
  icon: {
689
685
  medium: {
@@ -2137,8 +2133,8 @@ const typography = {
2137
2133
  allowedFontWeights: ['semibold']
2138
2134
  },
2139
2135
  'heading-l': {
2140
- fontSize: 38,
2141
- lineHeight: 44,
2136
+ fontSize: 40,
2137
+ lineHeight: 48,
2142
2138
  allowedFontWeights: ['semibold']
2143
2139
  },
2144
2140
  'heading-m': {
@@ -2147,19 +2143,14 @@ const typography = {
2147
2143
  allowedFontWeights: ['semibold']
2148
2144
  },
2149
2145
  'heading-s': {
2150
- fontSize: 24,
2151
- lineHeight: 28,
2152
- allowedFontWeights: ['semibold']
2146
+ fontSize: 18,
2147
+ lineHeight: 20,
2148
+ allowedFontWeights: ['regular', 'bold']
2153
2149
  },
2154
2150
  'heading-xs': {
2155
- fontSize: 20,
2156
- lineHeight: 24,
2157
- allowedFontWeights: ['semibold']
2158
- },
2159
- 'heading-xxs': {
2160
2151
  fontSize: 16,
2161
- lineHeight: 20,
2162
- allowedFontWeights: ['semibold']
2152
+ lineHeight: 18,
2153
+ allowedFontWeights: ['regular', 'bold']
2163
2154
  }
2164
2155
  }
2165
2156
  },
@@ -2226,17 +2217,17 @@ const typography = {
2226
2217
  configs: {
2227
2218
  'label-large': {
2228
2219
  fontSize: 16,
2229
- lineHeight: 20,
2220
+ lineHeight: 24,
2230
2221
  allowedFontWeights: ['semibold']
2231
2222
  },
2232
2223
  'label-medium': {
2233
2224
  fontSize: 14,
2234
- lineHeight: 18,
2225
+ lineHeight: 20,
2235
2226
  allowedFontWeights: ['semibold']
2236
2227
  },
2237
2228
  'label-small': {
2238
2229
  fontSize: 12,
2239
- lineHeight: 14,
2230
+ lineHeight: 16,
2240
2231
  allowedFontWeights: ['semibold']
2241
2232
  }
2242
2233
  }
@@ -3154,9 +3145,7 @@ function AnimatedContainer$2({
3154
3145
  },
3155
3146
  width: width,
3156
3147
  height: height,
3157
- minHeight: size === 'default' ? 'kitt.button.minHeight.default' : 'kitt.button.minHeight.medium',
3158
3148
  alignSelf: "baseline",
3159
- justifyContent: "center",
3160
3149
  borderRadius: "kitt.button.borderRadius",
3161
3150
  backgroundColor: currentBackgroundColor,
3162
3151
  children: children
@@ -3852,7 +3841,6 @@ const Button = /*#__PURE__*/react.forwardRef(({
3852
3841
  alignSelf: createResponsiveStyleFromProp(stretch, undefined, 'flex-start'),
3853
3842
  minWidth: "kitt.button.minWidth",
3854
3843
  maxWidth: createResponsiveStyleFromProp(stretch, '100%', 'kitt.button.maxWidth'),
3855
- minHeight: size === 'default' ? 'kitt.button.minHeight.default' : 'kitt.button.minHeight.medium',
3856
3844
  maxHeight: "kitt.button.maxHeight",
3857
3845
  width: createResponsiveStyleFromProp(stretch, '100%', 'auto'),
3858
3846
  onPress: onPress,
@@ -4718,7 +4706,8 @@ function AnimatedChoiceItemView({
4718
4706
  isPressed,
4719
4707
  isDisabled,
4720
4708
  isSelected,
4721
- hasError
4709
+ hasError,
4710
+ shouldExpand = false
4722
4711
  }) {
4723
4712
  const theme = useTheme();
4724
4713
  return /*#__PURE__*/jsxRuntime.jsx(View, {
@@ -4737,6 +4726,8 @@ function AnimatedChoiceItemView({
4737
4726
  isPressed
4738
4727
  }),
4739
4728
  padding: size === 'small' ? 'kitt.2' : 'kitt.4',
4729
+ flexGrow: shouldExpand ? 1 : undefined,
4730
+ flexShrink: shouldExpand ? 1 : undefined,
4740
4731
  _web: {
4741
4732
  style: {
4742
4733
  transitionProperty: theme.kitt.choices.item.transition.property,
@@ -4772,6 +4763,7 @@ function ChoiceItem({
4772
4763
  value,
4773
4764
  selected,
4774
4765
  disabled,
4766
+ shouldExpand = false,
4775
4767
  children,
4776
4768
  isPressedInternal,
4777
4769
  isHoveredInternal,
@@ -4807,6 +4799,8 @@ function ChoiceItem({
4807
4799
  checked: selected
4808
4800
  },
4809
4801
  style: style,
4802
+ flexGrow: shouldExpand ? 1 : undefined,
4803
+ flexShrink: shouldExpand ? 1 : undefined,
4810
4804
  onBlur: onBlur,
4811
4805
  onFocus: onFocus,
4812
4806
  onPress: e => {
@@ -4826,6 +4820,8 @@ function ChoiceItem({
4826
4820
  });
4827
4821
  return /*#__PURE__*/jsxRuntime.jsxs(VStack, {
4828
4822
  space: "kitt.2",
4823
+ flexGrow: shouldExpand ? 1 : undefined,
4824
+ flexShrink: shouldExpand ? 1 : undefined,
4829
4825
  children: [/*#__PURE__*/jsxRuntime.jsxs(AnimatedChoiceItemView, {
4830
4826
  animatedStyles: backgroundStyles,
4831
4827
  isHovered: isHovered || isHoveredInternal,
@@ -4833,10 +4829,13 @@ function ChoiceItem({
4833
4829
  isSelected: selected,
4834
4830
  isPressed: isPressed || isPressedInternal,
4835
4831
  hasError: hasError,
4832
+ shouldExpand: shouldExpand,
4836
4833
  size: size,
4837
4834
  children: [/*#__PURE__*/jsxRuntime.jsxs(Stack, {
4838
4835
  alignItems: "center",
4839
4836
  space: "kitt.2",
4837
+ flexGrow: shouldExpand ? 1 : undefined,
4838
+ flexShrink: shouldExpand ? 1 : undefined,
4840
4839
  children: [icon ? /*#__PURE__*/jsxRuntime.jsx(TypographyIcon, {
4841
4840
  color: textColor,
4842
4841
  icon: icon
@@ -4865,36 +4864,49 @@ function ChoiceItem({
4865
4864
  function ChoiceItemContainer({
4866
4865
  children,
4867
4866
  direction,
4867
+ shouldExpand,
4868
4868
  isLast
4869
4869
  }) {
4870
4870
  const currentItemMarginValue = isLast ? undefined : 'kitt.3';
4871
- const flexProps = direction === 'row' ? {
4871
+ const directionFlexProps = direction === 'row' ? {
4872
4872
  flexGrow: 1,
4873
4873
  flexShrink: 1,
4874
4874
  flexBasis: 0
4875
4875
  } : {};
4876
+ const shouldExpandFlexProps = shouldExpand ? {
4877
+ flexGrow: 1,
4878
+ flexShrink: 1
4879
+ } : {};
4876
4880
  return /*#__PURE__*/jsxRuntime.jsx(View, {
4877
4881
  marginRight: direction === 'row' ? currentItemMarginValue : undefined,
4878
4882
  marginBottom: direction === 'column' ? currentItemMarginValue : undefined,
4879
- ...flexProps,
4883
+ ...directionFlexProps,
4884
+ ...shouldExpandFlexProps,
4880
4885
  children: children
4881
4886
  });
4882
4887
  }
4883
4888
 
4884
4889
  function ChoicesContainer({
4885
4890
  direction,
4891
+ shouldExpand,
4886
4892
  contentContainerStyle,
4887
4893
  ...props
4888
4894
  }) {
4895
+ const shouldExpandFlexProps = shouldExpand ? {
4896
+ flexGrow: 1,
4897
+ flexShrink: 1
4898
+ } : {};
4889
4899
  if (direction === 'row') {
4890
- return /*#__PURE__*/jsxRuntime.jsx(reactNative.ScrollView, {
4900
+ return /*#__PURE__*/jsxRuntime.jsx(ScrollView, {
4891
4901
  horizontal: true,
4892
- contentContainerStyle: contentContainerStyle,
4893
- ...props
4902
+ contentContainerStyle: shouldExpand ? shouldExpandFlexProps : contentContainerStyle,
4903
+ ...props,
4904
+ ...shouldExpandFlexProps
4894
4905
  });
4895
4906
  }
4896
- return /*#__PURE__*/jsxRuntime.jsx(reactNative.View, {
4897
- ...props
4907
+ return /*#__PURE__*/jsxRuntime.jsx(View, {
4908
+ ...props,
4909
+ ...shouldExpandFlexProps
4898
4910
  });
4899
4911
  }
4900
4912
 
@@ -4906,6 +4918,7 @@ function Choices({
4906
4918
  type,
4907
4919
  direction = 'column',
4908
4920
  disabled,
4921
+ shouldExpand = false,
4909
4922
  children,
4910
4923
  value,
4911
4924
  onPress,
@@ -4922,6 +4935,7 @@ function Choices({
4922
4935
  const sharedProps = {
4923
4936
  type,
4924
4937
  disabled,
4938
+ shouldExpand,
4925
4939
  onPress: !isForm ? onPress : undefined,
4926
4940
  onChange: isForm ? newValue => {
4927
4941
  setCurrentValue(newValue);
@@ -4933,6 +4947,7 @@ function Choices({
4933
4947
  };
4934
4948
  return /*#__PURE__*/jsxRuntime.jsx(ChoicesContainer, {
4935
4949
  direction: direction,
4950
+ shouldExpand: shouldExpand,
4936
4951
  testID: testID,
4937
4952
  id: id,
4938
4953
  style: style,
@@ -4944,6 +4959,7 @@ function Choices({
4944
4959
  });
4945
4960
  return /*#__PURE__*/jsxRuntime.jsx(ChoiceItemContainer, {
4946
4961
  direction: direction,
4962
+ shouldExpand: shouldExpand,
4947
4963
  isLast: index === childrenArray.length - 1,
4948
4964
  children: element
4949
4965
  }, child.key);
@@ -9933,10 +9949,6 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
9933
9949
  button: {
9934
9950
  minWidth: theme.button.minWidth,
9935
9951
  maxWidth: theme.button.maxWidth,
9936
- minHeight: {
9937
- default: theme.button.minHeight.default,
9938
- medium: theme.button.minHeight.medium
9939
- },
9940
9952
  maxHeight: theme.button.maxHeight,
9941
9953
  height: {
9942
9954
  default: theme.button.height.default,
@@ -10558,7 +10570,6 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
10558
10570
  'heading-m': `${theme.typography.types.headings.configs['heading-m'].fontSize}px`,
10559
10571
  'heading-s': `${theme.typography.types.headings.configs['heading-s'].fontSize}px`,
10560
10572
  'heading-xs': `${theme.typography.types.headings.configs['heading-xs'].fontSize}px`,
10561
- 'heading-xxs': `${theme.typography.types.headings.configs['heading-xxs'].fontSize}px`,
10562
10573
  'body-xl': `${theme.typography.types.bodies.configs['body-xl'].fontSize}px`,
10563
10574
  'body-l': `${theme.typography.types.bodies.configs['body-l'].fontSize}px`,
10564
10575
  'body-m': `${theme.typography.types.bodies.configs['body-m'].fontSize}px`,
@@ -10582,7 +10593,6 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
10582
10593
  'heading-m': `${theme.typography.types.headings.configs['heading-m'].lineHeight}px`,
10583
10594
  'heading-s': `${theme.typography.types.headings.configs['heading-s'].lineHeight}px`,
10584
10595
  'heading-xs': `${theme.typography.types.headings.configs['heading-xs'].lineHeight}px`,
10585
- 'heading-xxs': `${theme.typography.types.headings.configs['heading-xxs'].lineHeight}px`,
10586
10596
  'body-xl': `${theme.typography.types.bodies.configs['body-xl'].lineHeight}px`,
10587
10597
  'body-l': `${theme.typography.types.bodies.configs['body-l'].lineHeight}px`,
10588
10598
  'body-m': `${theme.typography.types.bodies.configs['body-m'].lineHeight}px`,
@@ -12410,7 +12420,7 @@ function StoryTitleLevel4({
12410
12420
  return /*#__PURE__*/jsxRuntime.jsx(View, {
12411
12421
  marginBottom: 10,
12412
12422
  children: /*#__PURE__*/jsxRuntime.jsx(Typography.Header4, {
12413
- base: "body-l",
12423
+ base: "heading-s",
12414
12424
  color: useStoryBlockColor(color),
12415
12425
  numberOfLines: numberOfLines,
12416
12426
  children: children
@@ -12959,7 +12969,7 @@ function ToastContent({
12959
12969
  flexGrow: 1,
12960
12970
  flexShrink: 1,
12961
12971
  children: [title ? /*#__PURE__*/jsxRuntime.jsx(Typography.Text, {
12962
- base: "body-m",
12972
+ base: "heading-xs",
12963
12973
  color: "white",
12964
12974
  children: title
12965
12975
  }) : null, description ? /*#__PURE__*/jsxRuntime.jsx(Typography.Text, {
@@ -12975,7 +12985,7 @@ function ToastContent({
12975
12985
  borderColor: "white",
12976
12986
  onPress: onPress,
12977
12987
  children: /*#__PURE__*/jsxRuntime.jsx(Typography.Text, {
12978
- base: "body-m",
12988
+ base: "heading-xs",
12979
12989
  color: "white",
12980
12990
  children: actionLabel
12981
12991
  })