@ornikar/kitt-universal 22.1.1 → 22.2.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 (46) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/dist/definitions/CardModal/CardModal.d.ts.map +1 -1
  3. package/dist/definitions/CardModal/CardModalAnimation/CardModalRotationContainer.d.ts.map +1 -1
  4. package/dist/definitions/CardModal/CardModalBehaviour.d.ts +0 -5
  5. package/dist/definitions/CardModal/CardModalBehaviour.d.ts.map +1 -1
  6. package/dist/definitions/CardModal/CardModalBody.d.ts +2 -2
  7. package/dist/definitions/CardModal/CardModalBody.d.ts.map +1 -1
  8. package/dist/definitions/NavigationModal/NavigationModalBehaviour.d.ts.map +1 -1
  9. package/dist/definitions/native-base/KittNativeBaseProvider.d.ts +5 -17
  10. package/dist/definitions/native-base/KittNativeBaseProvider.d.ts.map +1 -1
  11. package/dist/definitions/themes/late-ocean/cardModal.d.ts +1 -0
  12. package/dist/definitions/themes/late-ocean/cardModal.d.ts.map +1 -1
  13. package/dist/index-metro.es.android.js +47 -75
  14. package/dist/index-metro.es.android.js.map +1 -1
  15. package/dist/index-metro.es.ios.js +47 -75
  16. package/dist/index-metro.es.ios.js.map +1 -1
  17. package/dist/index-node-18.18.cjs.js +40 -67
  18. package/dist/index-node-18.18.cjs.js.map +1 -1
  19. package/dist/index-node-18.18.cjs.web.js +40 -62
  20. package/dist/index-node-18.18.cjs.web.js.map +1 -1
  21. package/dist/index-node-18.18.es.mjs +40 -67
  22. package/dist/index-node-18.18.es.mjs.map +1 -1
  23. package/dist/index-node-18.18.es.web.mjs +40 -62
  24. package/dist/index-node-18.18.es.web.mjs.map +1 -1
  25. package/dist/index.es.js +58 -83
  26. package/dist/index.es.js.map +1 -1
  27. package/dist/index.es.web.js +58 -78
  28. package/dist/index.es.web.js.map +1 -1
  29. package/dist/linaria-themes-metro.es.android.js +2 -1
  30. package/dist/linaria-themes-metro.es.android.js.map +1 -1
  31. package/dist/linaria-themes-metro.es.ios.js +2 -1
  32. package/dist/linaria-themes-metro.es.ios.js.map +1 -1
  33. package/dist/linaria-themes-node-18.18.cjs.js +2 -1
  34. package/dist/linaria-themes-node-18.18.cjs.js.map +1 -1
  35. package/dist/linaria-themes-node-18.18.cjs.web.js +2 -1
  36. package/dist/linaria-themes-node-18.18.cjs.web.js.map +1 -1
  37. package/dist/linaria-themes-node-18.18.es.mjs +2 -1
  38. package/dist/linaria-themes-node-18.18.es.mjs.map +1 -1
  39. package/dist/linaria-themes-node-18.18.es.web.mjs +2 -1
  40. package/dist/linaria-themes-node-18.18.es.web.mjs.map +1 -1
  41. package/dist/linaria-themes.es.js +2 -1
  42. package/dist/linaria-themes.es.js.map +1 -1
  43. package/dist/linaria-themes.es.web.js +2 -1
  44. package/dist/linaria-themes.es.web.js.map +1 -1
  45. package/dist/tsbuildinfo +1 -1
  46. package/package.json +2 -2
@@ -782,6 +782,7 @@ var cardModal = {
782
782
  borderRadius: 20,
783
783
  maxWidth: maxWidth,
784
784
  maxWidthWithPadding: maxWidth + overlayHorizontalPadding * 2,
785
+ minHeight: 280,
785
786
  shadow: {
786
787
  color: colors.black,
787
788
  offsetX: 0,
@@ -800,7 +801,7 @@ var cardModal = {
800
801
  },
801
802
  overlayPadding: {
802
803
  horizontal: 24,
803
- vertical: 32
804
+ vertical: 80
804
805
  },
805
806
  animation: {
806
807
  overlay: {
@@ -2317,7 +2318,7 @@ function Icon(_ref) {
2317
2318
  }
2318
2319
 
2319
2320
  var _excluded$L = ["color", "size"],
2320
- _excluded2$7 = ["color"];
2321
+ _excluded2$6 = ["color"];
2321
2322
  function getIconSizeConfigKeyFromTypeName(breakpointName) {
2322
2323
  return breakpointName === KittBreakpointNameEnum.BASE || breakpointName === KittBreakpointNameEnum.SMALL ? 'baseAndSmall' : 'mediumAndWide';
2323
2324
  }
@@ -2359,7 +2360,7 @@ function TypographyIconInheritColor(props) {
2359
2360
  }
2360
2361
  function TypographyIcon(_ref2) {
2361
2362
  var color = _ref2.color,
2362
- props = _objectWithoutProperties(_ref2, _excluded2$7);
2363
+ props = _objectWithoutProperties(_ref2, _excluded2$6);
2363
2364
  if (color) {
2364
2365
  return /*#__PURE__*/jsx(TypographyIconSpecifiedColor, _objectSpread({
2365
2366
  color: color
@@ -3038,7 +3039,11 @@ function CardModalRotationContainer(props) {
3038
3039
  paddingX: "kitt.cardModal.overlayPadding.horizontal",
3039
3040
  paddingY: "kitt.cardModal.overlayPadding.vertical",
3040
3041
  maxWidth: "kitt.cardModal.maxWidthWithPadding",
3041
- width: "100%"
3042
+ width: "100%",
3043
+ maxHeight: "100%",
3044
+ _web: {
3045
+ maxHeight: '100svh'
3046
+ }
3042
3047
  }, props));
3043
3048
  }
3044
3049
 
@@ -3114,21 +3119,13 @@ function CardModalAnimation(_ref) {
3114
3119
  }));
3115
3120
  }
3116
3121
 
3117
- var _excluded$F = ["children"],
3118
- _excluded2$6 = ["children", "visible", "onClose", "onExited"];
3119
- function CardModalScrollContainer(_ref) {
3122
+ var _excluded$F = ["children", "visible", "onClose", "onExited"];
3123
+ function CardModalBehaviour(_ref) {
3120
3124
  var children = _ref.children,
3125
+ visible = _ref.visible,
3126
+ onClose = _ref.onClose,
3127
+ onExited = _ref.onExited,
3121
3128
  props = _objectWithoutProperties(_ref, _excluded$F);
3122
- return /*#__PURE__*/jsx(ScrollView, _objectSpread(_objectSpread({}, props), {}, {
3123
- children: children
3124
- }));
3125
- }
3126
- function CardModalBehaviour(_ref2) {
3127
- var children = _ref2.children,
3128
- visible = _ref2.visible,
3129
- onClose = _ref2.onClose,
3130
- onExited = _ref2.onExited,
3131
- props = _objectWithoutProperties(_ref2, _excluded2$6);
3132
3129
  var _useState = useState(visible),
3133
3130
  _useState2 = _slicedToArray(_useState, 2),
3134
3131
  isModalBehaviourVisible = _useState2[0],
@@ -3141,21 +3138,15 @@ function CardModalBehaviour(_ref2) {
3141
3138
  return /*#__PURE__*/jsx(ModalBehaviour, {
3142
3139
  visible: isModalBehaviourVisible,
3143
3140
  onClose: onClose,
3144
- children: /*#__PURE__*/jsx(CardModalScrollContainer, {
3145
- bounces: false,
3146
- contentContainerStyle: {
3147
- flexGrow: 1
3141
+ children: /*#__PURE__*/jsx(CardModalAnimation, _objectSpread(_objectSpread({}, props), {}, {
3142
+ visible: visible,
3143
+ onExited: function handleExitAnimationDone() {
3144
+ if (onExited) onExited();
3145
+ setIsModalBehaviourVisible(false);
3148
3146
  },
3149
- children: /*#__PURE__*/jsx(CardModalAnimation, _objectSpread(_objectSpread({}, props), {}, {
3150
- visible: visible,
3151
- onExited: function handleExitAnimationDone() {
3152
- if (onExited) onExited();
3153
- setIsModalBehaviourVisible(false);
3154
- },
3155
- onClose: onClose,
3156
- children: children
3157
- }))
3158
- })
3147
+ onClose: onClose,
3148
+ children: children
3149
+ }))
3159
3150
  });
3160
3151
  }
3161
3152
 
@@ -3170,7 +3161,8 @@ function CardModalBody(_ref) {
3170
3161
  _ref$paddingY = _ref.paddingY,
3171
3162
  paddingY = _ref$paddingY === void 0 ? 'kitt.4' : _ref$paddingY,
3172
3163
  props = _objectWithoutProperties(_ref, _excluded$E);
3173
- return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({
3164
+ return /*#__PURE__*/jsx(ScrollView, _objectSpread(_objectSpread({
3165
+ showsVerticalScrollIndicator: false,
3174
3166
  paddingX: paddingX,
3175
3167
  paddingY: paddingY
3176
3168
  }, props), {}, {
@@ -3273,6 +3265,7 @@ function CardModal(_ref) {
3273
3265
  width: "100%",
3274
3266
  maxHeight: "100%",
3275
3267
  maxWidth: maxWidth,
3268
+ minHeight: "kitt.cardModal.minHeight",
3276
3269
  children: children || /*#__PURE__*/jsxs(Fragment, {
3277
3270
  children: [header || null, body || null, footer || null]
3278
3271
  })
@@ -7538,7 +7531,8 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
7538
7531
  height: theme.cardModal.header.height
7539
7532
  },
7540
7533
  maxWidth: theme.cardModal.maxWidth,
7541
- maxWidthWithPadding: theme.cardModal.maxWidthWithPadding
7534
+ maxWidthWithPadding: theme.cardModal.maxWidthWithPadding,
7535
+ minHeight: theme.cardModal.minHeight
7542
7536
  },
7543
7537
  dialogModal: {
7544
7538
  maxWidth: theme.dialogModal.maxWidth,
@@ -7649,7 +7643,7 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
7649
7643
  padding: theme.button.padding
7650
7644
  },
7651
7645
  cardModal: {
7652
- overlayPadding: theme.dialogModal.overlayPadding
7646
+ overlayPadding: theme.cardModal.overlayPadding
7653
7647
  },
7654
7648
  dialogModal: {
7655
7649
  overlayPadding: theme.dialogModal.overlayPadding
@@ -8480,28 +8474,20 @@ function NativeOnlyFlatList(_ref) {
8480
8474
  }
8481
8475
 
8482
8476
  var _excluded$a = ["children", "visible", "appear", "onExited", "onEnter", "onExit", "onClose"];
8483
- function SimpleContainer(_ref) {
8484
- var children = _ref.children;
8485
- return children;
8486
- }
8487
- function NavigationModalBehaviour(_ref2) {
8488
- var children = _ref2.children,
8489
- visible = _ref2.visible,
8490
- _ref2$appear = _ref2.appear,
8491
- appear = _ref2$appear === void 0 ? true : _ref2$appear,
8492
- onExited = _ref2.onExited,
8493
- onEnter = _ref2.onEnter,
8494
- onExit = _ref2.onExit,
8495
- onClose = _ref2.onClose,
8496
- props = _objectWithoutProperties(_ref2, _excluded$a);
8477
+ function NavigationModalBehaviour(_ref) {
8478
+ var children = _ref.children,
8479
+ visible = _ref.visible,
8480
+ _ref$appear = _ref.appear,
8481
+ appear = _ref$appear === void 0 ? true : _ref$appear,
8482
+ onExited = _ref.onExited,
8483
+ onEnter = _ref.onEnter,
8484
+ onExit = _ref.onExit,
8485
+ onClose = _ref.onClose,
8486
+ props = _objectWithoutProperties(_ref, _excluded$a);
8497
8487
  var AnimationComponent = useBreakpointValue({
8498
8488
  base: FullscreenModalAnimation,
8499
8489
  small: CardModalAnimation
8500
8490
  });
8501
- var CurrentContainerComponent = useBreakpointValue({
8502
- base: SimpleContainer,
8503
- small: CardModalScrollContainer
8504
- });
8505
8491
  var _useState = useState(visible),
8506
8492
  _useState2 = _slicedToArray(_useState, 2),
8507
8493
  isModalBehaviourVisible = _useState2[0],
@@ -8518,34 +8504,28 @@ function NavigationModalBehaviour(_ref2) {
8518
8504
  return /*#__PURE__*/jsx(ModalBehaviour, {
8519
8505
  visible: isModalBehaviourVisible,
8520
8506
  onClose: onClose,
8521
- children: /*#__PURE__*/jsx(CurrentContainerComponent, {
8522
- bounces: false,
8523
- contentContainerStyle: {
8524
- flexGrow: 1
8525
- },
8526
- children: /*#__PURE__*/jsx(AnimationComponent, _objectSpread(_objectSpread({}, props), {}, {
8527
- appear: shouldAppear,
8528
- visible: visible,
8529
- onEnter: function handleEnter() {
8530
- if (onEnter) onEnter();
8507
+ children: /*#__PURE__*/jsx(AnimationComponent, _objectSpread(_objectSpread({}, props), {}, {
8508
+ appear: shouldAppear,
8509
+ visible: visible,
8510
+ onEnter: function handleEnter() {
8511
+ if (onEnter) onEnter();
8531
8512
 
8532
- // Once a children as been displayed, we force appear to false in order to avoid replaying animation on breakpoint change
8533
- setShouldAppear(false);
8534
- },
8535
- onExit: function handleExit() {
8536
- if (onExit) onExit();
8513
+ // Once a children as been displayed, we force appear to false in order to avoid replaying animation on breakpoint change
8514
+ setShouldAppear(false);
8515
+ },
8516
+ onExit: function handleExit() {
8517
+ if (onExit) onExit();
8537
8518
 
8538
- // Reset appear value to its original value for future modal display
8539
- setShouldAppear(appear);
8540
- },
8541
- onExited: function handleExitAnimationDone() {
8542
- if (onExited) onExited();
8543
- setIsModalBehaviourVisible(false);
8544
- },
8545
- onClose: onClose,
8546
- children: children
8547
- }))
8548
- })
8519
+ // Reset appear value to its original value for future modal display
8520
+ setShouldAppear(appear);
8521
+ },
8522
+ onExited: function handleExitAnimationDone() {
8523
+ if (onExited) onExited();
8524
+ setIsModalBehaviourVisible(false);
8525
+ },
8526
+ onClose: onClose,
8527
+ children: children
8528
+ }))
8549
8529
  });
8550
8530
  }
8551
8531