@ornikar/kitt-universal 7.1.0 → 7.3.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 (59) hide show
  1. package/dist/definitions/Button/BaseStyledButtonPressable.d.ts +1 -0
  2. package/dist/definitions/Button/BaseStyledButtonPressable.d.ts.map +1 -1
  3. package/dist/definitions/Button/Button.d.ts +1 -0
  4. package/dist/definitions/Button/Button.d.ts.map +1 -1
  5. package/dist/definitions/Button/ButtonContent.d.ts.map +1 -1
  6. package/dist/definitions/Overlay/Overlay.d.ts +1 -2
  7. package/dist/definitions/Overlay/Overlay.d.ts.map +1 -1
  8. package/dist/definitions/PageLoader/AnimatedBackgroundCircle.d.ts +3 -0
  9. package/dist/definitions/PageLoader/AnimatedBackgroundCircle.d.ts.map +1 -0
  10. package/dist/definitions/PageLoader/AnimatedFillCircle.d.ts +3 -0
  11. package/dist/definitions/PageLoader/AnimatedFillCircle.d.ts.map +1 -0
  12. package/dist/definitions/PageLoader/AnimatedFillCircleContainer.d.ts +8 -0
  13. package/dist/definitions/PageLoader/AnimatedFillCircleContainer.d.ts.map +1 -0
  14. package/dist/definitions/PageLoader/AnimatedLoaderCircle.d.ts +10 -0
  15. package/dist/definitions/PageLoader/AnimatedLoaderCircle.d.ts.map +1 -0
  16. package/dist/definitions/PageLoader/PageLoader.d.ts.map +1 -1
  17. package/dist/definitions/PageLoader/PageLoader.web.d.ts.map +1 -1
  18. package/dist/definitions/forms/DatePicker/DatePickerInputPart.d.ts.map +1 -1
  19. package/dist/definitions/forms/InputText/InputText.d.ts.map +1 -1
  20. package/dist/definitions/themes/default.d.ts +2 -0
  21. package/dist/definitions/themes/default.d.ts.map +1 -1
  22. package/dist/definitions/themes/late-ocean/button.d.ts +2 -1
  23. package/dist/definitions/themes/late-ocean/button.d.ts.map +1 -1
  24. package/dist/definitions/themes/late-ocean/colors.d.ts +2 -0
  25. package/dist/definitions/themes/late-ocean/colors.d.ts.map +1 -1
  26. package/dist/definitions/themes/late-ocean/input.d.ts +2 -2
  27. package/dist/definitions/themes/late-ocean/input.d.ts.map +1 -1
  28. package/dist/definitions/themes/late-ocean/pageLoader.d.ts +13 -0
  29. package/dist/definitions/themes/late-ocean/pageLoader.d.ts.map +1 -1
  30. package/dist/definitions/themes/late-ocean/typography.d.ts.map +1 -1
  31. package/dist/definitions/typography/Typography.d.ts.map +1 -1
  32. package/dist/index-browser-all.es.android.js +232 -40
  33. package/dist/index-browser-all.es.android.js.map +1 -1
  34. package/dist/index-browser-all.es.ios.js +232 -40
  35. package/dist/index-browser-all.es.ios.js.map +1 -1
  36. package/dist/index-browser-all.es.js +232 -40
  37. package/dist/index-browser-all.es.js.map +1 -1
  38. package/dist/index-browser-all.es.web.js +127 -46
  39. package/dist/index-browser-all.es.web.js.map +1 -1
  40. package/dist/index-node-14.17.cjs.js +228 -37
  41. package/dist/index-node-14.17.cjs.js.map +1 -1
  42. package/dist/index-node-14.17.cjs.web.css +1 -1
  43. package/dist/index-node-14.17.cjs.web.js +117 -42
  44. package/dist/index-node-14.17.cjs.web.js.map +1 -1
  45. package/dist/linaria-themes-browser-all.es.android.js +37 -12
  46. package/dist/linaria-themes-browser-all.es.android.js.map +1 -1
  47. package/dist/linaria-themes-browser-all.es.ios.js +37 -12
  48. package/dist/linaria-themes-browser-all.es.ios.js.map +1 -1
  49. package/dist/linaria-themes-browser-all.es.js +37 -12
  50. package/dist/linaria-themes-browser-all.es.js.map +1 -1
  51. package/dist/linaria-themes-browser-all.es.web.js +37 -12
  52. package/dist/linaria-themes-browser-all.es.web.js.map +1 -1
  53. package/dist/linaria-themes-node-14.17.cjs.js +37 -12
  54. package/dist/linaria-themes-node-14.17.cjs.js.map +1 -1
  55. package/dist/linaria-themes-node-14.17.cjs.web.js +37 -12
  56. package/dist/linaria-themes-node-14.17.cjs.web.js.map +1 -1
  57. package/dist/styles.css +1 -1
  58. package/dist/tsbuildinfo +1 -1
  59. package/package.json +9 -4
@@ -2,12 +2,12 @@ import _objectSpread from '@babel/runtime/helpers/objectSpread2';
2
2
  import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';
3
3
  import { UserIcon, CheckboxMark, XIcon, EyeOffIcon, EyeIcon, ArcIcon, InfoIcon, AlertTriangleIcon, CheckIcon, AlertCircleIcon, TooltipArrowIcon } from '@ornikar/kitt-icons';
4
4
  export * from '@ornikar/kitt-icons';
5
- import { useWindowDimensions, Platform, Image, Linking, Pressable, StyleSheet, ScrollView, Modal as Modal$1, Text as Text$1, TextInput, View, Animated as Animated$1, Easing, ActivityIndicator } from 'react-native';
5
+ import { useWindowDimensions, Platform, Image, Linking, Pressable, StyleSheet, ScrollView, Modal as Modal$1, Text as Text$1, TextInput, View, Animated as Animated$1, Easing } from 'react-native';
6
6
  export { useWindowDimensions as useWindowSize } from 'react-native';
7
- import styled, { useTheme, css, ThemeProvider } from 'styled-components/native';
7
+ import styled, { css, useTheme, ThemeProvider } from 'styled-components/native';
8
8
  import { cloneElement, useContext, createContext, forwardRef, useMemo, useState, useRef, useEffect, Fragment as Fragment$1, Children } from 'react';
9
9
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
10
- import Animated, { useSharedValue, useAnimatedStyle, interpolateColor, withSpring, withRepeat, withTiming, Easing as Easing$1, interpolate } from 'react-native-reanimated';
10
+ import Animated, { useSharedValue, useAnimatedStyle, interpolateColor, withSpring, useAnimatedProps, withDelay, withTiming, Easing as Easing$1, withRepeat, interpolate } from 'react-native-reanimated';
11
11
  import _slicedToArray from '@babel/runtime/helpers/slicedToArray';
12
12
  import { parse } from 'twemoji-parser';
13
13
  import { openBrowserAsync } from 'expo-web-browser';
@@ -16,6 +16,7 @@ import { FormattedMessage } from 'react-intl';
16
16
  import { styled as styled$1 } from '@linaria/react';
17
17
  import _extends from '@babel/runtime/helpers/extends';
18
18
  import { useSafeAreaInsets } from 'react-native-safe-area-context';
19
+ import Svg, { Circle as Circle$1 } from 'react-native-svg';
19
20
  import { LinearGradient } from 'expo-linear-gradient';
20
21
  import { useFloating, offset, shift, flip } from '@floating-ui/react-native';
21
22
  import { makeDecorator } from '@storybook/addons';
@@ -146,7 +147,8 @@ var StyledTypography = /*#__PURE__*/styled.Text.withConfig({
146
147
  }, function (_ref2) {
147
148
  var theme = _ref2.theme,
148
149
  $color = _ref2.$color;
149
- return !$color ? '' : "\n color: ".concat(theme.kitt.typography.colors[$color], ";\n text-decoration-color: ").concat(theme.kitt.typography.colors[$color], ";\n ");
150
+ if (!$color) return '';
151
+ return css(["color:", ";text-decoration-color:", ";"], theme.kitt.typography.colors[$color], theme.kitt.typography.colors[$color]);
150
152
  });
151
153
  function useTypographyTypeForCurrentWindowSize(base, small, medium, large) {
152
154
  var _useWindowDimensions = useWindowDimensions(),
@@ -494,11 +496,14 @@ var BaseStyledButtonPressable = /*#__PURE__*/styled.View.withConfig({
494
496
  }, function (_ref7) {
495
497
  var theme = _ref7.theme,
496
498
  $isLarge = _ref7.$isLarge,
499
+ $isXLarge = _ref7.$isXLarge,
497
500
  $isDisabled = _ref7.$isDisabled;
498
501
  var _theme$kitt$button$co = theme.kitt.button.contentPadding,
499
502
  large = _theme$kitt$button$co.large,
500
503
  defaultPadding = _theme$kitt$button$co["default"],
501
- disabledPadding = _theme$kitt$button$co.disabled;
504
+ disabledPadding = _theme$kitt$button$co.disabled,
505
+ xLarge = _theme$kitt$button$co.xLarge;
506
+ if ($isXLarge) return xLarge;
502
507
  if ($isLarge) return large;
503
508
  if ($isDisabled) return disabledPadding;
504
509
  return defaultPadding;
@@ -557,6 +562,9 @@ var getTextColorByType = function (type, variant) {
557
562
  case 'subtle-dark':
558
563
  return 'black';
559
564
 
565
+ case 'default':
566
+ return variant === 'ghost' ? 'white' : 'black';
567
+
560
568
  default:
561
569
  return 'black';
562
570
  }
@@ -711,6 +719,7 @@ var StyledDisabled = /*#__PURE__*/styled.View.withConfig({
711
719
  return theme.kitt.button.borderRadius;
712
720
  });
713
721
 
722
+ var allowedGhostTypes = ['primary', 'default'];
714
723
  var Button = /*#__PURE__*/forwardRef(function (_ref, ref) {
715
724
  var children = _ref.children,
716
725
  _ref$type = _ref.type,
@@ -720,6 +729,7 @@ var Button = /*#__PURE__*/forwardRef(function (_ref, ref) {
720
729
  disabled = _ref.disabled,
721
730
  stretch = _ref.stretch,
722
731
  large = _ref.large,
732
+ xLarge = _ref.xLarge,
723
733
  icon = _ref.icon,
724
734
  _ref$iconPosition = _ref.iconPosition,
725
735
  iconPosition = _ref$iconPosition === void 0 ? 'left' : _ref$iconPosition,
@@ -730,8 +740,8 @@ var Button = /*#__PURE__*/forwardRef(function (_ref, ref) {
730
740
  accessibilityRole = _ref$accessibilityRol === void 0 ? 'button' : _ref$accessibilityRol,
731
741
  onPress = _ref.onPress;
732
742
 
733
- if ((process.env.NODE_ENV !== "production") && variant === 'ghost' && type !== 'primary') {
734
- throw new Error('variant=ghost is only allowed with type=primary');
743
+ if ((process.env.NODE_ENV !== "production") && variant === 'ghost' && !allowedGhostTypes.includes(type)) {
744
+ throw new Error('variant=ghost is only allowed with type=primary or default');
735
745
  }
736
746
 
737
747
  return /*#__PURE__*/jsx(AnimatedButtonPressable, {
@@ -750,6 +760,7 @@ var Button = /*#__PURE__*/forwardRef(function (_ref, ref) {
750
760
  $variant: variant,
751
761
  $isStretch: stretch,
752
762
  $isLarge: large,
763
+ $isXLarge: xLarge,
753
764
  $isDisabled: disabled,
754
765
  children: [/*#__PURE__*/jsx(ButtonContent, {
755
766
  type: type,
@@ -910,7 +921,9 @@ var colors = {
910
921
  warning: lateOceanColorPalette.goldCrayola,
911
922
  separator: lateOceanColorPalette.black100,
912
923
  hover: lateOceanColorPalette.black100,
924
+ white: lateOceanColorPalette.white,
913
925
  black: lateOceanColorPalette.black1000,
926
+ blackAnthracite: lateOceanColorPalette.black800,
914
927
  uiBackground: lateOceanColorPalette.black25,
915
928
  uiBackgroundLight: lateOceanColorPalette.white,
916
929
  transparent: lateOceanColorPalette.transparent,
@@ -957,6 +970,7 @@ var button = {
957
970
  contentPadding: {
958
971
  "default": '7px 16px 7px',
959
972
  large: '11px 24px 11px',
973
+ xLarge: '15px 24px 15px',
960
974
  disabled: '5px 14px 5px'
961
975
  },
962
976
  transition: {
@@ -969,6 +983,15 @@ var button = {
969
983
  pressedBackgroundColor: 'rgba(0, 0, 0, 0.1)',
970
984
  hoverBackgroundColor: 'rgba(0, 0, 0, 0.1)',
971
985
  focusBorderColor: 'rgba(0, 0, 0, 0.1)'
986
+ },
987
+ ghost: {
988
+ backgroundColor: 'rgba(255, 255, 255, 0.1)',
989
+ pressedBackgroundColor: 'rgba(255, 255, 255, 0.05)',
990
+ hoverBackgroundColor: 'rgba(255, 255, 255, 0.05)',
991
+ focusBorderColor: 'rgba(255, 255, 255, 0.4)',
992
+ color: lateOceanColorPalette.white,
993
+ hoverColor: lateOceanColorPalette.white,
994
+ activeColor: lateOceanColorPalette.white
972
995
  }
973
996
  },
974
997
  primary: {
@@ -1103,16 +1126,16 @@ var createTypographyTypeConfig = function (lineHeightMultiplier, baseAndSmallFon
1103
1126
  };
1104
1127
  var typography = {
1105
1128
  colors: {
1106
- black: lateOceanColorPalette.black1000,
1107
- 'black-anthracite': lateOceanColorPalette.black800,
1129
+ black: colors.black,
1130
+ 'black-anthracite': colors.blackAnthracite,
1108
1131
  'black-light': lateOceanColorPalette.black555,
1109
- white: lateOceanColorPalette.white,
1110
- 'white-light': lateOceanColorPalette.white,
1111
- primary: lateOceanColorPalette.lateOcean,
1112
- 'primary-light': lateOceanColorPalette.lateOceanLight1,
1113
- accent: lateOceanColorPalette.warmEmbrace,
1114
- success: lateOceanColorPalette.viride,
1115
- danger: lateOceanColorPalette.englishVermillon
1132
+ white: colors.white,
1133
+ 'white-light': colors.white,
1134
+ primary: colors.primary,
1135
+ 'primary-light': colors.primaryLight,
1136
+ accent: colors.accent,
1137
+ success: colors.success,
1138
+ danger: colors.danger
1116
1139
  },
1117
1140
  types: {
1118
1141
  headers: {
@@ -1208,8 +1231,8 @@ var input = {
1208
1231
  size: 20
1209
1232
  },
1210
1233
  padding: {
1211
- "default": '5px 16px',
1212
- iOSSingleLine: '7px 16px'
1234
+ horizontal: 16,
1235
+ vertical: 5
1213
1236
  },
1214
1237
  transition: {
1215
1238
  property: 'border-color',
@@ -1324,7 +1347,20 @@ var listItem = {
1324
1347
  };
1325
1348
 
1326
1349
  var pageLoader = {
1327
- size: 60
1350
+ size: 60,
1351
+ strokeWidth: 3,
1352
+ colors: {
1353
+ base: colors.separator,
1354
+ fill: colors.primary
1355
+ },
1356
+ animation: {
1357
+ delay: 500,
1358
+ circleBackgroundFillDuration: 1000,
1359
+ filledCircleFillDuration: 1800,
1360
+ groupFilledCircleRotationDuration: 1800,
1361
+ filledCircleRotationDuration: 2160,
1362
+ fillEasingFunction: [0.39, 0.575, 0.565, 1]
1363
+ }
1328
1364
  };
1329
1365
 
1330
1366
  var shadows = {
@@ -1620,7 +1656,7 @@ var ViewInput = /*#__PURE__*/styled.View.withConfig({
1620
1656
  displayName: "DatePickerInputPart__ViewInput"
1621
1657
  })(["", " padding:", ";min-height:", "px;min-width:", ";"], styledTextInputMixin, function (_ref) {
1622
1658
  var theme = _ref.theme;
1623
- return theme.kitt.forms.input.padding["default"];
1659
+ return "".concat(theme.kitt.forms.input.padding.vertical, "px ").concat(theme.kitt.forms.input.padding.horizontal, "px");
1624
1660
  }, function (_ref2) {
1625
1661
  var theme = _ref2.theme;
1626
1662
  return theme.kitt.forms.input.minHeight;
@@ -2386,20 +2422,18 @@ var StyledTextInput = /*#__PURE__*/styled(TextInput).withConfig({
2386
2422
  })(["", " padding:", ";line-height:", ";width:100%;min-height:", "px;"], styledTextInputMixin, function (_ref) {
2387
2423
  var theme = _ref.theme,
2388
2424
  multiline = _ref.multiline;
2389
-
2390
- if (!multiline && Platform.OS === 'ios') {
2391
- return theme.kitt.forms.input.padding.iOSSingleLine;
2392
- }
2393
-
2394
- return theme.kitt.forms.input.padding["default"];
2425
+ if (!multiline && Platform.OS !== 'web') return "0 ".concat(theme.kitt.forms.input.padding.horizontal, "px");
2426
+ return "".concat(theme.kitt.forms.input.padding.vertical, "px ").concat(theme.kitt.forms.input.padding.horizontal, "px");
2395
2427
  }, function (_ref2) {
2396
2428
  var theme = _ref2.theme,
2397
2429
  multiline = _ref2.multiline;
2398
- if (!multiline && Platform.OS === 'ios') return 0;
2430
+ if (!multiline && Platform.OS !== 'web') return 0;
2399
2431
  var typeConfigKey = getTypographyTypeConfigKey(theme);
2400
2432
  return "".concat(theme.kitt.typography.types.bodies.configs.body[typeConfigKey].lineHeight, "px");
2401
2433
  }, function (_ref3) {
2402
- var $minHeight = _ref3.$minHeight;
2434
+ var theme = _ref3.theme,
2435
+ _ref3$$minHeight = _ref3.$minHeight,
2436
+ $minHeight = _ref3$$minHeight === void 0 ? theme.kitt.forms.input.minHeight : _ref3$$minHeight;
2403
2437
  return $minHeight;
2404
2438
  });
2405
2439
  var RightInputContainer = /*#__PURE__*/styled.View.withConfig({
@@ -2408,8 +2442,7 @@ var RightInputContainer = /*#__PURE__*/styled.View.withConfig({
2408
2442
  var InputText = /*#__PURE__*/forwardRef(function (_ref4, ref) {
2409
2443
  var id = _ref4.id,
2410
2444
  right = _ref4.right,
2411
- _ref4$minHeight = _ref4.minHeight,
2412
- minHeight = _ref4$minHeight === void 0 ? 0 : _ref4$minHeight,
2445
+ minHeight = _ref4.minHeight,
2413
2446
  formState = _ref4.state,
2414
2447
  internalForceState = _ref4.internalForceState,
2415
2448
  _ref4$disabled = _ref4.disabled,
@@ -3292,19 +3325,178 @@ function Notification(_ref) {
3292
3325
  });
3293
3326
  }
3294
3327
 
3295
- function getActivityIndicatorSize(size) {
3296
- if (Platform.OS === 'android') return size;
3297
- return size < 36 ? 'small' : 'large';
3328
+ var AnimatedCircle = Animated.createAnimatedComponent(Circle$1);
3329
+ function AnimatedLoaderCircle(_ref) {
3330
+ var color = _ref.color,
3331
+ progress = _ref.progress;
3332
+ var theme = /*#__PURE__*/useTheme();
3333
+ var _theme$kitt$pageLoade = theme.kitt.pageLoader,
3334
+ strokeWidth = _theme$kitt$pageLoade.strokeWidth,
3335
+ size = _theme$kitt$pageLoade.size;
3336
+ var centerCoord = size * 0.5;
3337
+ var circlePerimeter = 2 * Math.PI * (size * 0.5 - strokeWidth);
3338
+ var strokeAnimation = useAnimatedProps(function () {
3339
+ var _f = function () {
3340
+ return {
3341
+ strokeDashoffset: circlePerimeter - circlePerimeter * progress.value
3342
+ };
3343
+ };
3344
+
3345
+ _f._closure = {
3346
+ circlePerimeter: circlePerimeter,
3347
+ progress: progress
3348
+ };
3349
+ _f.asString = "function _f(){const{circlePerimeter,progress}=jsThis._closure;{return{strokeDashoffset:circlePerimeter-circlePerimeter*progress.value};}}";
3350
+ _f.__workletHash = 1345639818356;
3351
+ _f.__location = "/home/circleci/repo/@ornikar/kitt-universal/src/PageLoader/AnimatedLoaderCircle.tsx (23:43)";
3352
+
3353
+ global.__reanimatedWorkletInit(_f);
3354
+
3355
+ return _f;
3356
+ }());
3357
+ return /*#__PURE__*/jsx(AnimatedCircle, {
3358
+ "transform-origin": "center center",
3359
+ strokeWidth: strokeWidth,
3360
+ stroke: color,
3361
+ strokeLinecap: "round",
3362
+ cx: centerCoord,
3363
+ cy: centerCoord,
3364
+ r: centerCoord - strokeWidth,
3365
+ fill: "none",
3366
+ strokeDasharray: circlePerimeter,
3367
+ animatedProps: strokeAnimation
3368
+ });
3298
3369
  }
3299
3370
 
3300
- function PageLoader() {
3371
+ function AnimatedBackgroundCircle() {
3372
+ var theme = /*#__PURE__*/useTheme();
3373
+ var progress = useSharedValue(0);
3374
+ var _theme$kitt$pageLoade = theme.kitt.pageLoader,
3375
+ animation = _theme$kitt$pageLoade.animation,
3376
+ colors = _theme$kitt$pageLoade.colors,
3377
+ size = _theme$kitt$pageLoade.size;
3378
+ useEffect(function () {
3379
+ var delay = animation.delay,
3380
+ circleBackgroundFillDuration = animation.circleBackgroundFillDuration,
3381
+ fillEasingFunction = animation.fillEasingFunction;
3382
+
3383
+ var _fillEasingFunction = _slicedToArray(fillEasingFunction, 4),
3384
+ x1 = _fillEasingFunction[0],
3385
+ y1 = _fillEasingFunction[1],
3386
+ x2 = _fillEasingFunction[2],
3387
+ y2 = _fillEasingFunction[3];
3388
+
3389
+ progress.value = withDelay(delay, withTiming(1, {
3390
+ duration: circleBackgroundFillDuration,
3391
+ easing: Easing$1.bezier(x1, y1, x2, y2)
3392
+ }));
3393
+ }, [progress, animation]);
3394
+ return /*#__PURE__*/jsx(Svg, {
3395
+ width: size,
3396
+ height: size,
3397
+ viewBox: "0 0 ".concat(size, " ").concat(size),
3398
+ children: /*#__PURE__*/jsx(AnimatedLoaderCircle, {
3399
+ color: colors.base,
3400
+ progress: progress
3401
+ })
3402
+ });
3403
+ }
3404
+
3405
+ var isInfinitAnimation$1 = -1;
3406
+ function AnimatedFillCircleContainer(_ref) {
3407
+ var children = _ref.children,
3408
+ duration = _ref.duration;
3301
3409
  var theme = /*#__PURE__*/useTheme();
3302
- var size = theme.kitt.pageLoader.size;
3303
- var colorHex = theme.kitt.typography.colors.primary;
3304
- return /*#__PURE__*/jsx(ActivityIndicator, {
3305
- testID: "ActivityIndicator",
3306
- color: colorHex,
3307
- size: getActivityIndicatorSize(size)
3410
+ var progress = useSharedValue(0);
3411
+ var animation = theme.kitt.pageLoader.animation;
3412
+ useEffect(function () {
3413
+ var delay = animation.delay;
3414
+ progress.value = withDelay(delay, withRepeat(withTiming(1, {
3415
+ duration: duration,
3416
+ easing: Easing$1.linear
3417
+ }), isInfinitAnimation$1));
3418
+ }, [progress, animation, duration]);
3419
+ var rotationStyles = useAnimatedStyle(function () {
3420
+ var _f = function () {
3421
+ return {
3422
+ transform: [{
3423
+ rotate: "".concat(360 * progress.value, "deg")
3424
+ }]
3425
+ };
3426
+ };
3427
+
3428
+ _f._closure = {
3429
+ progress: progress
3430
+ };
3431
+ _f.asString = "function _f(){const{progress}=jsThis._closure;{return{transform:[{rotate:360*progress.value+\"deg\"}]};}}";
3432
+ _f.__workletHash = 16553090406738;
3433
+ _f.__location = "/home/circleci/repo/@ornikar/kitt-universal/src/PageLoader/AnimatedFillCircleContainer.tsx (36:42)";
3434
+ _f.__optimalization = 3;
3435
+
3436
+ global.__reanimatedWorkletInit(_f);
3437
+
3438
+ return _f;
3439
+ }());
3440
+ return /*#__PURE__*/jsx(Animated.View, {
3441
+ style: [StyleSheet.absoluteFill, rotationStyles],
3442
+ children: children
3443
+ });
3444
+ }
3445
+
3446
+ var isInfinitAnimation = -1;
3447
+ var shouldReverse = true;
3448
+ function AnimatedFilledCircle() {
3449
+ var theme = /*#__PURE__*/useTheme();
3450
+ var progress = useSharedValue(0);
3451
+ var _theme$kitt$pageLoade = theme.kitt.pageLoader,
3452
+ size = _theme$kitt$pageLoade.size,
3453
+ animation = _theme$kitt$pageLoade.animation,
3454
+ colors = _theme$kitt$pageLoade.colors;
3455
+ useEffect(function () {
3456
+ var delay = animation.delay,
3457
+ filledCircleFillDuration = animation.filledCircleFillDuration,
3458
+ fillEasingFunction = animation.fillEasingFunction;
3459
+
3460
+ var _fillEasingFunction = _slicedToArray(fillEasingFunction, 4),
3461
+ x1 = _fillEasingFunction[0],
3462
+ y1 = _fillEasingFunction[1],
3463
+ x2 = _fillEasingFunction[2],
3464
+ y2 = _fillEasingFunction[3];
3465
+
3466
+ progress.value = withDelay(delay, withRepeat(withTiming(0.8, {
3467
+ duration: filledCircleFillDuration,
3468
+ easing: Easing$1.bezier(x1, y1, x2, y2)
3469
+ }), isInfinitAnimation, shouldReverse));
3470
+ }, [progress, animation]);
3471
+ return /*#__PURE__*/jsx(AnimatedFillCircleContainer, {
3472
+ duration: animation.groupFilledCircleRotationDuration,
3473
+ children: /*#__PURE__*/jsx(AnimatedFillCircleContainer, {
3474
+ duration: animation.filledCircleRotationDuration,
3475
+ children: /*#__PURE__*/jsx(Svg, {
3476
+ width: size,
3477
+ height: size,
3478
+ viewBox: "0 0 ".concat(size, " ").concat(size),
3479
+ children: /*#__PURE__*/jsx(AnimatedLoaderCircle, {
3480
+ color: colors.fill,
3481
+ progress: progress
3482
+ })
3483
+ })
3484
+ })
3485
+ });
3486
+ }
3487
+
3488
+ var PageLoaderContainer = /*#__PURE__*/styled.View.withConfig({
3489
+ displayName: "PageLoader__PageLoaderContainer"
3490
+ })(["transform:scale(-1) rotate(90deg);position:relative;width:", "px;height:", "px;"], function (_ref) {
3491
+ var theme = _ref.theme;
3492
+ return theme.kitt.pageLoader.size;
3493
+ }, function (_ref2) {
3494
+ var theme = _ref2.theme;
3495
+ return theme.kitt.pageLoader.size;
3496
+ });
3497
+ function PageLoader() {
3498
+ return /*#__PURE__*/jsxs(PageLoaderContainer, {
3499
+ children: [/*#__PURE__*/jsx(AnimatedBackgroundCircle, {}), /*#__PURE__*/jsx(AnimatedFilledCircle, {})]
3308
3500
  });
3309
3501
  }
3310
3502