@ornikar/kitt-universal 9.34.2 → 9.36.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 (76) hide show
  1. package/dist/definitions/forms/Checkbox/Checkbox.d.ts +6 -5
  2. package/dist/definitions/forms/Checkbox/Checkbox.d.ts.map +1 -1
  3. package/dist/definitions/forms/Checkbox/utils/getBackgroundColor.d.ts +10 -0
  4. package/dist/definitions/forms/Checkbox/utils/getBackgroundColor.d.ts.map +1 -0
  5. package/dist/definitions/forms/Checkbox/utils/getBorderColor.d.ts +10 -0
  6. package/dist/definitions/forms/Checkbox/utils/getBorderColor.d.ts.map +1 -0
  7. package/dist/definitions/forms/DatePicker/DatePicker.d.ts +5 -2
  8. package/dist/definitions/forms/DatePicker/DatePicker.d.ts.map +1 -1
  9. package/dist/definitions/forms/DatePicker/components/InputPart.d.ts +1 -0
  10. package/dist/definitions/forms/DatePicker/components/InputPart.d.ts.map +1 -1
  11. package/dist/definitions/forms/DatePicker/components/KeyboardDatePicker.d.ts +5 -2
  12. package/dist/definitions/forms/DatePicker/components/KeyboardDatePicker.d.ts.map +1 -1
  13. package/dist/definitions/forms/DatePicker/components/NativeUIDatePicker/DatePickerAndroid.d.ts +3 -2
  14. package/dist/definitions/forms/DatePicker/components/NativeUIDatePicker/DatePickerAndroid.d.ts.map +1 -1
  15. package/dist/definitions/forms/DatePicker/components/NativeUIDatePicker/DefaultNativeUIDatePicker.d.ts +3 -2
  16. package/dist/definitions/forms/DatePicker/components/NativeUIDatePicker/DefaultNativeUIDatePicker.d.ts.map +1 -1
  17. package/dist/definitions/forms/DatePicker/components/NativeUIDatePicker/NativeUIDatePicker.d.ts +3 -2
  18. package/dist/definitions/forms/DatePicker/components/NativeUIDatePicker/NativeUIDatePicker.d.ts.map +1 -1
  19. package/dist/definitions/forms/DatePicker/components/PressableDateInputs.d.ts +3 -2
  20. package/dist/definitions/forms/DatePicker/components/PressableDateInputs.d.ts.map +1 -1
  21. package/dist/definitions/forms/InputEmail/InputEmail.d.ts +3 -2
  22. package/dist/definitions/forms/InputEmail/InputEmail.d.ts.map +1 -1
  23. package/dist/definitions/forms/InputPassword/InputPassword.d.ts +3 -2
  24. package/dist/definitions/forms/InputPassword/InputPassword.d.ts.map +1 -1
  25. package/dist/definitions/forms/InputPhone/InputPhone.d.ts +3 -2
  26. package/dist/definitions/forms/InputPhone/InputPhone.d.ts.map +1 -1
  27. package/dist/definitions/forms/InputText/InputText.d.ts +1 -1
  28. package/dist/definitions/forms/InputText/InputText.d.ts.map +1 -1
  29. package/dist/definitions/forms/Radio/InnerCircle.d.ts +7 -0
  30. package/dist/definitions/forms/Radio/InnerCircle.d.ts.map +1 -0
  31. package/dist/definitions/forms/Radio/OuterCircle.d.ts +12 -0
  32. package/dist/definitions/forms/Radio/OuterCircle.d.ts.map +1 -0
  33. package/dist/definitions/forms/Radio/Radio.d.ts +5 -4
  34. package/dist/definitions/forms/Radio/Radio.d.ts.map +1 -1
  35. package/dist/definitions/forms/Radio/utils/getBackgroundColor.d.ts +10 -0
  36. package/dist/definitions/forms/Radio/utils/getBackgroundColor.d.ts.map +1 -0
  37. package/dist/definitions/forms/Radio/utils/getBorderColor.d.ts +10 -0
  38. package/dist/definitions/forms/Radio/utils/getBorderColor.d.ts.map +1 -0
  39. package/dist/definitions/forms/TextArea/TextArea.d.ts +3 -2
  40. package/dist/definitions/forms/TextArea/TextArea.d.ts.map +1 -1
  41. package/dist/definitions/native-base/KittNativeBaseProvider.d.ts +284 -147
  42. package/dist/definitions/native-base/KittNativeBaseProvider.d.ts.map +1 -1
  43. package/dist/definitions/themes/default.d.ts +29 -4
  44. package/dist/definitions/themes/default.d.ts.map +1 -1
  45. package/dist/definitions/themes/late-ocean/checkbox.d.ts +29 -4
  46. package/dist/definitions/themes/late-ocean/checkbox.d.ts.map +1 -1
  47. package/dist/definitions/themes/late-ocean/forms.d.ts +29 -4
  48. package/dist/definitions/themes/late-ocean/forms.d.ts.map +1 -1
  49. package/dist/definitions/themes/late-ocean/radio.d.ts +13 -0
  50. package/dist/definitions/themes/late-ocean/radio.d.ts.map +1 -1
  51. package/dist/index-browser-all.es.android.js +440 -190
  52. package/dist/index-browser-all.es.android.js.map +1 -1
  53. package/dist/index-browser-all.es.ios.js +440 -190
  54. package/dist/index-browser-all.es.ios.js.map +1 -1
  55. package/dist/index-browser-all.es.js +440 -190
  56. package/dist/index-browser-all.es.js.map +1 -1
  57. package/dist/index-browser-all.es.web.js +412 -180
  58. package/dist/index-browser-all.es.web.js.map +1 -1
  59. package/dist/index-node-14.17.cjs.js +433 -172
  60. package/dist/index-node-14.17.cjs.js.map +1 -1
  61. package/dist/index-node-14.17.cjs.web.js +408 -156
  62. package/dist/index-node-14.17.cjs.web.js.map +1 -1
  63. package/dist/linaria-themes-browser-all.es.android.js +44 -6
  64. package/dist/linaria-themes-browser-all.es.android.js.map +1 -1
  65. package/dist/linaria-themes-browser-all.es.ios.js +44 -6
  66. package/dist/linaria-themes-browser-all.es.ios.js.map +1 -1
  67. package/dist/linaria-themes-browser-all.es.js +44 -6
  68. package/dist/linaria-themes-browser-all.es.js.map +1 -1
  69. package/dist/linaria-themes-browser-all.es.web.js +44 -6
  70. package/dist/linaria-themes-browser-all.es.web.js.map +1 -1
  71. package/dist/linaria-themes-node-14.17.cjs.js +44 -6
  72. package/dist/linaria-themes-node-14.17.cjs.js.map +1 -1
  73. package/dist/linaria-themes-node-14.17.cjs.web.js +44 -6
  74. package/dist/linaria-themes-node-14.17.cjs.web.js.map +1 -1
  75. package/dist/tsbuildinfo +1 -1
  76. package/package.json +2 -2
@@ -1,6 +1,6 @@
1
1
  import _objectSpread from '@babel/runtime/helpers/objectSpread2';
2
2
  import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';
3
- import { Stack as Stack$1, VStack as VStack$1, HStack as HStack$1, Center as Center$1, View as View$1, ScrollView as ScrollView$1, Pressable as Pressable$1, Image as Image$1, FlatList as FlatList$1, SectionList as SectionList$1, useBreakpointValue, Text as Text$1, Input, NativeBaseProvider, extendTheme } from 'native-base';
3
+ import { Stack as Stack$1, VStack as VStack$1, HStack as HStack$1, Center as Center$1, View as View$1, ScrollView as ScrollView$1, Pressable as Pressable$1, Image as Image$1, FlatList as FlatList$1, SectionList as SectionList$1, useBreakpointValue, Text, Input, NativeBaseProvider, extendTheme } from 'native-base';
4
4
  export { useBreakpointValue, useClipboard, useToken } from 'native-base';
5
5
  import _objectDestructuringEmpty from '@babel/runtime/helpers/objectDestructuringEmpty';
6
6
  import _extends from '@babel/runtime/helpers/extends';
@@ -274,7 +274,7 @@ function Typography(_ref) {
274
274
  });
275
275
  }
276
276
  var currentColor = !color && !hasTypographyAncestor ? defaultColor : color;
277
- var text = /*#__PURE__*/jsx(Text$1, _objectSpread({
277
+ var text = /*#__PURE__*/jsx(Text, _objectSpread({
278
278
  accessibilityRole: accessibilityRole || undefined,
279
279
  fontSize: fontSizeForNativeBase,
280
280
  lineHeight: hasTypographyAncestor ? undefined : fontSizeForNativeBase,
@@ -2258,11 +2258,36 @@ var checkbox = {
2258
2258
  height: 20,
2259
2259
  width: 20,
2260
2260
  iconSize: 14,
2261
- borderColor: colors.separator,
2262
- backgroundColor: colors.uiBackgroundLight,
2263
- checkedBorderColor: colors.primary,
2264
- checkedBackgroundColor: colors.primary,
2265
- markColor: colors.uiBackgroundLight
2261
+ markColor: colors.uiBackgroundLight,
2262
+ textSpacing: 10,
2263
+ "default": {
2264
+ borderColor: colors.separator,
2265
+ backgroundColor: colors.uiBackgroundLight
2266
+ },
2267
+ checked: {
2268
+ borderColor: colors.primary,
2269
+ backgroundColor: colors.primary
2270
+ },
2271
+ focus: {
2272
+ borderColor: colors.primary,
2273
+ backgroundColor: colors.uiBackgroundLight
2274
+ },
2275
+ hover: {
2276
+ borderColor: colors.primary,
2277
+ backgroundColor: colors.uiBackgroundLight
2278
+ },
2279
+ pressed: {
2280
+ borderColor: colors.primary,
2281
+ backgroundColor: colors.uiBackgroundLight
2282
+ },
2283
+ disabled: {
2284
+ borderColor: colors.separator,
2285
+ backgroundColor: colors.disabled
2286
+ },
2287
+ transition: {
2288
+ duration: '200ms',
2289
+ timingFunction: 'ease-out'
2290
+ }
2266
2291
  };
2267
2292
 
2268
2293
  var datePicker = {
@@ -2458,18 +2483,31 @@ var inputTag = {
2458
2483
  var radio = {
2459
2484
  size: 18,
2460
2485
  unchecked: {
2461
- backgroundColor: colors.uiBackgroundLight,
2462
2486
  borderWidth: 2,
2487
+ backgroundColor: colors.uiBackgroundLight,
2463
2488
  borderColor: lateOceanColorPalette.black200
2464
2489
  },
2465
2490
  checked: {
2466
2491
  backgroundColor: colors.primary,
2492
+ borderColor: colors.transparent,
2467
2493
  innerSize: 5,
2468
2494
  innerBackgroundColor: colors.uiBackgroundLight
2469
2495
  },
2496
+ hover: {
2497
+ backgroundColor: colors.uiBackgroundLight,
2498
+ borderColor: colors.primary
2499
+ },
2500
+ pressed: {
2501
+ backgroundColor: colors.uiBackgroundLight,
2502
+ borderColor: colors.primary
2503
+ },
2470
2504
  disabled: {
2471
2505
  backgroundColor: colors.disabled,
2472
2506
  borderColor: colors.separator
2507
+ },
2508
+ transition: {
2509
+ duration: '200ms',
2510
+ timingFunction: 'ease-out'
2473
2511
  }
2474
2512
  };
2475
2513
 
@@ -2911,75 +2949,120 @@ function useKittTheme() {
2911
2949
  }, [dimensions]);
2912
2950
  }
2913
2951
 
2914
- var CheckboxAndLabelPressableWrapper = /*#__PURE__*/styled(BabelPluginStyledComponentsReactNative.Pressable).withConfig({
2915
- displayName: "Checkbox__CheckboxAndLabelPressableWrapper",
2916
- componentId: "kitt-universal__sc-1sav1n6-0"
2917
- })(["display:flex;flex-direction:row;"]);
2918
- var CheckboxContainer = /*#__PURE__*/styled(BabelPluginStyledComponentsReactNative.View).withConfig({
2919
- displayName: "Checkbox__CheckboxContainer",
2920
- componentId: "kitt-universal__sc-1sav1n6-1"
2921
- })(["display:flex;flex-direction:row;align-items:center;justify-content:center;height:", "px;width:", "px;position:relative;border-radius:", "px;", " margin-right:", ";"], function (_ref) {
2922
- var theme = _ref.theme;
2923
- return theme.kitt.forms.checkbox.height;
2924
- }, function (_ref2) {
2925
- var theme = _ref2.theme;
2926
- return theme.kitt.forms.checkbox.width;
2927
- }, function (_ref3) {
2928
- var theme = _ref3.theme;
2929
- return theme.kitt.forms.checkbox.borderRadius;
2930
- }, function (_ref4) {
2931
- var $isChecked = _ref4.$isChecked,
2932
- theme = _ref4.theme;
2933
- var _theme$kitt$forms$che = theme.kitt.forms.checkbox,
2934
- checkedBackgroundColor = _theme$kitt$forms$che.checkedBackgroundColor,
2935
- checkedBorderColor = _theme$kitt$forms$che.checkedBorderColor,
2936
- borderColor = _theme$kitt$forms$che.borderColor,
2937
- borderWidth = _theme$kitt$forms$che.borderWidth,
2938
- backgroundColor = _theme$kitt$forms$che.backgroundColor;
2939
- if ($isChecked) {
2940
- return css(["background-color:", ";border:", ";"], checkedBackgroundColor, "".concat(borderWidth, "px solid ").concat(checkedBorderColor));
2941
- }
2942
- return css(["background-color:", ";border:", ";"], backgroundColor, "".concat(borderWidth, "px solid ").concat(borderColor));
2943
- }, function (_ref5) {
2944
- var theme = _ref5.theme,
2945
- $hasLabel = _ref5.$hasLabel;
2946
- if (!$hasLabel) return '0px';
2947
- return "".concat(theme.kitt.spacing * 2.5, "px;");
2948
- });
2949
- function Checkbox(_ref6) {
2950
- var onChange = _ref6.onChange,
2951
- onBlur = _ref6.onBlur,
2952
- onFocus = _ref6.onFocus,
2953
- checked = _ref6.checked,
2954
- _ref6$hitSlop = _ref6.hitSlop,
2955
- hitSlop = _ref6$hitSlop === void 0 ? 40 : _ref6$hitSlop,
2956
- id = _ref6.id,
2957
- children = _ref6.children;
2952
+ function getBackgroundColor$1(_ref) {
2953
+ var isDisabled = _ref.isDisabled,
2954
+ isPressed = _ref.isPressed,
2955
+ isHovered = _ref.isHovered,
2956
+ isFocused = _ref.isFocused,
2957
+ isChecked = _ref.isChecked;
2958
+ if (isChecked) return 'kitt.forms.checkbox.checked.backgroundColor';
2959
+ if (isDisabled) return 'kitt.forms.checkbox.disabled.backgroundColor';
2960
+ if (isPressed) return 'kitt.forms.checkbox.pressed.backgroundColor';
2961
+ if (isHovered) return 'kitt.forms.checkbox.hover.backgroundColor';
2962
+ if (isFocused) return 'kitt.forms.checkbox.focus.backgroundColor';
2963
+ return 'kitt.forms.checkbox.default.backgroundColor';
2964
+ }
2965
+
2966
+ function getBorderColor$1(_ref) {
2967
+ var isDisabled = _ref.isDisabled,
2968
+ isPressed = _ref.isPressed,
2969
+ isHovered = _ref.isHovered,
2970
+ isFocused = _ref.isFocused,
2971
+ isChecked = _ref.isChecked;
2972
+ if (isChecked) return 'kitt.forms.checkbox.checked.borderColor';
2973
+ if (isDisabled) return 'kitt.forms.checkbox.disabled.borderColor';
2974
+ if (isPressed) return 'kitt.forms.checkbox.pressed.borderColor';
2975
+ if (isHovered) return 'kitt.forms.checkbox.hover.borderColor';
2976
+ if (isFocused) return 'kitt.forms.checkbox.focus.borderColor';
2977
+ return 'kitt.forms.checkbox.default.borderColor';
2978
+ }
2979
+
2980
+ var Checkbox = /*#__PURE__*/forwardRef(function (_ref, ref) {
2981
+ var checked = _ref.checked,
2982
+ _ref$hitSlop = _ref.hitSlop,
2983
+ hitSlop = _ref$hitSlop === void 0 ? 40 : _ref$hitSlop,
2984
+ id = _ref.id,
2985
+ _children = _ref.children,
2986
+ disabled = _ref.disabled,
2987
+ onChange = _ref.onChange,
2988
+ onBlur = _ref.onBlur,
2989
+ onFocus = _ref.onFocus;
2958
2990
  var theme = useKittTheme();
2959
- return /*#__PURE__*/jsxs(CheckboxAndLabelPressableWrapper, {
2991
+ return /*#__PURE__*/jsx(Pressable, {
2992
+ ref: ref,
2993
+ testID: id,
2960
2994
  accessibilityRole: "checkbox",
2961
2995
  accessibilityState: {
2962
2996
  checked: checked
2963
2997
  },
2964
2998
  hitSlop: hitSlop,
2999
+ disabled: disabled,
2965
3000
  onPress: function handlePress(e) {
2966
3001
  if (onFocus) onFocus(e);
2967
3002
  if (onChange) onChange(!checked, e);
2968
3003
  if (onBlur) onBlur(e);
2969
3004
  },
2970
- children: [/*#__PURE__*/jsx(CheckboxContainer, {
2971
- $isChecked: checked,
2972
- $hasLabel: !!children,
2973
- testID: id,
2974
- children: checked ? /*#__PURE__*/jsx(Icon, {
2975
- align: "center",
2976
- color: theme.kitt.forms.checkbox.markColor,
2977
- size: theme.kitt.forms.checkbox.iconSize,
2978
- icon: /*#__PURE__*/jsx(CheckboxMark, {})
2979
- }) : null
2980
- }), children]
3005
+ children: function children(_ref2) {
3006
+ var isHovered = _ref2.isHovered,
3007
+ isPressed = _ref2.isPressed,
3008
+ isFocused = _ref2.isFocused;
3009
+ return /*#__PURE__*/jsxs(HStack, {
3010
+ space: _children ? 'kitt.forms.checkbox.textSpacing' : undefined,
3011
+ children: [/*#__PURE__*/jsx(View, {
3012
+ display: "flex",
3013
+ flexDirection: "row",
3014
+ alignItems: "center",
3015
+ justifyContent: "center",
3016
+ marginTop: _children ? 'kitt.1' : undefined,
3017
+ height: "kitt.forms.checkbox.height",
3018
+ width: "kitt.forms.checkbox.width",
3019
+ borderRadius: "kitt.forms.checkbox.borderRadius",
3020
+ borderWidth: "kitt.forms.checkbox.borderWidth",
3021
+ borderColor: getBorderColor$1({
3022
+ isDisabled: disabled,
3023
+ isFocused: isFocused,
3024
+ isHovered: isHovered,
3025
+ isPressed: isPressed,
3026
+ isChecked: checked
3027
+ }),
3028
+ backgroundColor: getBackgroundColor$1({
3029
+ isDisabled: disabled,
3030
+ isFocused: isFocused,
3031
+ isHovered: isHovered,
3032
+ isPressed: isPressed,
3033
+ isChecked: checked
3034
+ }),
3035
+ _web: {
3036
+ style: {
3037
+ transitionDuration: theme.kitt.forms.checkbox.transition.duration,
3038
+ transitionProperty: 'all',
3039
+ transitionTimingFunction: theme.kitt.forms.checkbox.transition.timingFunction
3040
+ }
3041
+ },
3042
+ children: /*#__PURE__*/jsx(View, {
3043
+ opacity: checked ? 1 : 0,
3044
+ _web: {
3045
+ style: {
3046
+ transitionDuration: theme.kitt.forms.checkbox.transition.duration,
3047
+ transitionProperty: 'opacity',
3048
+ transitionTimingFunction: theme.kitt.forms.checkbox.transition.timingFunction
3049
+ }
3050
+ },
3051
+ children: /*#__PURE__*/jsx(Icon, {
3052
+ align: "center",
3053
+ color: theme.kitt.forms.checkbox.markColor,
3054
+ size: theme.kitt.forms.checkbox.iconSize,
3055
+ icon: /*#__PURE__*/jsx(CheckboxMark, {})
3056
+ })
3057
+ })
3058
+ }), _children ? /*#__PURE__*/jsx(View, {
3059
+ flexShrink: 1,
3060
+ children: _children
3061
+ }) : null]
3062
+ });
3063
+ }
2981
3064
  });
2982
- }
3065
+ });
2983
3066
 
2984
3067
  function prefixWithZero(value) {
2985
3068
  var maxLength = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 2;
@@ -3297,7 +3380,8 @@ var InputPart = /*#__PURE__*/forwardRef(function (_ref2, ref) {
3297
3380
  isHoveredInternal = _ref2.isHoveredInternal,
3298
3381
  isPressedInternal = _ref2.isPressedInternal,
3299
3382
  onChange = _ref2.onChange,
3300
- onBlur = _ref2.onBlur;
3383
+ onBlur = _ref2.onBlur,
3384
+ onSubmitEditing = _ref2.onSubmitEditing;
3301
3385
  return /*#__PURE__*/jsx(InputText, {
3302
3386
  ref: ref,
3303
3387
  internalForceState: getCurrentInternalForcedState({
@@ -3312,7 +3396,8 @@ var InputPart = /*#__PURE__*/forwardRef(function (_ref2, ref) {
3312
3396
  keyboardType: "numeric",
3313
3397
  textAlign: "center",
3314
3398
  onChange: onChange,
3315
- onBlur: onBlur
3399
+ onBlur: onBlur,
3400
+ onSubmitEditing: onSubmitEditing
3316
3401
  });
3317
3402
  });
3318
3403
 
@@ -3328,8 +3413,8 @@ function PartContainer(_ref) {
3328
3413
  });
3329
3414
  }
3330
3415
 
3331
- var _excluded$h = ["value", "testID", "id", "stretch", "placeholder", "minDate", "maxDate", "disabled", "isFocusedInternal", "isHoveredInternal", "isPressedInternal", "onChange", "onBlur", "onFocus"];
3332
- function KeyboardDatePicker(_ref) {
3416
+ var _excluded$h = ["value", "testID", "id", "stretch", "placeholder", "minDate", "maxDate", "disabled", "isFocusedInternal", "isHoveredInternal", "isPressedInternal", "onChange", "onBlur", "onFocus", "onSubmitEditing"];
3417
+ var KeyboardDatePicker = /*#__PURE__*/forwardRef(function (_ref, ref) {
3333
3418
  var value = _ref.value,
3334
3419
  testID = _ref.testID,
3335
3420
  id = _ref.id,
@@ -3343,9 +3428,9 @@ function KeyboardDatePicker(_ref) {
3343
3428
  isPressedInternal = _ref.isPressedInternal,
3344
3429
  onChange = _ref.onChange,
3345
3430
  onBlur = _ref.onBlur,
3346
- onFocus = _ref.onFocus;
3431
+ onFocus = _ref.onFocus,
3432
+ onSubmitEditing = _ref.onSubmitEditing;
3347
3433
  _objectWithoutProperties(_ref, _excluded$h);
3348
- var dayRef = useRef(null);
3349
3434
  var monthRef = useRef(null);
3350
3435
  var yearRef = useRef(null);
3351
3436
  var defaultValue = value;
@@ -3384,7 +3469,7 @@ function KeyboardDatePicker(_ref) {
3384
3469
  isStretch: stretch,
3385
3470
  width: "kitt.forms.datePicker.day.minWidth",
3386
3471
  children: /*#__PURE__*/jsx(InputPart, _objectSpread(_objectSpread({
3387
- ref: dayRef
3472
+ ref: ref
3388
3473
  }, sharedInputPartProps), {}, {
3389
3474
  placeholder: placeholder === null || placeholder === void 0 ? void 0 : placeholder.day,
3390
3475
  value: state.displayedDay,
@@ -3402,6 +3487,9 @@ function KeyboardDatePicker(_ref) {
3402
3487
  return dispatch({
3403
3488
  type: 'day-blur'
3404
3489
  });
3490
+ },
3491
+ onSubmitEditing: function () {
3492
+ if (monthRef.current) monthRef.current.focus();
3405
3493
  }
3406
3494
  }))
3407
3495
  }), /*#__PURE__*/jsx(PartContainer, {
@@ -3426,6 +3514,9 @@ function KeyboardDatePicker(_ref) {
3426
3514
  return dispatch({
3427
3515
  type: 'month-blur'
3428
3516
  });
3517
+ },
3518
+ onSubmitEditing: function () {
3519
+ if (yearRef.current) yearRef.current.focus();
3429
3520
  }
3430
3521
  }))
3431
3522
  }), /*#__PURE__*/jsx(PartContainer, {
@@ -3446,12 +3537,13 @@ function KeyboardDatePicker(_ref) {
3446
3537
  return dispatch({
3447
3538
  type: 'year-blur'
3448
3539
  });
3449
- }
3540
+ },
3541
+ onSubmitEditing: onSubmitEditing
3450
3542
  }))
3451
3543
  })]
3452
3544
  })
3453
3545
  });
3454
- }
3546
+ });
3455
3547
 
3456
3548
  var _excluded$g = ["value"];
3457
3549
  function DatePicker(_ref) {
@@ -3464,14 +3556,15 @@ function DatePicker(_ref) {
3464
3556
  }));
3465
3557
  }
3466
3558
 
3467
- function InputEmail(props) {
3559
+ var InputEmail = /*#__PURE__*/forwardRef(function (props, ref) {
3468
3560
  return /*#__PURE__*/jsx(InputText, _objectSpread({
3561
+ ref: ref,
3469
3562
  autoComplete: "email",
3470
3563
  keyboardType: "email-address",
3471
3564
  textContentType: "emailAddress",
3472
3565
  autoCapitalize: "none"
3473
3566
  }, props));
3474
- }
3567
+ });
3475
3568
 
3476
3569
  var getColorFromState = function (state) {
3477
3570
  switch (state) {
@@ -3548,7 +3641,7 @@ function InputPressable(_ref) {
3548
3641
  }
3549
3642
 
3550
3643
  var _excluded$f = ["isPasswordDefaultVisible", "right"];
3551
- function InputPassword(_ref) {
3644
+ var InputPassword = /*#__PURE__*/forwardRef(function (_ref, ref) {
3552
3645
  var isPasswordDefaultVisible = _ref.isPasswordDefaultVisible,
3553
3646
  right = _ref.right,
3554
3647
  props = _objectWithoutProperties(_ref, _excluded$f);
@@ -3556,7 +3649,9 @@ function InputPassword(_ref) {
3556
3649
  _useState2 = _slicedToArray(_useState, 2),
3557
3650
  isVisible = _useState2[0],
3558
3651
  setIsVisible = _useState2[1];
3559
- return /*#__PURE__*/jsx(InputText, _objectSpread(_objectSpread({}, props), {}, {
3652
+ return /*#__PURE__*/jsx(InputText, _objectSpread(_objectSpread({
3653
+ ref: ref
3654
+ }, props), {}, {
3560
3655
  textContentType: "password",
3561
3656
  autoComplete: "password",
3562
3657
  autoCorrect: false,
@@ -3574,15 +3669,17 @@ function InputPassword(_ref) {
3574
3669
  })
3575
3670
  })
3576
3671
  }));
3577
- }
3672
+ });
3578
3673
 
3579
- function InputPhone(props) {
3580
- return /*#__PURE__*/jsx(InputText, _objectSpread(_objectSpread({}, props), {}, {
3674
+ var InputPhone = /*#__PURE__*/forwardRef(function (props, ref) {
3675
+ return /*#__PURE__*/jsx(InputText, _objectSpread(_objectSpread({
3676
+ ref: ref
3677
+ }, props), {}, {
3581
3678
  autoComplete: "tel",
3582
3679
  keyboardType: "number-pad",
3583
3680
  textContentType: "telephoneNumber"
3584
3681
  }));
3585
- }
3682
+ });
3586
3683
 
3587
3684
  var getTypographyColor = function (type) {
3588
3685
  return type ? 'white' : 'black';
@@ -3648,101 +3745,150 @@ function Label(_ref) {
3648
3745
  });
3649
3746
  }
3650
3747
 
3651
- var OuterRadio = /*#__PURE__*/styled(BabelPluginStyledComponentsReactNative.View).withConfig({
3652
- displayName: "Radio__OuterRadio",
3653
- componentId: "kitt-universal__sc-1mdgr2o-0"
3654
- })(["background-color:", ";width:", "px;height:", "px;border-radius:", "px;border-width:", "px;border-color:", ";"], function (_ref) {
3655
- var theme = _ref.theme,
3656
- disabled = _ref.disabled;
3657
- return theme.kitt.forms.radio[disabled ? 'disabled' : 'unchecked'].backgroundColor;
3658
- }, function (_ref2) {
3659
- var theme = _ref2.theme;
3660
- return theme.kitt.forms.radio.size;
3661
- }, function (_ref3) {
3662
- var theme = _ref3.theme;
3663
- return theme.kitt.forms.radio.size;
3664
- }, function (_ref4) {
3665
- var theme = _ref4.theme;
3666
- return theme.kitt.forms.radio.size / 2;
3667
- }, function (_ref5) {
3668
- var theme = _ref5.theme;
3669
- return theme.kitt.forms.radio.unchecked.borderWidth;
3670
- }, function (_ref6) {
3671
- var theme = _ref6.theme,
3672
- disabled = _ref6.disabled;
3673
- return theme.kitt.forms.radio[disabled ? 'disabled' : 'unchecked'].borderColor;
3674
- });
3675
- var SelectedOuterRadio = /*#__PURE__*/styled(BabelPluginStyledComponentsReactNative.View).withConfig({
3676
- displayName: "Radio__SelectedOuterRadio",
3677
- componentId: "kitt-universal__sc-1mdgr2o-1"
3678
- })(["background-color:", ";width:", "px;height:", "px;border-radius:", "px;justify-content:center;align-items:center;"], function (_ref7) {
3679
- var theme = _ref7.theme;
3680
- return theme.kitt.forms.radio.checked.backgroundColor;
3681
- }, function (_ref8) {
3682
- var theme = _ref8.theme;
3683
- return theme.kitt.forms.radio.size;
3684
- }, function (_ref9) {
3685
- var theme = _ref9.theme;
3686
- return theme.kitt.forms.radio.size;
3687
- }, function (_ref10) {
3688
- var theme = _ref10.theme;
3689
- return theme.kitt.forms.radio.size / 2;
3690
- });
3691
- var SelectedInnerRadio = /*#__PURE__*/styled(BabelPluginStyledComponentsReactNative.View).withConfig({
3692
- displayName: "Radio__SelectedInnerRadio",
3693
- componentId: "kitt-universal__sc-1mdgr2o-2"
3694
- })(["background-color:", ";width:", "px;height:", "px;border-radius:", "px;"], function (_ref11) {
3695
- var theme = _ref11.theme;
3696
- return theme.kitt.forms.radio.checked.innerBackgroundColor;
3697
- }, function (_ref12) {
3698
- var theme = _ref12.theme;
3699
- return theme.kitt.forms.radio.checked.innerSize;
3700
- }, function (_ref13) {
3701
- var theme = _ref13.theme;
3702
- return theme.kitt.forms.radio.checked.innerSize;
3703
- }, function (_ref14) {
3704
- var theme = _ref14.theme;
3705
- return theme.kitt.forms.radio.checked.innerSize / 2;
3706
- });
3707
- var Container$1 = /*#__PURE__*/styled(BabelPluginStyledComponentsReactNative.Pressable).withConfig({
3708
- displayName: "Radio__Container",
3709
- componentId: "kitt-universal__sc-1mdgr2o-3"
3710
- })(["flex-direction:row;align-items:center;"]);
3711
- var Text = /*#__PURE__*/styled(Typography.Text).withConfig({
3712
- displayName: "Radio__Text",
3713
- componentId: "kitt-universal__sc-1mdgr2o-4"
3714
- })(["margin-left:", "px;"], function (_ref15) {
3715
- var theme = _ref15.theme;
3716
- return theme.kitt.spacing * 2;
3717
- });
3718
- function Radio(_ref16) {
3719
- var id = _ref16.id,
3720
- checked = _ref16.checked,
3721
- onChange = _ref16.onChange,
3722
- value = _ref16.value,
3723
- _ref16$disabled = _ref16.disabled,
3724
- disabled = _ref16$disabled === void 0 ? false : _ref16$disabled,
3725
- children = _ref16.children;
3726
- return /*#__PURE__*/jsxs(Container$1, {
3748
+ function InnerCircle(_ref) {
3749
+ var isChecked = _ref.isChecked;
3750
+ var theme = /*#__PURE__*/useTheme();
3751
+ var sharedTransform = [{
3752
+ scale: isChecked ? 1 : 0
3753
+ }];
3754
+ return /*#__PURE__*/jsx(View, {
3755
+ width: "kitt.forms.radio.innerCircle.size",
3756
+ height: "kitt.forms.radio.innerCircle.size",
3757
+ borderRadius: "kitt.forms.radio.innerCircle.borderRadius",
3758
+ backgroundColor: "kitt.forms.radio.innerCircle.backgroundColor",
3759
+ _web: {
3760
+ style: {
3761
+ transform: sharedTransform,
3762
+ transitionProperty: 'all',
3763
+ transitionDuration: theme.kitt.forms.radio.transition.duration,
3764
+ transitionTimingFunction: theme.kitt.forms.radio.transition.timingFunction
3765
+ }
3766
+ },
3767
+ _ios: {
3768
+ style: {
3769
+ transform: sharedTransform
3770
+ }
3771
+ },
3772
+ _android: {
3773
+ style: {
3774
+ transform: sharedTransform
3775
+ }
3776
+ }
3777
+ });
3778
+ }
3779
+
3780
+ function getBackgroundColor(_ref) {
3781
+ var isDisabled = _ref.isDisabled,
3782
+ isPressed = _ref.isPressed,
3783
+ isHovered = _ref.isHovered,
3784
+ isFocused = _ref.isFocused,
3785
+ isChecked = _ref.isChecked;
3786
+ if (isChecked) return 'kitt.forms.radio.checked.backgroundColor';
3787
+ if (isDisabled) return 'kitt.forms.radio.disabled.backgroundColor';
3788
+ if (isPressed) return 'kitt.forms.radio.pressed.backgroundColor';
3789
+ if (isHovered) return 'kitt.forms.radio.hover.backgroundColor';
3790
+ if (isFocused) return 'kitt.forms.radio.focus.backgroundColor';
3791
+ return 'kitt.forms.radio.default.backgroundColor';
3792
+ }
3793
+
3794
+ function getBorderColor(_ref) {
3795
+ var isDisabled = _ref.isDisabled,
3796
+ isPressed = _ref.isPressed,
3797
+ isHovered = _ref.isHovered,
3798
+ isFocused = _ref.isFocused,
3799
+ isChecked = _ref.isChecked;
3800
+ if (isChecked) return 'kitt.forms.radio.checked.borderColor';
3801
+ if (isDisabled) return 'kitt.forms.radio.disabled.borderColor';
3802
+ if (isPressed) return 'kitt.forms.radio.pressed.borderColor';
3803
+ if (isHovered) return 'kitt.forms.radio.hover.borderColor';
3804
+ if (isFocused) return 'kitt.forms.radio.focus.borderColor';
3805
+ return 'kitt.forms.radio.default.borderColor';
3806
+ }
3807
+
3808
+ function OuterCircle(_ref) {
3809
+ var children = _ref.children,
3810
+ isChecked = _ref.isChecked,
3811
+ isDisabled = _ref.isDisabled,
3812
+ isHovered = _ref.isHovered,
3813
+ isFocused = _ref.isFocused,
3814
+ isPressed = _ref.isPressed;
3815
+ var theme = /*#__PURE__*/useTheme();
3816
+ return /*#__PURE__*/jsx(View, {
3817
+ alignItems: "center",
3818
+ justifyContent: "center",
3819
+ borderWidth: "kitt.forms.radio.borderWidth",
3820
+ width: "kitt.forms.radio.size",
3821
+ height: "kitt.forms.radio.size",
3822
+ borderRadius: "kitt.forms.radio.borderRadius",
3823
+ backgroundColor: getBackgroundColor({
3824
+ isChecked: isChecked,
3825
+ isDisabled: isDisabled,
3826
+ isFocused: isFocused,
3827
+ isHovered: isHovered,
3828
+ isPressed: isPressed
3829
+ }),
3830
+ borderColor: getBorderColor({
3831
+ isChecked: isChecked,
3832
+ isDisabled: isDisabled,
3833
+ isFocused: isFocused,
3834
+ isHovered: isHovered,
3835
+ isPressed: isPressed
3836
+ }),
3837
+ _web: {
3838
+ style: {
3839
+ transitionProperty: 'all',
3840
+ transitionDuration: theme.kitt.forms.radio.transition.duration,
3841
+ transitionTimingFunction: theme.kitt.forms.radio.transition.timingFunction
3842
+ }
3843
+ },
3844
+ children: children
3845
+ });
3846
+ }
3847
+
3848
+ var Radio = /*#__PURE__*/forwardRef(function (_ref, ref) {
3849
+ var id = _ref.id,
3850
+ checked = _ref.checked,
3851
+ onChange = _ref.onChange,
3852
+ value = _ref.value,
3853
+ disabled = _ref.disabled,
3854
+ _children = _ref.children;
3855
+ return /*#__PURE__*/jsx(Pressable, {
3856
+ ref: ref,
3727
3857
  nativeID: id,
3728
3858
  disabled: disabled,
3729
3859
  accessibilityRole: "radio",
3730
3860
  "aria-checked": checked,
3731
3861
  focusable: checked && !disabled,
3862
+ flexDirection: "row",
3863
+ alignItems: "center",
3732
3864
  onPress: function handlePress() {
3733
3865
  onChange(value);
3734
3866
  },
3735
- children: [checked && !disabled ? /*#__PURE__*/jsx(SelectedOuterRadio, {
3736
- children: /*#__PURE__*/jsx(SelectedInnerRadio, {})
3737
- }) : /*#__PURE__*/jsx(OuterRadio, {
3738
- disabled: disabled
3739
- }), /*#__PURE__*/jsx(Text, {
3740
- base: "body",
3741
- color: disabled ? 'black-light' : 'black',
3742
- children: children
3743
- })]
3867
+ children: function children(_ref2) {
3868
+ var isHovered = _ref2.isHovered,
3869
+ isPressed = _ref2.isPressed,
3870
+ isFocused = _ref2.isFocused;
3871
+ return /*#__PURE__*/jsxs(HStack, {
3872
+ space: _children ? 'kitt.2' : undefined,
3873
+ alignItems: "center",
3874
+ children: [/*#__PURE__*/jsx(OuterCircle, {
3875
+ isChecked: checked,
3876
+ isDisabled: disabled,
3877
+ isHovered: isHovered,
3878
+ isFocused: isFocused,
3879
+ isPressed: isPressed,
3880
+ children: /*#__PURE__*/jsx(InnerCircle, {
3881
+ isChecked: checked
3882
+ })
3883
+ }), _children ? /*#__PURE__*/jsx(Typography.Text, {
3884
+ base: "body",
3885
+ color: disabled ? 'black-light' : 'black',
3886
+ children: _children
3887
+ }) : null]
3888
+ });
3889
+ }
3744
3890
  });
3745
- }
3891
+ });
3746
3892
 
3747
3893
  function getCurrentBackgroundColor(_ref) {
3748
3894
  var isFocused = _ref.isFocused,
@@ -3980,15 +4126,15 @@ function RadioButtonGroup(_ref2) {
3980
4126
  }
3981
4127
  RadioButtonGroup.RadioButton = RadioButtonGroupItem;
3982
4128
 
3983
- function TextArea(_ref) {
4129
+ var TextArea = /*#__PURE__*/forwardRef(function (_ref, ref) {
3984
4130
  var props = _extends({}, (_objectDestructuringEmpty(_ref), _ref));
3985
- var theme = /*#__PURE__*/useTheme();
3986
4131
  return /*#__PURE__*/jsx(InputText, _objectSpread({
4132
+ ref: ref,
3987
4133
  multiline: true,
3988
4134
  textAlignVertical: "top",
3989
- minHeight: theme.kitt.forms.textArea.minHeight
4135
+ minHeight: "kitt.forms.textArea.minHeight"
3990
4136
  }, props));
3991
- }
4137
+ });
3992
4138
 
3993
4139
  function Highlight(_ref) {
3994
4140
  var _ref$variant = _ref.variant,
@@ -4839,9 +4985,13 @@ Modal.Body = ModalBody;
4839
4985
  Modal.Footer = ModalFooter;
4840
4986
 
4841
4987
  var createKittSpaces = function (spacing) {
4842
- var sizes = {};
4988
+ var sizes = {
4989
+ positive: {},
4990
+ negative: {}
4991
+ };
4843
4992
  for (var size = 1; size <= 64; size++) {
4844
- sizes["kitt.".concat(size)] = size * spacing;
4993
+ sizes.positive["kitt.".concat(size)] = size * spacing;
4994
+ sizes.negative["-kitt.".concat(size)] = -size * spacing;
4845
4995
  }
4846
4996
  return sizes;
4847
4997
  };
@@ -4889,10 +5039,62 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
4889
5039
  backgroundColor: theme.forms.radioButtonGroup.item.backgroundColor
4890
5040
  }
4891
5041
  },
4892
- skeleton: {
4893
- backgroundColor: theme.skeleton.backgroundColor,
4894
- flareColor: theme.skeleton.flareColor
5042
+ checkbox: {
5043
+ markColor: theme.forms.checkbox.markColor,
5044
+ checked: {
5045
+ backgroundColor: theme.forms.checkbox.checked.backgroundColor,
5046
+ borderColor: theme.forms.checkbox.checked.borderColor
5047
+ },
5048
+ hover: {
5049
+ backgroundColor: theme.forms.checkbox.hover.backgroundColor,
5050
+ borderColor: theme.forms.checkbox.hover.borderColor
5051
+ },
5052
+ pressed: {
5053
+ backgroundColor: theme.forms.checkbox.pressed.backgroundColor,
5054
+ borderColor: theme.forms.checkbox.pressed.borderColor
5055
+ },
5056
+ focus: {
5057
+ backgroundColor: theme.forms.checkbox.focus.backgroundColor,
5058
+ borderColor: theme.forms.checkbox.focus.borderColor
5059
+ },
5060
+ "default": {
5061
+ backgroundColor: theme.forms.checkbox["default"].backgroundColor,
5062
+ borderColor: theme.forms.checkbox["default"].borderColor
5063
+ }
5064
+ },
5065
+ radio: {
5066
+ checked: {
5067
+ backgroundColor: theme.forms.radio.checked.backgroundColor,
5068
+ borderColor: theme.forms.radio.checked.borderColor
5069
+ },
5070
+ hover: {
5071
+ backgroundColor: theme.forms.radio.hover.backgroundColor,
5072
+ borderColor: theme.forms.radio.hover.borderColor
5073
+ },
5074
+ pressed: {
5075
+ backgroundColor: theme.forms.radio.pressed.backgroundColor,
5076
+ borderColor: theme.forms.radio.pressed.borderColor
5077
+ },
5078
+ focus: {
5079
+ backgroundColor: theme.forms.radio.pressed.backgroundColor,
5080
+ borderColor: theme.forms.radio.pressed.borderColor
5081
+ },
5082
+ disabled: {
5083
+ backgroundColor: theme.forms.radio.disabled.backgroundColor,
5084
+ borderColor: theme.forms.radio.disabled.borderColor
5085
+ },
5086
+ "default": {
5087
+ backgroundColor: theme.forms.radio.unchecked.backgroundColor,
5088
+ borderColor: theme.forms.radio.unchecked.borderColor
5089
+ },
5090
+ innerCircle: {
5091
+ backgroundColor: theme.forms.radio.checked.innerBackgroundColor
5092
+ }
4895
5093
  }
5094
+ },
5095
+ skeleton: {
5096
+ backgroundColor: theme.skeleton.backgroundColor,
5097
+ flareColor: theme.skeleton.flareColor
4896
5098
  }
4897
5099
  }),
4898
5100
  app: appTheme === null || appTheme === void 0 ? void 0 : appTheme.colors
@@ -4904,7 +5106,7 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
4904
5106
  sm: Number.MAX_SAFE_INTEGER,
4905
5107
  xl: Number.MAX_SAFE_INTEGER,
4906
5108
  xs: Number.MAX_SAFE_INTEGER
4907
- }, spaces), {}, {
5109
+ }, spaces.positive), {}, {
4908
5110
  kitt: {
4909
5111
  avatar: {
4910
5112
  borderRadius: theme.avatar.borderRadius,
@@ -4933,6 +5135,15 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
4933
5135
  item: {
4934
5136
  borderRadius: theme.forms.radioButtonGroup.item.borderRadius
4935
5137
  }
5138
+ },
5139
+ checkbox: {
5140
+ borderRadius: theme.forms.checkbox.borderRadius
5141
+ },
5142
+ radio: {
5143
+ borderRadius: theme.forms.radio.size * 0.5,
5144
+ innerCircle: {
5145
+ borderRadius: theme.forms.radio.checked.innerSize * 0.5
5146
+ }
4936
5147
  }
4937
5148
  },
4938
5149
  tooltip: {
@@ -4967,6 +5178,12 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
4967
5178
  item: {
4968
5179
  borderWidth: theme.forms.radioButtonGroup.item.borderWidth
4969
5180
  }
5181
+ },
5182
+ checkbox: {
5183
+ borderWidth: theme.forms.checkbox.borderWidth
5184
+ },
5185
+ radio: {
5186
+ borderWidth: theme.forms.radio.unchecked.borderWidth
4970
5187
  }
4971
5188
  },
4972
5189
  cardModal: {
@@ -4980,7 +5197,7 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
4980
5197
  },
4981
5198
  app: appTheme === null || appTheme === void 0 ? void 0 : appTheme.borderWidths
4982
5199
  },
4983
- sizes: _objectSpread(_objectSpread(_objectSpread({}, spaces), overridenNativeBaseSizeandSpaceScale), {}, {
5200
+ sizes: _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, spaces.positive), spaces.negative), overridenNativeBaseSizeandSpaceScale), {}, {
4984
5201
  kitt: {
4985
5202
  avatar: {
4986
5203
  size: theme.avatar.size,
@@ -5026,6 +5243,21 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
5026
5243
  item: {
5027
5244
  minHeight: theme.forms.radioButtonGroup.item.minHeight
5028
5245
  }
5246
+ },
5247
+ checkbox: {
5248
+ height: theme.forms.checkbox.height,
5249
+ width: theme.forms.checkbox.width,
5250
+ iconSize: theme.forms.checkbox.iconSize,
5251
+ textSpacing: theme.forms.checkbox.textSpacing
5252
+ },
5253
+ radio: {
5254
+ size: theme.forms.radio.size,
5255
+ innerCircle: {
5256
+ size: theme.forms.radio.checked.innerSize
5257
+ }
5258
+ },
5259
+ textArea: {
5260
+ minHeight: theme.forms.textArea.minHeight
5029
5261
  }
5030
5262
  },
5031
5263
  iconButton: {
@@ -5054,7 +5286,7 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
5054
5286
  },
5055
5287
  app: appTheme === null || appTheme === void 0 ? void 0 : appTheme.sizes
5056
5288
  }),
5057
- space: _objectSpread(_objectSpread(_objectSpread({}, spaces), overridenNativeBaseSizeandSpaceScale), {}, {
5289
+ space: _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, spaces.positive), spaces.negative), overridenNativeBaseSizeandSpaceScale), {}, {
5058
5290
  kitt: {
5059
5291
  button: {
5060
5292
  padding: theme.button.padding