@ornikar/kitt-universal 23.0.2 → 23.2.1

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 (75) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/dist/definitions/Highlight/AnimatedCaret/AnimatedCaret.d.ts +11 -0
  3. package/dist/definitions/Highlight/AnimatedCaret/AnimatedCaret.d.ts.map +1 -0
  4. package/dist/definitions/Highlight/AnimatedCaret/AnimatedCaret.web.d.ts +4 -0
  5. package/dist/definitions/Highlight/AnimatedCaret/AnimatedCaret.web.d.ts.map +1 -0
  6. package/dist/definitions/Highlight/AnimatedContainer/AnimatedContainer.d.ts +13 -0
  7. package/dist/definitions/Highlight/AnimatedContainer/AnimatedContainer.d.ts.map +1 -0
  8. package/dist/definitions/Highlight/AnimatedContainer/AnimatedContainer.web.d.ts +4 -0
  9. package/dist/definitions/Highlight/AnimatedContainer/AnimatedContainer.web.d.ts.map +1 -0
  10. package/dist/definitions/Highlight/AnimatedContent/AnimatedContent.d.ts +12 -0
  11. package/dist/definitions/Highlight/AnimatedContent/AnimatedContent.d.ts.map +1 -0
  12. package/dist/definitions/Highlight/AnimatedContent/AnimatedContent.web.d.ts +4 -0
  13. package/dist/definitions/Highlight/AnimatedContent/AnimatedContent.web.d.ts.map +1 -0
  14. package/dist/definitions/Highlight/Highlight.d.ts +10 -5
  15. package/dist/definitions/Highlight/Highlight.d.ts.map +1 -1
  16. package/dist/definitions/Highlight/hooks/useNativeAnimation.d.ts +18 -0
  17. package/dist/definitions/Highlight/hooks/useNativeAnimation.d.ts.map +1 -0
  18. package/dist/definitions/Highlight/hooks/useNativeAnimation.web.d.ts +3 -0
  19. package/dist/definitions/Highlight/hooks/useNativeAnimation.web.d.ts.map +1 -0
  20. package/dist/definitions/TimePicker/ModalDateTimePicker.d.ts +4 -1
  21. package/dist/definitions/TimePicker/ModalDateTimePicker.d.ts.map +1 -1
  22. package/dist/definitions/TimePicker/TimePicker.d.ts +2 -0
  23. package/dist/definitions/TimePicker/TimePicker.d.ts.map +1 -1
  24. package/dist/definitions/forms/InputText/InputTextContainer.web.d.ts.map +1 -1
  25. package/dist/definitions/native-base/KittNativeBaseProvider.d.ts +37 -11
  26. package/dist/definitions/native-base/KittNativeBaseProvider.d.ts.map +1 -1
  27. package/dist/definitions/themes/default.d.ts +1 -4
  28. package/dist/definitions/themes/default.d.ts.map +1 -1
  29. package/dist/definitions/themes/late-ocean/forms.d.ts +1 -4
  30. package/dist/definitions/themes/late-ocean/forms.d.ts.map +1 -1
  31. package/dist/definitions/themes/late-ocean/highlight.d.ts +11 -2
  32. package/dist/definitions/themes/late-ocean/highlight.d.ts.map +1 -1
  33. package/dist/definitions/themes/late-ocean/input.d.ts +2 -2
  34. package/dist/definitions/themes/late-ocean/input.d.ts.map +1 -1
  35. package/dist/definitions/themes/late-ocean/inputField.d.ts +1 -4
  36. package/dist/definitions/themes/late-ocean/inputField.d.ts.map +1 -1
  37. package/dist/definitions/utils/windowSize/MatchWindowSize.d.ts +1 -1
  38. package/dist/definitions/utils/windowSize/MatchWindowSize.d.ts.map +1 -1
  39. package/dist/index-metro.es.android.js +487 -205
  40. package/dist/index-metro.es.android.js.map +1 -1
  41. package/dist/index-metro.es.ios.js +487 -205
  42. package/dist/index-metro.es.ios.js.map +1 -1
  43. package/dist/index-node-20.10.cjs.js +486 -204
  44. package/dist/index-node-20.10.cjs.js.map +1 -1
  45. package/dist/index-node-20.10.cjs.web.css +1 -1
  46. package/dist/index-node-20.10.cjs.web.js +451 -203
  47. package/dist/index-node-20.10.cjs.web.js.map +1 -1
  48. package/dist/index-node-20.10.es.mjs +487 -205
  49. package/dist/index-node-20.10.es.mjs.map +1 -1
  50. package/dist/index-node-20.10.es.web.css +1 -1
  51. package/dist/index-node-20.10.es.web.mjs +452 -204
  52. package/dist/index-node-20.10.es.web.mjs.map +1 -1
  53. package/dist/index.es.js +501 -212
  54. package/dist/index.es.js.map +1 -1
  55. package/dist/index.es.web.js +467 -211
  56. package/dist/index.es.web.js.map +1 -1
  57. package/dist/linaria-themes-metro.es.android.js +212 -183
  58. package/dist/linaria-themes-metro.es.android.js.map +1 -1
  59. package/dist/linaria-themes-metro.es.ios.js +212 -183
  60. package/dist/linaria-themes-metro.es.ios.js.map +1 -1
  61. package/dist/linaria-themes-node-20.10.cjs.js +212 -183
  62. package/dist/linaria-themes-node-20.10.cjs.js.map +1 -1
  63. package/dist/linaria-themes-node-20.10.cjs.web.js +212 -183
  64. package/dist/linaria-themes-node-20.10.cjs.web.js.map +1 -1
  65. package/dist/linaria-themes-node-20.10.es.mjs +212 -183
  66. package/dist/linaria-themes-node-20.10.es.mjs.map +1 -1
  67. package/dist/linaria-themes-node-20.10.es.web.mjs +212 -183
  68. package/dist/linaria-themes-node-20.10.es.web.mjs.map +1 -1
  69. package/dist/linaria-themes.es.js +218 -189
  70. package/dist/linaria-themes.es.js.map +1 -1
  71. package/dist/linaria-themes.es.web.js +218 -189
  72. package/dist/linaria-themes.es.web.js.map +1 -1
  73. package/dist/styles.css +1 -1
  74. package/dist/tsbuildinfo +1 -1
  75. package/package.json +1 -1
@@ -9,7 +9,7 @@ import { CSSTransition } from 'react-transition-group';
9
9
  import { ScrollView as ScrollView$2, View as View$2, Linking, Pressable as Pressable$2, useWindowDimensions } from 'react-native';
10
10
  export { useWindowDimensions as useWindowSize } from 'react-native';
11
11
  import { parse } from 'twemoji-parser';
12
- import { CaretUpFillIcon, CaretDownFillIcon, EyeClosedRegularIcon, EyeRegularIcon, XRegularIcon } from '@ornikar/kitt-icons/phosphor';
12
+ import { CaretUpFillIcon, CaretDownFillIcon, EyeClosedRegularIcon, EyeRegularIcon, CaretDownRegularIcon, XRegularIcon } from '@ornikar/kitt-icons/phosphor';
13
13
  import Downshift, { useSelect } from 'downshift';
14
14
  import { useDebouncedCallback } from 'use-debounce';
15
15
  import { Loader } from '@googlemaps/js-api-loader';
@@ -962,209 +962,64 @@ const datePicker = {
962
962
  }
963
963
  };
964
964
 
965
- const calcLineHeight = (fontSize, lineHeightMultiplier) => Math.round(fontSize * lineHeightMultiplier);
966
- /** @deprecated legacy typography type config is deprecated. */
967
- const createLegacyTypographyTypeConfig = (lineHeightMultiplierBaseAndSmall, baseAndSmallFontSize, mediumAndWideFontSize = baseAndSmallFontSize, lineHeightMultiplierMediumAndWide = lineHeightMultiplierBaseAndSmall) => ({
968
- baseAndSmall: {
969
- fontSize: baseAndSmallFontSize,
970
- lineHeight: calcLineHeight(baseAndSmallFontSize, lineHeightMultiplierBaseAndSmall)
971
- },
972
- mediumAndWide: {
973
- fontSize: mediumAndWideFontSize,
974
- lineHeight: calcLineHeight(mediumAndWideFontSize, lineHeightMultiplierMediumAndWide)
975
- }
976
- });
977
- const createTypographyConfig = (fontSize, lineHeightMultiplier) => {
978
- const config = {
979
- fontSize,
980
- lineHeight: calcLineHeight(fontSize, lineHeightMultiplier)
981
- };
982
- return {
983
- baseAndSmall: config,
984
- mediumAndWide: config
985
- };
986
- };
987
- const typography = {
988
- colors: {
989
- black: colors.black,
990
- 'black-anthracite': colors.blackAnthracite,
991
- 'black-disabled': lateOceanColorPalette.black400,
992
- 'black-light': lateOceanColorPalette.black555,
993
- white: colors.white,
994
- 'white-light': colors.white,
995
- primary: colors.primary,
996
- 'primary-light': colors.primaryLight,
997
- accent: colors.accent,
998
- success: colors.success,
999
- danger: colors.danger,
1000
- warning: colors.warning
1001
- },
1002
- types: {
1003
- headings: {
1004
- fontFamily: {
1005
- native: {
1006
- regular: 'Moderat-Bold',
1007
- bold: 'Moderat-Bold'
1008
- },
1009
- web: {
1010
- regular: 'Moderat',
1011
- bold: 'Moderat'
1012
- }
1013
- },
1014
- fontWeight: {
1015
- regular: 400,
1016
- bold: 700
1017
- },
1018
- fontStyle: 'normal',
1019
- configs: {
1020
- /* legacy */
1021
- header1: createLegacyTypographyTypeConfig(1.1, 40, 56),
1022
- header2: createLegacyTypographyTypeConfig(1.2, 32, 48, 1.1),
1023
- header3: createLegacyTypographyTypeConfig(1.2, 24, 40, 1.1),
1024
- header4: createLegacyTypographyTypeConfig(1.3, 18, 24, 1.2),
1025
- header5: createLegacyTypographyTypeConfig(1.3, 18, 18),
1026
- /* latest */
1027
- 'heading-xxl': createTypographyConfig(56, 1.1),
1028
- 'heading-xl': createTypographyConfig(48, 1.1),
1029
- 'heading-l': createTypographyConfig(40, 1.1),
1030
- 'heading-m': createTypographyConfig(32, 1.2),
1031
- 'heading-s': createTypographyConfig(24, 1.2),
1032
- 'heading-xs': createTypographyConfig(18, 1.3),
1033
- 'heading-xxs': createTypographyConfig(16, 1.3)
1034
- }
1035
- },
1036
- 'headings-impact': {
1037
- fontFamily: {
1038
- native: {
1039
- regular: 'Transducer-Black',
1040
- bold: 'Transducer-Black'
1041
- },
1042
- web: {
1043
- regular: 'TransducerBlack',
1044
- bold: 'TransducerBlack'
1045
- }
1046
- },
1047
- fontWeight: 900,
1048
- fontStyle: 'normal',
1049
- configs: {
1050
- /* legacy */
1051
- 'header-impact-xxl': createLegacyTypographyTypeConfig(1.2, 56, 56),
1052
- 'header-impact-xl': createLegacyTypographyTypeConfig(1.2, 48, 48),
1053
- 'header-impact-l': createLegacyTypographyTypeConfig(1.2, 40, 40),
1054
- 'header-impact-m': createLegacyTypographyTypeConfig(1.2, 32, 32),
1055
- 'header-impact-s': createLegacyTypographyTypeConfig(1.2, 24, 24),
1056
- 'header-impact-xs': createLegacyTypographyTypeConfig(1.2, 18, 18),
1057
- 'header-impact-xxs': createLegacyTypographyTypeConfig(1.2, 16, 16),
1058
- 'header-impact-xxxs': createLegacyTypographyTypeConfig(1.2, 14, 14),
1059
- /* latest */
1060
- 'heading-impact-xxl': createTypographyConfig(56, 1.2),
1061
- 'heading-impact-xl': createTypographyConfig(48, 1.2),
1062
- 'heading-impact-l': createTypographyConfig(40, 1.2),
1063
- 'heading-impact-m': createTypographyConfig(32, 1.2),
1064
- 'heading-impact-s': createTypographyConfig(24, 1.2),
1065
- 'heading-impact-xs': createTypographyConfig(18, 1.2),
1066
- 'heading-impact-xxs': createTypographyConfig(16, 1.2),
1067
- 'heading-impact-xxxs': createTypographyConfig(14, 1.2)
1068
- }
1069
- },
1070
- bodies: {
1071
- fontFamily: {
1072
- web: {
1073
- regular: 'Moderat',
1074
- bold: 'Moderat'
1075
- },
1076
- native: {
1077
- regular: 'Moderat-Regular',
1078
- bold: 'Moderat-Bold'
1079
- }
1080
- },
1081
- fontWeight: {
1082
- regular: 400,
1083
- bold: 700
1084
- },
1085
- fontStyle: {
1086
- regular: 'normal',
1087
- bold: 'normal'
1088
- },
1089
- configs: {
1090
- /* legacy */
1091
- 'body-large': createLegacyTypographyTypeConfig(1.4, 18, 24),
1092
- 'body-medium': createLegacyTypographyTypeConfig(1.4, 18, 18),
1093
- body: createLegacyTypographyTypeConfig(1.4, 16, 16),
1094
- 'body-small': createLegacyTypographyTypeConfig(1.4, 14, 14),
1095
- 'body-xsmall': createLegacyTypographyTypeConfig(1.4, 12, 12),
1096
- /* latest */
1097
- 'body-xl': createTypographyConfig(24, 1.4),
1098
- 'body-l': createTypographyConfig(18, 1.4),
1099
- 'body-m': createTypographyConfig(16, 1.4),
1100
- 'body-s': createTypographyConfig(14, 1.4),
1101
- 'body-xs': createTypographyConfig(12, 1.4)
1102
- }
1103
- }
1104
- },
1105
- link: {
1106
- /** @deprecated not used in kitt anymore, use Typography instead */
1107
- disabledColor: colors.blackDisabled
1108
- }
1109
- };
1110
-
1111
965
  const inputStatesStyle = {
1112
966
  default: {
1113
- backgroundColor: colors.uiBackgroundLight,
1114
- borderColor: colors.separator,
1115
- color: colors.black
967
+ backgroundColor: lateOceanColorPalette.white,
968
+ borderColor: lateOceanColorPalette['eggshell.4'],
969
+ color: lateOceanColorPalette.black
1116
970
  },
1117
971
  pending: {
1118
- backgroundColor: colors.uiBackgroundLight,
1119
- borderColor: colors.separator,
1120
- color: colors.black
972
+ backgroundColor: lateOceanColorPalette.white,
973
+ borderColor: lateOceanColorPalette['eggshell.3'],
974
+ color: lateOceanColorPalette.black
1121
975
  },
1122
976
  valid: {
1123
- backgroundColor: colors.uiBackgroundLight,
1124
- borderColor: lateOceanColorPalette.black100,
1125
- color: colors.black
977
+ backgroundColor: lateOceanColorPalette.white,
978
+ borderColor: lateOceanColorPalette['eggshell.4'],
979
+ color: lateOceanColorPalette.black
1126
980
  },
1127
981
  hover: {
1128
- borderColor: lateOceanColorPalette.black200,
1129
- color: colors.black
982
+ backgroundColor: lateOceanColorPalette['eggshell.1'],
983
+ borderColor: lateOceanColorPalette['eggshell.5'],
984
+ color: lateOceanColorPalette.black
1130
985
  },
1131
986
  focus: {
1132
- borderColor: colors.primary,
1133
- color: colors.black
987
+ borderColor: lateOceanColorPalette['violine.9'],
988
+ color: lateOceanColorPalette.black
1134
989
  },
1135
990
  disabled: {
1136
- backgroundColor: colors.disabled,
1137
- borderColor: colors.separator,
1138
- color: colors.blackDisabled
991
+ backgroundColor: lateOceanColorPalette['eggshell.2'],
992
+ borderColor: lateOceanColorPalette['eggshell.4'],
993
+ color: lateOceanColorPalette['eggshell.6']
1139
994
  },
1140
995
  invalid: {
1141
- borderColor: colors.separator,
1142
- color: colors.black
996
+ borderColor: lateOceanColorPalette['eggshell.3'],
997
+ color: lateOceanColorPalette.black
1143
998
  }
1144
999
  };
1145
1000
  const webAnimationDuration = '200ms';
1146
1001
  const webAnimationTimingFunction = 'ease-in-out';
1147
- const webAnimationProperty = 'border-color';
1002
+ const webAnimationProperties = ['border-color', 'background-color'];
1148
1003
  const input = {
1149
1004
  minHeight: 40,
1150
1005
  color: {
1151
- selection: colors.primary,
1152
- placeholder: typography.colors['black-light']
1006
+ selection: lateOceanColorPalette['violine.9'],
1007
+ placeholder: lateOceanColorPalette['eggshell.9']
1153
1008
  },
1154
- borderWidth: 2,
1155
- borderRadius: 10,
1009
+ borderWidth: 1,
1010
+ borderRadius: 8,
1156
1011
  icon: {
1157
1012
  size: 20
1158
1013
  },
1159
1014
  rightContainer: {
1160
- padding: 10
1015
+ padding: 16
1161
1016
  },
1162
1017
  padding: {
1163
1018
  horizontal: 16,
1164
- vertical: 5
1019
+ vertical: 0
1165
1020
  },
1166
1021
  transition: {
1167
- property: webAnimationProperty,
1022
+ properties: webAnimationProperties,
1168
1023
  duration: webAnimationDuration,
1169
1024
  timingFunction: webAnimationTimingFunction
1170
1025
  },
@@ -1174,11 +1029,8 @@ const input = {
1174
1029
  const inputField = {
1175
1030
  containerPaddingTop: 5,
1176
1031
  containerPaddingBottom: 10,
1177
- feedbackPaddingTop: {
1178
- base: 5,
1179
- small: 10
1180
- },
1181
- labelContainerPaddingBottom: 5,
1032
+ feedbackPaddingTop: 4,
1033
+ labelContainerPaddingBottom: 4,
1182
1034
  labelFeedbackMarginLeft: 6
1183
1035
  };
1184
1036
 
@@ -1310,21 +1162,52 @@ const fullscreenModal = {
1310
1162
  };
1311
1163
 
1312
1164
  const highlight = {
1313
- borderRadius: spacing * 5,
1165
+ borderRadius: spacing * 2,
1314
1166
  /** @deprecated use primary instead */
1315
1167
  regular: {
1316
- backgroundColor: colors.accentLight
1168
+ default: {
1169
+ backgroundColor: colors.accentLight
1170
+ },
1171
+ hover: {
1172
+ backgroundColor: colors.accentLight
1173
+ }
1317
1174
  },
1318
1175
  primary: {
1319
- backgroundColor: colors.accentLight
1176
+ default: {
1177
+ backgroundColor: lateOceanColorPalette['lavender.3']
1178
+ },
1179
+ hover: {
1180
+ backgroundColor: lateOceanColorPalette['lavender.5']
1181
+ }
1320
1182
  },
1321
1183
  secondary: {
1322
- backgroundColor: lateOceanColorPalette.moonPurple
1184
+ default: {
1185
+ backgroundColor: lateOceanColorPalette['violine.2']
1186
+ },
1187
+ hover: {
1188
+ backgroundColor: lateOceanColorPalette['violine.4']
1189
+ }
1190
+ },
1191
+ ghost: {
1192
+ default: {
1193
+ backgroundColor: lateOceanColorPalette.white
1194
+ },
1195
+ hover: {
1196
+ backgroundColor: lateOceanColorPalette['eggshell.2']
1197
+ }
1323
1198
  },
1324
1199
  dark: {
1325
- backgroundColor: lateOceanColorPalette.black100
1200
+ default: {
1201
+ backgroundColor: lateOceanColorPalette['eggshell.3']
1202
+ },
1203
+ hover: {
1204
+ backgroundColor: lateOceanColorPalette['eggshell.2']
1205
+ }
1326
1206
  },
1327
- padding: spacing * 5
1207
+ padding: {
1208
+ medium: spacing * 4,
1209
+ large: spacing * 6
1210
+ }
1328
1211
  };
1329
1212
 
1330
1213
  const getIconSizeFromFontSize = fontSize => {
@@ -1447,6 +1330,152 @@ const pageLoader = {
1447
1330
  }
1448
1331
  };
1449
1332
 
1333
+ const calcLineHeight = (fontSize, lineHeightMultiplier) => Math.round(fontSize * lineHeightMultiplier);
1334
+ /** @deprecated legacy typography type config is deprecated. */
1335
+ const createLegacyTypographyTypeConfig = (lineHeightMultiplierBaseAndSmall, baseAndSmallFontSize, mediumAndWideFontSize = baseAndSmallFontSize, lineHeightMultiplierMediumAndWide = lineHeightMultiplierBaseAndSmall) => ({
1336
+ baseAndSmall: {
1337
+ fontSize: baseAndSmallFontSize,
1338
+ lineHeight: calcLineHeight(baseAndSmallFontSize, lineHeightMultiplierBaseAndSmall)
1339
+ },
1340
+ mediumAndWide: {
1341
+ fontSize: mediumAndWideFontSize,
1342
+ lineHeight: calcLineHeight(mediumAndWideFontSize, lineHeightMultiplierMediumAndWide)
1343
+ }
1344
+ });
1345
+ const createTypographyConfig = (fontSize, lineHeightMultiplier) => {
1346
+ const config = {
1347
+ fontSize,
1348
+ lineHeight: calcLineHeight(fontSize, lineHeightMultiplier)
1349
+ };
1350
+ return {
1351
+ baseAndSmall: config,
1352
+ mediumAndWide: config
1353
+ };
1354
+ };
1355
+ const typography = {
1356
+ colors: {
1357
+ black: colors.black,
1358
+ 'black-anthracite': colors.blackAnthracite,
1359
+ 'black-disabled': lateOceanColorPalette.black400,
1360
+ 'black-light': lateOceanColorPalette.black555,
1361
+ white: colors.white,
1362
+ 'white-light': colors.white,
1363
+ primary: colors.primary,
1364
+ 'primary-light': colors.primaryLight,
1365
+ accent: colors.accent,
1366
+ success: colors.success,
1367
+ danger: colors.danger,
1368
+ warning: colors.warning
1369
+ },
1370
+ types: {
1371
+ headings: {
1372
+ fontFamily: {
1373
+ native: {
1374
+ regular: 'Moderat-Bold',
1375
+ bold: 'Moderat-Bold'
1376
+ },
1377
+ web: {
1378
+ regular: 'Moderat',
1379
+ bold: 'Moderat'
1380
+ }
1381
+ },
1382
+ fontWeight: {
1383
+ regular: 400,
1384
+ bold: 700
1385
+ },
1386
+ fontStyle: 'normal',
1387
+ configs: {
1388
+ /* legacy */
1389
+ header1: createLegacyTypographyTypeConfig(1.1, 40, 56),
1390
+ header2: createLegacyTypographyTypeConfig(1.2, 32, 48, 1.1),
1391
+ header3: createLegacyTypographyTypeConfig(1.2, 24, 40, 1.1),
1392
+ header4: createLegacyTypographyTypeConfig(1.3, 18, 24, 1.2),
1393
+ header5: createLegacyTypographyTypeConfig(1.3, 18, 18),
1394
+ /* latest */
1395
+ 'heading-xxl': createTypographyConfig(56, 1.1),
1396
+ 'heading-xl': createTypographyConfig(48, 1.1),
1397
+ 'heading-l': createTypographyConfig(40, 1.1),
1398
+ 'heading-m': createTypographyConfig(32, 1.2),
1399
+ 'heading-s': createTypographyConfig(24, 1.2),
1400
+ 'heading-xs': createTypographyConfig(18, 1.3),
1401
+ 'heading-xxs': createTypographyConfig(16, 1.3)
1402
+ }
1403
+ },
1404
+ 'headings-impact': {
1405
+ fontFamily: {
1406
+ native: {
1407
+ regular: 'Transducer-Black',
1408
+ bold: 'Transducer-Black'
1409
+ },
1410
+ web: {
1411
+ regular: 'TransducerBlack',
1412
+ bold: 'TransducerBlack'
1413
+ }
1414
+ },
1415
+ fontWeight: 900,
1416
+ fontStyle: 'normal',
1417
+ configs: {
1418
+ /* legacy */
1419
+ 'header-impact-xxl': createLegacyTypographyTypeConfig(1.2, 56, 56),
1420
+ 'header-impact-xl': createLegacyTypographyTypeConfig(1.2, 48, 48),
1421
+ 'header-impact-l': createLegacyTypographyTypeConfig(1.2, 40, 40),
1422
+ 'header-impact-m': createLegacyTypographyTypeConfig(1.2, 32, 32),
1423
+ 'header-impact-s': createLegacyTypographyTypeConfig(1.2, 24, 24),
1424
+ 'header-impact-xs': createLegacyTypographyTypeConfig(1.2, 18, 18),
1425
+ 'header-impact-xxs': createLegacyTypographyTypeConfig(1.2, 16, 16),
1426
+ 'header-impact-xxxs': createLegacyTypographyTypeConfig(1.2, 14, 14),
1427
+ /* latest */
1428
+ 'heading-impact-xxl': createTypographyConfig(56, 1.2),
1429
+ 'heading-impact-xl': createTypographyConfig(48, 1.2),
1430
+ 'heading-impact-l': createTypographyConfig(40, 1.2),
1431
+ 'heading-impact-m': createTypographyConfig(32, 1.2),
1432
+ 'heading-impact-s': createTypographyConfig(24, 1.2),
1433
+ 'heading-impact-xs': createTypographyConfig(18, 1.2),
1434
+ 'heading-impact-xxs': createTypographyConfig(16, 1.2),
1435
+ 'heading-impact-xxxs': createTypographyConfig(14, 1.2)
1436
+ }
1437
+ },
1438
+ bodies: {
1439
+ fontFamily: {
1440
+ web: {
1441
+ regular: 'Moderat',
1442
+ bold: 'Moderat'
1443
+ },
1444
+ native: {
1445
+ regular: 'Moderat-Regular',
1446
+ bold: 'Moderat-Bold'
1447
+ }
1448
+ },
1449
+ fontWeight: {
1450
+ regular: 400,
1451
+ bold: 700
1452
+ },
1453
+ fontStyle: {
1454
+ regular: 'normal',
1455
+ bold: 'normal'
1456
+ },
1457
+ configs: {
1458
+ /* legacy */
1459
+ 'body-large': createLegacyTypographyTypeConfig(1.4, 18, 24),
1460
+ 'body-medium': createLegacyTypographyTypeConfig(1.4, 18, 18),
1461
+ body: createLegacyTypographyTypeConfig(1.4, 16, 16),
1462
+ 'body-small': createLegacyTypographyTypeConfig(1.4, 14, 14),
1463
+ 'body-xsmall': createLegacyTypographyTypeConfig(1.4, 12, 12),
1464
+ /* latest */
1465
+ 'body-xl': createTypographyConfig(24, 1.4),
1466
+ 'body-l': createTypographyConfig(18, 1.4),
1467
+ 'body-m': createTypographyConfig(16, 1.4),
1468
+ 'body-s': createTypographyConfig(14, 1.4),
1469
+ 'body-xs': createTypographyConfig(12, 1.4)
1470
+ }
1471
+ }
1472
+ },
1473
+ link: {
1474
+ /** @deprecated not used in kitt anymore, use Typography instead */
1475
+ disabledColor: colors.blackDisabled
1476
+ }
1477
+ };
1478
+
1450
1479
  const picker = {
1451
1480
  ios: {
1452
1481
  default: {
@@ -1981,7 +2010,7 @@ function getCurrentScale$1({
1981
2010
  return 1;
1982
2011
  }
1983
2012
 
1984
- function AnimatedContainer$1({
2013
+ function AnimatedContainer$2({
1985
2014
  children,
1986
2015
  type,
1987
2016
  variant,
@@ -2536,7 +2565,7 @@ function FocusBorder({
2536
2565
  });
2537
2566
  }
2538
2567
 
2539
- function useNativeAnimation$3() {
2568
+ function useNativeAnimation$4() {
2540
2569
  return {
2541
2570
  onPressIn: undefined,
2542
2571
  onPressOut: undefined,
@@ -2583,7 +2612,7 @@ const Button = /*#__PURE__*/forwardRef(({
2583
2612
  onPressIn,
2584
2613
  onPressOut,
2585
2614
  animatedStyles
2586
- } = useNativeAnimation$3();
2615
+ } = useNativeAnimation$4();
2587
2616
  if ((process.env.NODE_ENV !== "production") && variant === 'ghost' && !allowedGhostTypes.includes(type)) {
2588
2617
  throw new Error('variant=ghost is only allowed with type=primary or default');
2589
2618
  }
@@ -2619,7 +2648,7 @@ const Button = /*#__PURE__*/forwardRef(({
2619
2648
  isHovered,
2620
2649
  isPressed,
2621
2650
  isFocused
2622
- }) => /*#__PURE__*/jsx(AnimatedContainer$1, {
2651
+ }) => /*#__PURE__*/jsx(AnimatedContainer$2, {
2623
2652
  animatedStyles: animatedStyles,
2624
2653
  type: type,
2625
2654
  isHovered: isHovered || isHoveredInternal,
@@ -3298,7 +3327,7 @@ function AnimatedChoiceItemView({
3298
3327
  });
3299
3328
  }
3300
3329
 
3301
- const useNativeAnimation$2 = () => {
3330
+ const useNativeAnimation$3 = () => {
3302
3331
  return {
3303
3332
  onPressIn: () => {},
3304
3333
  onPressOut: () => {},
@@ -3337,7 +3366,7 @@ function ChoiceItem({
3337
3366
  onPressIn,
3338
3367
  onPressOut,
3339
3368
  backgroundStyles
3340
- } = useNativeAnimation$2();
3369
+ } = useNativeAnimation$3();
3341
3370
  const handleChange = () => {
3342
3371
  if (!onChange) return;
3343
3372
 
@@ -5506,7 +5535,7 @@ function getCurrentBorderColor({
5506
5535
  return 'default';
5507
5536
  }
5508
5537
 
5509
- function AnimatedContainer({
5538
+ function AnimatedContainer$1({
5510
5539
  children,
5511
5540
  isFocused,
5512
5541
  isPressed,
@@ -5580,7 +5609,7 @@ function HoverBorder({
5580
5609
  });
5581
5610
  }
5582
5611
 
5583
- function useNativeAnimation$1() {
5612
+ function useNativeAnimation$2() {
5584
5613
  return {
5585
5614
  onPressIn: undefined,
5586
5615
  onPressOut: undefined,
@@ -5622,7 +5651,7 @@ function RadioButton({
5622
5651
  onPressIn,
5623
5652
  onPressOut,
5624
5653
  animatedStyles
5625
- } = useNativeAnimation$1();
5654
+ } = useNativeAnimation$2();
5626
5655
  return /*#__PURE__*/jsx(Pressable, {
5627
5656
  accessibilityRole: "radiogroup",
5628
5657
  accessibilityState: {
@@ -5645,7 +5674,7 @@ function RadioButton({
5645
5674
  isHovered,
5646
5675
  isPressed,
5647
5676
  isFocused
5648
- }) => /*#__PURE__*/jsx(AnimatedContainer, {
5677
+ }) => /*#__PURE__*/jsx(AnimatedContainer$1, {
5649
5678
  animatedStyles: animatedStyles,
5650
5679
  isFocused: isFocused || isFocusedInternal,
5651
5680
  isPressed: isPressed || isPressedInternal,
@@ -6000,18 +6029,202 @@ FullscreenModal.Footer = FullscreenModalFooter;
6000
6029
  FullscreenModal.Body = FullscreenModalBody;
6001
6030
  FullscreenModal.ModalBehaviour = FullscreenModalBehaviour;
6002
6031
 
6003
- function Highlight({
6004
- variant = 'regular',
6005
- children
6032
+ function AnimatedCaret({
6033
+ children,
6034
+ isHovered,
6035
+ isExpanded
6036
+ }) {
6037
+ return /*#__PURE__*/jsx(View, {
6038
+ _web: {
6039
+ style: {
6040
+ transform: `rotate(${isExpanded ? '180deg' : '0deg'}) translateY(${isHovered ? '2px' : '0'})`,
6041
+ transitionDuration: '300ms',
6042
+ transitionProperty: 'transform',
6043
+ transitionTimingFunction: 'ease'
6044
+ }
6045
+ },
6046
+ children: children
6047
+ });
6048
+ }
6049
+
6050
+ function AnimatedContainer({
6051
+ children,
6052
+ size,
6053
+ isHovered,
6054
+ variant
6006
6055
  }) {
6056
+ const theme = useTheme();
6007
6057
  return /*#__PURE__*/jsx(View, {
6058
+ _web: {
6059
+ style: {
6060
+ transitionDuration: '300ms',
6061
+ transitionProperty: 'background-color',
6062
+ transitionTimingFunction: 'ease'
6063
+ }
6064
+ },
6008
6065
  borderRadius: "kitt.highlight.borderRadius",
6009
- padding: "kitt.highlight.padding",
6010
- backgroundColor: `kitt.highlight.${variant}.backgroundColor`,
6066
+ padding: theme.kitt.highlight.padding[size],
6067
+ backgroundColor: isHovered ? theme.kitt.highlight[variant].hover.backgroundColor : theme.kitt.highlight[variant].default.backgroundColor,
6068
+ children: children
6069
+ });
6070
+ }
6071
+
6072
+ function AnimatedContent({
6073
+ children,
6074
+ isExpanded,
6075
+ isInitialRender,
6076
+ contentHeight
6077
+ }) {
6078
+ return /*#__PURE__*/jsx(View, {
6079
+ _web: {
6080
+ style: {
6081
+ height: isExpanded ? `${contentHeight}px` : '0',
6082
+ transitionDuration: isInitialRender ? '0ms' : '300ms',
6083
+ transitionProperty: 'height',
6084
+ transitionTimingFunction: 'ease'
6085
+ }
6086
+ },
6087
+ overflow: "hidden",
6011
6088
  children: children
6012
6089
  });
6013
6090
  }
6014
6091
 
6092
+ function useNativeAnimation$1() {
6093
+ return {
6094
+ onPressIn: undefined,
6095
+ onPressOut: undefined,
6096
+ containerAnimatedStyles: {},
6097
+ caretAnimatedStyles: {},
6098
+ contentAnimatedStyles: {}
6099
+ };
6100
+ }
6101
+
6102
+ function Highlight({
6103
+ variant = 'primary',
6104
+ canCollapse = false,
6105
+ isInitialCollapsed = true,
6106
+ title,
6107
+ icon = null,
6108
+ size = 'medium',
6109
+ children
6110
+ }) {
6111
+ const theme = useTheme();
6112
+ const [isExpanded, setIsExpanded] = useState(!isInitialCollapsed);
6113
+ const [contentHeight, setContentHeight] = useState(0);
6114
+ const [isInitialRender, setIsInitialRender] = useState(true);
6115
+ const highlightStyle = {
6116
+ medium: {
6117
+ marginBottom: 'kitt.1',
6118
+ spaceBetween: 'kitt.2',
6119
+ contentMarginY: 8
6120
+ },
6121
+ large: {
6122
+ marginBottom: 'kitt.2',
6123
+ spaceBetween: 'kitt.4',
6124
+ contentMarginY: 16
6125
+ }
6126
+ };
6127
+ const {
6128
+ containerAnimatedStyles,
6129
+ caretAnimatedStyles,
6130
+ contentAnimatedStyles,
6131
+ onPressIn,
6132
+ onPressOut
6133
+ } = useNativeAnimation$1();
6134
+ const handleLayout = event => {
6135
+ const layoutHeight = event.nativeEvent.layout.height;
6136
+ const newContentHeight = layoutHeight + highlightStyle[size].contentMarginY;
6137
+ if (layoutHeight > 0 && newContentHeight !== contentHeight) {
6138
+ setContentHeight(newContentHeight);
6139
+ }
6140
+ };
6141
+ if (!canCollapse) {
6142
+ return /*#__PURE__*/jsx(View, {
6143
+ borderRadius: "kitt.highlight.borderRadius",
6144
+ padding: theme.kitt.highlight.padding[size],
6145
+ backgroundColor: `kitt.highlight.${variant}.default.backgroundColor`,
6146
+ children: /*#__PURE__*/jsxs(HStack, {
6147
+ space: highlightStyle[size].spaceBetween,
6148
+ children: [icon && /*#__PURE__*/jsx(View, {
6149
+ children: icon
6150
+ }), /*#__PURE__*/jsxs(View, {
6151
+ flexGrow: 1,
6152
+ flexShrink: 1,
6153
+ children: [title && /*#__PURE__*/jsx(View, {
6154
+ marginBottom: highlightStyle[size].marginBottom,
6155
+ children: /*#__PURE__*/jsx(Typography.Text, {
6156
+ variant: "bold",
6157
+ base: "body",
6158
+ ellipsizeMode: "clip",
6159
+ children: title
6160
+ })
6161
+ }), children]
6162
+ })]
6163
+ })
6164
+ });
6165
+ }
6166
+ return /*#__PURE__*/jsx(Pressable, {
6167
+ onPress: () => {
6168
+ setIsExpanded(!isExpanded);
6169
+ setIsInitialRender(false);
6170
+ },
6171
+ onPressIn: onPressIn,
6172
+ onPressOut: onPressOut,
6173
+ children: ({
6174
+ isHovered
6175
+ }) => {
6176
+ return /*#__PURE__*/jsxs(AnimatedContainer, {
6177
+ isHovered: isHovered,
6178
+ size: size,
6179
+ variant: variant,
6180
+ animatedStyles: containerAnimatedStyles,
6181
+ children: [title && /*#__PURE__*/jsxs(HStack, {
6182
+ space: highlightStyle[size].spaceBetween,
6183
+ alignItems: "center",
6184
+ children: [icon && /*#__PURE__*/jsx(View, {
6185
+ flexGrow: 1,
6186
+ children: icon
6187
+ }), /*#__PURE__*/jsx(View, {
6188
+ flexGrow: 1,
6189
+ flexShrink: 1,
6190
+ width: "100%",
6191
+ children: /*#__PURE__*/jsx(Typography.Text, {
6192
+ variant: "bold",
6193
+ base: "body",
6194
+ ellipsizeMode: "clip",
6195
+ children: title
6196
+ })
6197
+ }), /*#__PURE__*/jsx(View, {
6198
+ flexGrow: 2,
6199
+ flexShrink: 2,
6200
+ alignItems: "center",
6201
+ justifyContent: "center",
6202
+ children: /*#__PURE__*/jsx(AnimatedCaret, {
6203
+ isHovered: isHovered,
6204
+ isExpanded: isExpanded,
6205
+ animatedStyles: caretAnimatedStyles,
6206
+ children: /*#__PURE__*/jsx(TypographyIcon, {
6207
+ icon: /*#__PURE__*/jsx(CaretDownRegularIcon, {})
6208
+ })
6209
+ })
6210
+ })]
6211
+ }), /*#__PURE__*/jsx(AnimatedContent, {
6212
+ isExpanded: isExpanded,
6213
+ isInitialRender: isInitialRender,
6214
+ contentHeight: contentHeight,
6215
+ animatedStyles: contentAnimatedStyles,
6216
+ children: /*#__PURE__*/jsx(View, {
6217
+ marginTop: highlightStyle[size].contentMarginY,
6218
+ position: "absolute",
6219
+ onLayout: handleLayout,
6220
+ children: children
6221
+ })
6222
+ })]
6223
+ });
6224
+ }
6225
+ });
6226
+ }
6227
+
6015
6228
  function getBackgroundColor$1(color, isDisabled) {
6016
6229
  if (isDisabled) {
6017
6230
  return 'kitt.iconButton.disabled.backgroundColor';
@@ -7032,16 +7245,44 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
7032
7245
  },
7033
7246
  highlight: {
7034
7247
  regular: {
7035
- backgroundColor: theme.highlight.regular.backgroundColor
7248
+ default: {
7249
+ backgroundColor: theme.highlight.regular.default.backgroundColor
7250
+ },
7251
+ hover: {
7252
+ backgroundColor: theme.highlight.regular.hover.backgroundColor
7253
+ }
7036
7254
  },
7037
7255
  primary: {
7038
- backgroundColor: theme.highlight.primary.backgroundColor
7256
+ default: {
7257
+ backgroundColor: theme.highlight.primary.default.backgroundColor
7258
+ },
7259
+ hover: {
7260
+ backgroundColor: theme.highlight.primary.hover.backgroundColor
7261
+ }
7039
7262
  },
7040
7263
  secondary: {
7041
- backgroundColor: theme.highlight.secondary.backgroundColor
7264
+ default: {
7265
+ backgroundColor: theme.highlight.secondary.default.backgroundColor
7266
+ },
7267
+ hover: {
7268
+ backgroundColor: theme.highlight.secondary.hover.backgroundColor
7269
+ }
7042
7270
  },
7043
7271
  dark: {
7044
- backgroundColor: theme.highlight.dark.backgroundColor
7272
+ default: {
7273
+ backgroundColor: theme.highlight.dark.default.backgroundColor
7274
+ },
7275
+ hover: {
7276
+ backgroundColor: theme.highlight.dark.hover.backgroundColor
7277
+ }
7278
+ },
7279
+ ghost: {
7280
+ default: {
7281
+ backgroundColor: theme.highlight.ghost.default.backgroundColor
7282
+ },
7283
+ hover: {
7284
+ backgroundColor: theme.highlight.ghost.hover.backgroundColor
7285
+ }
7045
7286
  }
7046
7287
  },
7047
7288
  verticalSteps: {
@@ -7554,7 +7795,12 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
7554
7795
  }
7555
7796
  },
7556
7797
  highlight: {
7557
- padding: theme.highlight.padding
7798
+ medium: {
7799
+ padding: theme.highlight.padding.medium
7800
+ },
7801
+ large: {
7802
+ padding: theme.highlight.padding.large
7803
+ }
7558
7804
  },
7559
7805
  listItem: {
7560
7806
  verticalPadding: theme.listItem.verticalPadding,
@@ -8187,9 +8433,11 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
8187
8433
  borderColor: theme.forms.input.states.default.borderColor,
8188
8434
  bg: theme.forms.input.states.default.backgroundColor,
8189
8435
  _hover: {
8436
+ bg: theme.forms.input.states.hover.backgroundColor,
8190
8437
  borderColor: theme.forms.input.states.hover.borderColor,
8191
8438
  color: theme.forms.input.states.hover.color,
8192
8439
  _focus: {
8440
+ bg: theme.forms.input.states.default.backgroundColor,
8193
8441
  borderColor: theme.forms.input.states.focus.borderColor,
8194
8442
  color: theme.forms.input.states.focus.color
8195
8443
  }