@xqmsg/ui-core 0.12.1 → 0.14.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 (32) hide show
  1. package/dist/components/form/hooks/useFormHandler.d.ts +1 -1
  2. package/dist/components/input/Input.stories.d.ts +1 -0
  3. package/dist/components/input/StackedSelect/StackedSelect.d.ts +1 -0
  4. package/dist/components/input/index.d.ts +3 -3
  5. package/dist/index.d.ts +1 -0
  6. package/dist/theme/components/form-error.d.ts +2 -0
  7. package/dist/theme/components/form.d.ts +2 -0
  8. package/dist/theme/components/table.d.ts +4 -1
  9. package/dist/theme/foundations/colors.d.ts +1 -1
  10. package/dist/ui-core.cjs.development.js +84 -36
  11. package/dist/ui-core.cjs.development.js.map +1 -1
  12. package/dist/ui-core.cjs.production.min.js +1 -1
  13. package/dist/ui-core.cjs.production.min.js.map +1 -1
  14. package/dist/ui-core.esm.js +203 -156
  15. package/dist/ui-core.esm.js.map +1 -1
  16. package/package.json +8 -7
  17. package/src/components/form/hooks/useFormHandler.tsx +2 -2
  18. package/src/components/form/section/index.tsx +4 -3
  19. package/src/components/input/Input.stories.tsx +9 -1
  20. package/src/components/input/StackedPilledInput/index.tsx +12 -1
  21. package/src/components/input/StackedSelect/StackedSelect.tsx +18 -2
  22. package/src/components/input/StackedSwitch/index.tsx +0 -2
  23. package/src/components/input/components/dropdown/index.tsx +1 -1
  24. package/src/components/input/components/token/index.tsx +2 -2
  25. package/src/components/input/index.tsx +148 -166
  26. package/src/components/table/index.tsx +2 -1
  27. package/src/index.tsx +3 -0
  28. package/src/theme/components/form-error.ts +2 -0
  29. package/src/theme/components/form.ts +2 -0
  30. package/src/theme/components/table.ts +5 -5
  31. package/src/theme/foundations/colors.ts +1 -1
  32. package/src/theme/provider/index.tsx +6 -1
@@ -1,7 +1,7 @@
1
1
  import { FormEvent } from 'react';
2
2
  import { DeepPartial, FieldValues, UseFormReturn, ValidationMode } from 'react-hook-form';
3
3
  import * as Yup from 'yup';
4
- import { ErrorResponse } from 'src/components/form/utils/formErrors';
4
+ import { ErrorResponse } from '../../../../src/components/form/utils/formErrors';
5
5
  export declare type FormHandler<T extends FieldValues> = {
6
6
  form: UseFormReturn<T, any>;
7
7
  error?: ErrorResponse;
@@ -7,6 +7,7 @@ interface StoryFormSchema {
7
7
  prop3?: string;
8
8
  prop4?: string;
9
9
  prop5?: string;
10
+ prop6?: boolean;
10
11
  }
11
12
  export default meta;
12
13
  export declare const Default: import("@storybook/csf").AnnotatedStoryFn<import("@storybook/react").ReactFramework, InputProps<StoryFormSchema>>;
@@ -6,6 +6,7 @@ export interface StackedSelectProps extends StackedInputProps {
6
6
  options: FieldOptions;
7
7
  setValue: UseFormSetValue<FieldValues>;
8
8
  control: Control<FieldValues, any>;
9
+ handleOnChange: (value?: string) => void;
9
10
  }
10
11
  /**
11
12
  * A functional React component utilized to render the `StackedSelect` component.
@@ -12,10 +12,10 @@ export interface InputProps<T extends FieldValues> extends ValidationProps {
12
12
  options?: FieldOptions;
13
13
  maxLength?: number;
14
14
  helperText?: React.ReactNode;
15
- control?: Control<T, any>;
16
- onChange?: (args?: any) => void;
15
+ control: Control<T, any>;
16
+ onChange?: (value?: string) => void;
17
17
  disabled?: boolean;
18
- setValue?: UseFormSetValue<T>;
18
+ setValue: UseFormSetValue<T>;
19
19
  }
20
20
  /**
21
21
  * A functional React component utilized to render the `Input` component. Utilizes a switch statement
package/dist/index.d.ts CHANGED
@@ -13,3 +13,4 @@ export * from './components/tabs';
13
13
  export * from './components/text';
14
14
  export * from './theme/provider';
15
15
  export * from './components/form/utils/formErrors';
16
+ export * from './theme/foundations/colors';
@@ -3,6 +3,8 @@ declare const _default: {
3
3
  baseStyle: () => {
4
4
  text: {
5
5
  color: string;
6
+ position: string;
7
+ bottom: number;
6
8
  mt: number;
7
9
  ml: number;
8
10
  fontSize: string;
@@ -6,9 +6,11 @@ declare const _default: {
6
6
  color: string;
7
7
  };
8
8
  helperText: {
9
+ position: string;
9
10
  color: string;
10
11
  mt: number;
11
12
  ml: number;
13
+ bottom: number;
12
14
  fontSize: string;
13
15
  };
14
16
  };
@@ -1,6 +1,9 @@
1
1
  declare const _default: {
2
2
  parts: string[];
3
3
  baseStyle: {
4
+ thead: {
5
+ bg: string;
6
+ };
4
7
  th: {
5
8
  height: string;
6
9
  width: string;
@@ -15,7 +18,7 @@ declare const _default: {
15
18
  height: string;
16
19
  borderRadius: string;
17
20
  _odd: {
18
- background: string;
21
+ bg: string;
19
22
  };
20
23
  };
21
24
  td: {
@@ -10,7 +10,7 @@ export interface ColorHues {
10
10
  800: string;
11
11
  900: string;
12
12
  }
13
- declare const colors: {
13
+ export declare const colors: {
14
14
  label: {
15
15
  primary: {
16
16
  light: string;
@@ -8,19 +8,18 @@ var React = require('react');
8
8
  var React__default = _interopDefault(React);
9
9
  var react = require('@chakra-ui/react');
10
10
  var reactHookForm = require('react-hook-form');
11
- var colors$1 = _interopDefault(require('src/theme/foundations/colors'));
12
11
  var icons = require('@chakra-ui/icons');
13
12
  var hi = require('react-icons/hi');
14
13
  var themeTools = require('@chakra-ui/theme-tools');
15
14
  var system = require('@chakra-ui/system');
16
15
 
17
- var ErrorIcon = "<svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M5.5 5.5L8.5 8.5M8.5 5.5L5.5 8.5M13 7C13 10.3137 10.3137 13 7 13C3.68629 13 1 10.3137 1 7C1 3.68629 3.68629 1 7 1C10.3137 1 13 3.68629 13 7Z\" stroke=\"#F96057\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n</svg>";
16
+ var ErrorIcon = "data:image/svg+xml,%3Csvg%20width%3D%2214%22%20height%3D%2214%22%20viewBox%3D%220%200%2014%2014%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5.5%205.5L8.5%208.5M8.5%205.5L5.5%208.5M13%207C13%2010.3137%2010.3137%2013%207%2013C3.68629%2013%201%2010.3137%201%207C1%203.68629%203.68629%201%207%201C10.3137%201%2013%203.68629%2013%207Z%22%20stroke%3D%22%23F96057%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3C%2Fsvg%3E";
18
17
 
19
- var PositiveIcon = "<svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M5 7.5L6.5 9L9 5.5M13 7C13 10.3137 10.3137 13 7 13C3.68629 13 1 10.3137 1 7C1 3.68629 3.68629 1 7 1C10.3137 1 13 3.68629 13 7Z\" stroke=\"#34C759\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n</svg>";
18
+ var PositiveIcon = "data:image/svg+xml,%3Csvg%20width%3D%2214%22%20height%3D%2214%22%20viewBox%3D%220%200%2014%2014%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%207.5L6.5%209L9%205.5M13%207C13%2010.3137%2010.3137%2013%207%2013C3.68629%2013%201%2010.3137%201%207C1%203.68629%203.68629%201%207%201C10.3137%201%2013%203.68629%2013%207Z%22%20stroke%3D%22%2334C759%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3C%2Fsvg%3E";
20
19
 
21
- var NeutralIcon = "<svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M7 4.5V4C6.72386 4 6.5 4.22386 6.5 4.5H7ZM7.005 4.5H7.505C7.505 4.22386 7.28114 4 7.005 4V4.5ZM7.005 4.505V5.005C7.28114 5.005 7.505 4.78114 7.505 4.505H7.005ZM7 4.505H6.5C6.5 4.78114 6.72386 5.005 7 5.005V4.505ZM6.27639 6.05279C6.0294 6.17628 5.92929 6.47662 6.05279 6.72361C6.17628 6.9706 6.47662 7.07071 6.72361 6.94721L6.27639 6.05279ZM6.52766 6.48617L6.30405 6.03896L6.52766 6.48617ZM7.23634 7.05465L7.72141 7.17592L7.23634 7.05465ZM6.76366 8.94535L6.27859 8.82408L6.76366 8.94535ZM7.47234 9.51383L7.69595 9.96104L7.69595 9.96104L7.47234 9.51383ZM7.72361 9.94721C7.9706 9.82371 8.07071 9.52337 7.94721 9.27639C7.82371 9.0294 7.52337 8.92929 7.27639 9.05279L7.72361 9.94721ZM12.5 7C12.5 10.0376 10.0376 12.5 7 12.5V13.5C10.5899 13.5 13.5 10.5899 13.5 7H12.5ZM7 12.5C3.96243 12.5 1.5 10.0376 1.5 7H0.5C0.5 10.5899 3.41015 13.5 7 13.5V12.5ZM1.5 7C1.5 3.96243 3.96243 1.5 7 1.5V0.5C3.41015 0.5 0.5 3.41015 0.5 7H1.5ZM7 1.5C10.0376 1.5 12.5 3.96243 12.5 7H13.5C13.5 3.41015 10.5899 0.5 7 0.5V1.5ZM7 5H7.005V4H7V5ZM6.505 4.5V4.505H7.505V4.5H6.505ZM7.005 4.005H7V5.005H7.005V4.005ZM7.5 4.505V4.5H6.5V4.505H7.5ZM6.72361 6.94721L6.75127 6.93338L6.30405 6.03896L6.27639 6.05279L6.72361 6.94721ZM6.75127 6.93338L6.27859 8.82408L7.24873 9.06662L7.72141 7.17592L6.75127 6.93338ZM7.69595 9.96104L7.72361 9.94721L7.27639 9.05279L7.24873 9.06662L7.69595 9.96104ZM6.27859 8.82408C6.07138 9.65293 6.93179 10.3431 7.69595 9.96104L7.24873 9.06662L6.27859 8.82408ZM6.75127 6.93338L7.72141 7.17592C7.92862 6.34708 7.06821 5.65688 6.30405 6.03896L6.75127 6.93338Z\" fill=\"#3C3C43\" fill-opacity=\"0.6\"/>\n</svg>";
20
+ var NeutralIcon = "data:image/svg+xml,%3Csvg%20width%3D%2214%22%20height%3D%2214%22%20viewBox%3D%220%200%2014%2014%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M7%204.5V4C6.72386%204%206.5%204.22386%206.5%204.5H7ZM7.005%204.5H7.505C7.505%204.22386%207.28114%204%207.005%204V4.5ZM7.005%204.505V5.005C7.28114%205.005%207.505%204.78114%207.505%204.505H7.005ZM7%204.505H6.5C6.5%204.78114%206.72386%205.005%207%205.005V4.505ZM6.27639%206.05279C6.0294%206.17628%205.92929%206.47662%206.05279%206.72361C6.17628%206.9706%206.47662%207.07071%206.72361%206.94721L6.27639%206.05279ZM6.52766%206.48617L6.30405%206.03896L6.52766%206.48617ZM7.23634%207.05465L7.72141%207.17592L7.23634%207.05465ZM6.76366%208.94535L6.27859%208.82408L6.76366%208.94535ZM7.47234%209.51383L7.69595%209.96104L7.69595%209.96104L7.47234%209.51383ZM7.72361%209.94721C7.9706%209.82371%208.07071%209.52337%207.94721%209.27639C7.82371%209.0294%207.52337%208.92929%207.27639%209.05279L7.72361%209.94721ZM12.5%207C12.5%2010.0376%2010.0376%2012.5%207%2012.5V13.5C10.5899%2013.5%2013.5%2010.5899%2013.5%207H12.5ZM7%2012.5C3.96243%2012.5%201.5%2010.0376%201.5%207H0.5C0.5%2010.5899%203.41015%2013.5%207%2013.5V12.5ZM1.5%207C1.5%203.96243%203.96243%201.5%207%201.5V0.5C3.41015%200.5%200.5%203.41015%200.5%207H1.5ZM7%201.5C10.0376%201.5%2012.5%203.96243%2012.5%207H13.5C13.5%203.41015%2010.5899%200.5%207%200.5V1.5ZM7%205H7.005V4H7V5ZM6.505%204.5V4.505H7.505V4.5H6.505ZM7.005%204.005H7V5.005H7.005V4.005ZM7.5%204.505V4.5H6.5V4.505H7.5ZM6.72361%206.94721L6.75127%206.93338L6.30405%206.03896L6.27639%206.05279L6.72361%206.94721ZM6.75127%206.93338L6.27859%208.82408L7.24873%209.06662L7.72141%207.17592L6.75127%206.93338ZM7.69595%209.96104L7.72361%209.94721L7.27639%209.05279L7.24873%209.06662L7.69595%209.96104ZM6.27859%208.82408C6.07138%209.65293%206.93179%2010.3431%207.69595%209.96104L7.24873%209.06662L6.27859%208.82408ZM6.75127%206.93338L7.72141%207.17592C7.92862%206.34708%207.06821%205.65688%206.30405%206.03896L6.75127%206.93338Z%22%20fill%3D%22%233C3C43%22%20fill-opacity%3D%220.6%22%2F%3E%3C%2Fsvg%3E";
22
21
 
23
- var WarningIcon = "<svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M7 5V7.5M13 7C13 10.3137 10.3137 13 7 13C3.68629 13 1 10.3137 1 7C1 3.68629 3.68629 1 7 1C10.3137 1 13 3.68629 13 7ZM7 9.5H7.005V9.505H7V9.5Z\" stroke=\"#F8CE52\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n</svg>";
22
+ var WarningIcon = "data:image/svg+xml,%3Csvg%20width%3D%2214%22%20height%3D%2214%22%20viewBox%3D%220%200%2014%2014%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M7%205V7.5M13%207C13%2010.3137%2010.3137%2013%207%2013C3.68629%2013%201%2010.3137%201%207C1%203.68629%203.68629%201%207%201C10.3137%201%2013%203.68629%2013%207ZM7%209.5H7.005V9.505H7V9.5Z%22%20stroke%3D%22%23F8CE52%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3C%2Fsvg%3E";
24
23
 
25
24
  var blue = {
26
25
  50: 'hsl(209, 100%, 95%)',
@@ -328,7 +327,7 @@ var Button = function Button(_ref) {
328
327
  }, text);
329
328
  };
330
329
 
331
- var GoogleLogo = "<svg viewBox=\"0 0 533.5 544.3\" xmlns=\"http://www.w3.org/2000/svg\"><path\n d=\"M533.5 278.4c0-18.5-1.5-37.1-4.7-55.3H272.1v104.8h147c-6.1 33.8-25.7 63.7-54.4 82.7v68h87.7c51.5-47.4 81.1-117.4 81.1-200.2z\"\n fill=\"#4285f4\"\n /><path\n d=\"M272.1 544.3c73.4 0 135.3-24.1 180.4-65.7l-87.7-68c-24.4 16.6-55.9 26-92.6 26-71 0-131.2-47.9-152.8-112.3H28.9v70.1c46.2 91.9 140.3 149.9 243.2 149.9z\"\n fill=\"#34a853\"\n /><path\n d=\"M119.3 324.3c-11.4-33.8-11.4-70.4 0-104.2V150H28.9c-38.6 76.9-38.6 167.5 0 244.4l90.4-70.1z\"\n fill=\"#fbbc04\"\n /><path\n d=\"M272.1 107.7c38.8-.6 76.3 14 104.4 40.8l77.7-77.7C405 24.6 339.7-.8 272.1 0 169.2 0 75.1 58 28.9 150l90.4 70.1c21.5-64.5 81.8-112.4 152.8-112.4z\"\n fill=\"#ea4335\"\n /></svg>";
330
+ var GoogleLogo = "data:image/svg+xml,%3Csvg%20viewBox%3D%220%200%20533.5%20544.3%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20%20%20%20d%3D%22M533.5%20278.4c0-18.5-1.5-37.1-4.7-55.3H272.1v104.8h147c-6.1%2033.8-25.7%2063.7-54.4%2082.7v68h87.7c51.5-47.4%2081.1-117.4%2081.1-200.2z%22%20%20%20%20fill%3D%22%234285f4%22%20%20%2F%3E%3Cpath%20%20%20%20d%3D%22M272.1%20544.3c73.4%200%20135.3-24.1%20180.4-65.7l-87.7-68c-24.4%2016.6-55.9%2026-92.6%2026-71%200-131.2-47.9-152.8-112.3H28.9v70.1c46.2%2091.9%20140.3%20149.9%20243.2%20149.9z%22%20%20%20%20fill%3D%22%2334a853%22%20%20%2F%3E%3Cpath%20%20%20%20d%3D%22M119.3%20324.3c-11.4-33.8-11.4-70.4%200-104.2V150H28.9c-38.6%2076.9-38.6%20167.5%200%20244.4l90.4-70.1z%22%20%20%20%20fill%3D%22%23fbbc04%22%20%20%2F%3E%3Cpath%20%20%20%20d%3D%22M272.1%20107.7c38.8-.6%2076.3%2014%20104.4%2040.8l77.7-77.7C405%2024.6%20339.7-.8%20272.1%200%20169.2%200%2075.1%2058%2028.9%20150l90.4%2070.1c21.5-64.5%2081.8-112.4%20152.8-112.4z%22%20%20%20%20fill%3D%22%23ea4335%22%20%20%2F%3E%3C%2Fsvg%3E";
332
331
 
333
332
  /**
334
333
  * A functional React component utilized to render the `GoogleButton` component
@@ -496,7 +495,7 @@ var StackedRadioGroup = /*#__PURE__*/React__default.forwardRef(function (_ref2,
496
495
  })));
497
496
  });
498
497
 
499
- var SubtractIcon = "<svg width=\"12\" height=\"12\" viewBox=\"0 0 12 12\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M2 12C0.89543 12 -3.91405e-08 11.1046 -8.74228e-08 10L-4.37114e-07 2C-4.85396e-07 0.895431 0.89543 -3.91405e-08 2 -8.74228e-08L10 -4.37114e-07C11.1046 -4.85396e-07 12 0.89543 12 2L12 10C12 11.1046 11.1046 12 10 12L2 12ZM6 2.5C6.13261 2.5 6.25979 2.55268 6.35355 2.64645L7.85355 4.14645C8.04881 4.34171 8.04881 4.65829 7.85355 4.85355C7.65829 5.04882 7.34171 5.04882 7.14645 4.85355L6 3.70711L4.85355 4.85355C4.65829 5.04882 4.34171 5.04882 4.14645 4.85355C3.95118 4.65829 3.95118 4.34171 4.14645 4.14645L5.64645 2.64645C5.74021 2.55268 5.86739 2.5 6 2.5ZM5.64645 9.35355C5.74021 9.44732 5.86739 9.5 6 9.5C6.13261 9.5 6.25978 9.44732 6.35355 9.35355L7.85355 7.85355C8.04882 7.65829 8.04882 7.34171 7.85355 7.14645C7.65829 6.95118 7.34171 6.95118 7.14645 7.14645L6 8.29289L4.85355 7.14645C4.65829 6.95118 4.34171 6.95118 4.14645 7.14645C3.95118 7.34171 3.95118 7.65829 4.14645 7.85355L5.64645 9.35355Z\" fill=\"#0082FF\"/>\n</svg>";
498
+ var SubtractIcon = "data:image/svg+xml,%3Csvg%20width%3D%2212%22%20height%3D%2212%22%20viewBox%3D%220%200%2012%2012%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20d%3D%22M2%2012C0.89543%2012%20-3.91405e-08%2011.1046%20-8.74228e-08%2010L-4.37114e-07%202C-4.85396e-07%200.895431%200.89543%20-3.91405e-08%202%20-8.74228e-08L10%20-4.37114e-07C11.1046%20-4.85396e-07%2012%200.89543%2012%202L12%2010C12%2011.1046%2011.1046%2012%2010%2012L2%2012ZM6%202.5C6.13261%202.5%206.25979%202.55268%206.35355%202.64645L7.85355%204.14645C8.04881%204.34171%208.04881%204.65829%207.85355%204.85355C7.65829%205.04882%207.34171%205.04882%207.14645%204.85355L6%203.70711L4.85355%204.85355C4.65829%205.04882%204.34171%205.04882%204.14645%204.85355C3.95118%204.65829%203.95118%204.34171%204.14645%204.14645L5.64645%202.64645C5.74021%202.55268%205.86739%202.5%206%202.5ZM5.64645%209.35355C5.74021%209.44732%205.86739%209.5%206%209.5C6.13261%209.5%206.25978%209.44732%206.35355%209.35355L7.85355%207.85355C8.04882%207.65829%208.04882%207.34171%207.85355%207.14645C7.65829%206.95118%207.34171%206.95118%207.14645%207.14645L6%208.29289L4.85355%207.14645C4.65829%206.95118%204.34171%206.95118%204.14645%207.14645C3.95118%207.34171%203.95118%207.65829%204.14645%207.85355L5.64645%209.35355Z%22%20fill%3D%22%230082FF%22%2F%3E%3C%2Fsvg%3E";
500
499
 
501
500
  /**
502
501
  * A functional React component utilized to render the `Dropdown` component
@@ -508,14 +507,14 @@ var Dropdown = function Dropdown(_ref) {
508
507
  var DropdownContent = React.useMemo(function () {
509
508
  return options.map(function (option, idx) {
510
509
  return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, option.value === 'section_header' && options[idx + 1] && options[idx + 1].value !== 'section_header' && /*#__PURE__*/React__default.createElement(react.Box, {
511
- color: colors$1.label.secondary.light,
510
+ color: colors.label.secondary.light,
512
511
  fontSize: "13px",
513
512
  fontWeight: "bold",
514
513
  px: "8px"
515
514
  }, idx > 0 && /*#__PURE__*/React__default.createElement(react.Box, {
516
515
  my: "3px",
517
516
  borderTop: "2px solid",
518
- borderColor: colors$1.border["default"]
517
+ borderColor: colors.border["default"]
519
518
  }), option.label), option.value !== 'section_header' && /*#__PURE__*/React__default.createElement(react.Box, {
520
519
  cursor: "pointer",
521
520
  borderRadius: "inherit",
@@ -526,17 +525,17 @@ var Dropdown = function Dropdown(_ref) {
526
525
  fontSize: "13px",
527
526
  px: "8px",
528
527
  py: "4px",
529
- color: colors$1.label.primary.light,
528
+ color: colors.label.primary.light,
530
529
  _hover: {
531
- color: colors$1.label.primary.dark,
532
- bg: colors$1.fill.action,
530
+ color: colors.label.primary.dark,
531
+ bg: colors.fill.action,
533
532
  borderRadius: '4px'
534
533
  }
535
534
  }, option.label));
536
535
  });
537
536
  }, [onSelectItem, options]);
538
537
  return /*#__PURE__*/React__default.createElement(react.Box, {
539
- bg: colors$1.fill.light.quaternary,
538
+ bg: colors.fill.light.quaternary,
540
539
  backdropFilter: "blur(64px)",
541
540
  borderRadius: "4px",
542
541
  mt: "3px",
@@ -550,16 +549,27 @@ var Dropdown = function Dropdown(_ref) {
550
549
  }, DropdownContent);
551
550
  };
552
551
 
553
- var _excluded$1 = ["isRequired", "options", "name", "setValue", "onChange"];
552
+ var useDidMountEffect = function useDidMountEffect(func, deps) {
553
+ var didMount = React.useRef(false);
554
+ React.useEffect(function () {
555
+ if (didMount.current) func();else didMount.current = true; // eslint-disable-next-line
556
+ }, deps);
557
+ };
558
+
559
+ var _excluded$1 = ["isRequired", "options", "name", "setValue", "handleOnChange", "value"];
554
560
  /**
555
561
  * A functional React component utilized to render the `StackedSelect` component.
556
562
  */
557
563
 
558
564
  var StackedSelect = /*#__PURE__*/React__default.forwardRef(function (_ref2, _ref) {
565
+ var _options$find$label, _options$find;
566
+
559
567
  var isRequired = _ref2.isRequired,
560
568
  options = _ref2.options,
561
569
  name = _ref2.name,
562
570
  setValue = _ref2.setValue,
571
+ handleOnChange = _ref2.handleOnChange,
572
+ value = _ref2.value,
563
573
  props = _objectWithoutPropertiesLoose(_ref2, _excluded$1);
564
574
 
565
575
  var dropdownRef = React.useRef(null);
@@ -568,10 +578,19 @@ var StackedSelect = /*#__PURE__*/React__default.forwardRef(function (_ref2, _ref
568
578
  isFocussed = _useState[0],
569
579
  setIsFocussed = _useState[1];
570
580
 
571
- var _useState2 = React.useState(''),
581
+ var _useState2 = React.useState((_options$find$label = (_options$find = options.find(function (option) {
582
+ return option.value === value;
583
+ })) == null ? void 0 : _options$find.label) != null ? _options$find$label : ''),
572
584
  selectedOption = _useState2[0],
573
585
  setSelectedOption = _useState2[1];
574
586
 
587
+ useDidMountEffect(function () {
588
+ var _options$find$label2, _options$find2;
589
+
590
+ setSelectedOption((_options$find$label2 = (_options$find2 = options.find(function (option) {
591
+ return option.value === value;
592
+ })) == null ? void 0 : _options$find2.label) != null ? _options$find$label2 : '');
593
+ }, [value]);
575
594
  react.useOutsideClick({
576
595
  ref: dropdownRef,
577
596
  handler: function handler() {
@@ -580,6 +599,10 @@ var StackedSelect = /*#__PURE__*/React__default.forwardRef(function (_ref2, _ref
580
599
  });
581
600
 
582
601
  var handleOnSelectItem = function handleOnSelectItem(option) {
602
+ if (handleOnChange) {
603
+ handleOnChange(option.value);
604
+ }
605
+
583
606
  setValue(name, option.value);
584
607
  setSelectedOption(option.label);
585
608
  setIsFocussed(false);
@@ -629,7 +652,7 @@ var StackedTextarea = /*#__PURE__*/React__default.forwardRef(function (_ref2, _r
629
652
  }, props));
630
653
  });
631
654
 
632
- var CloseIcon = "<svg width=\"56\" height=\"56\" viewBox=\"0 0 56 56\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M27.9995 56C43.4635 56 55.9995 43.464 55.9995 28C55.9995 12.536 43.4635 0 27.9995 0C12.5355 0 -0.000488281 12.536 -0.000488281 28C-0.000488281 43.464 12.5355 56 27.9995 56ZM21.9807 18.2688C20.9555 17.2437 19.2935 17.2437 18.2684 18.2688C17.2432 19.294 17.2432 20.956 18.2684 21.9812L24.2872 28L18.2684 34.0188C17.2432 35.044 17.2432 36.706 18.2684 37.7312C19.2935 38.7563 20.9555 38.7563 21.9807 37.7312L27.9995 31.7123L34.0184 37.7312C35.0435 38.7563 36.7055 38.7563 37.7307 37.7312C38.7558 36.706 38.7558 35.044 37.7307 34.0188L31.7118 28L37.7307 21.9812C38.7558 20.956 38.7558 19.294 37.7307 18.2688C36.7055 17.2437 35.0435 17.2437 34.0184 18.2688L27.9995 24.2877L21.9807 18.2688Z\" fill=\"#3C3C43\" fill-opacity=\"0.6\"/>\n</svg>";
655
+ var CloseIcon = "data:image/svg+xml,%3Csvg%20width%3D%2256%22%20height%3D%2256%22%20viewBox%3D%220%200%2056%2056%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20d%3D%22M27.9995%2056C43.4635%2056%2055.9995%2043.464%2055.9995%2028C55.9995%2012.536%2043.4635%200%2027.9995%200C12.5355%200%20-0.000488281%2012.536%20-0.000488281%2028C-0.000488281%2043.464%2012.5355%2056%2027.9995%2056ZM21.9807%2018.2688C20.9555%2017.2437%2019.2935%2017.2437%2018.2684%2018.2688C17.2432%2019.294%2017.2432%2020.956%2018.2684%2021.9812L24.2872%2028L18.2684%2034.0188C17.2432%2035.044%2017.2432%2036.706%2018.2684%2037.7312C19.2935%2038.7563%2020.9555%2038.7563%2021.9807%2037.7312L27.9995%2031.7123L34.0184%2037.7312C35.0435%2038.7563%2036.7055%2038.7563%2037.7307%2037.7312C38.7558%2036.706%2038.7558%2035.044%2037.7307%2034.0188L31.7118%2028L37.7307%2021.9812C38.7558%2020.956%2038.7558%2019.294%2037.7307%2018.2688C36.7055%2017.2437%2035.0435%2017.2437%2034.0184%2018.2688L27.9995%2024.2877L21.9807%2018.2688Z%22%20fill%3D%22%233C3C43%22%20fill-opacity%3D%220.6%22%2F%3E%3C%2Fsvg%3E";
633
656
 
634
657
  var Token = function Token(_ref) {
635
658
  var label = _ref.label,
@@ -639,12 +662,12 @@ var Token = function Token(_ref) {
639
662
  borderRadius: "full",
640
663
  backgroundColor: "#7676801F",
641
664
  alignItems: "center",
642
- width: "fit-content",
665
+ // width="100%"
643
666
  pl: "8px",
644
667
  pr: "4px",
645
668
  py: "2px"
646
669
  }, /*#__PURE__*/React__default.createElement(react.Text, {
647
- color: colors$1.label.primary.light,
670
+ color: colors.label.primary.light,
648
671
  fontSize: "13px"
649
672
  }, label), /*#__PURE__*/React__default.createElement(react.Image, {
650
673
  pl: "4px",
@@ -957,7 +980,14 @@ var StackedPilledInput = /*#__PURE__*/React__default.forwardRef(function (_ref2,
957
980
  }, /*#__PURE__*/React__default.createElement(react.Flex, {
958
981
  height: "28px",
959
982
  alignItems: "center",
960
- width: "fit-content"
983
+ // width="fit-content"
984
+ // maxW="70%"
985
+ overflowX: "auto",
986
+ style: {
987
+ scrollbarWidth: 'none'
988
+ /* Firefox */
989
+
990
+ }
961
991
  }, lastestFormValueToArray.length ? lastestFormValueToArray.map(function (label, index) {
962
992
  return /*#__PURE__*/React__default.createElement(react.Box, {
963
993
  mr: "4px",
@@ -965,7 +995,9 @@ var StackedPilledInput = /*#__PURE__*/React__default.forwardRef(function (_ref2,
965
995
  borderRadius: "full",
966
996
  onClick: function onClick() {
967
997
  return setTokenIndex(index);
968
- }
998
+ },
999
+ // width="fit-content"
1000
+ width: "100%"
969
1001
  }, /*#__PURE__*/React__default.createElement(Token, {
970
1002
  label: label,
971
1003
  onDelete: function onDelete(e) {
@@ -1009,7 +1041,6 @@ var StackedSwitch = /*#__PURE__*/React__default.forwardRef(function (_ref2, _ref
1009
1041
  var isRequired = _ref2.isRequired,
1010
1042
  _onChange = _ref2.onChange,
1011
1043
  value = _ref2.value;
1012
- if (value === undefined) return null;
1013
1044
  return /*#__PURE__*/React__default.createElement(react.Switch, {
1014
1045
  size: "lg",
1015
1046
  ref: _ref,
@@ -1058,7 +1089,8 @@ function Input(_ref) {
1058
1089
  disabled = _ref.disabled,
1059
1090
  onChange = _ref.onChange,
1060
1091
  setValue = _ref.setValue;
1061
- var selectedInputField = React.useCallback(function (onChange, onBlur, ref, value) {
1092
+
1093
+ var selectedInputField = function selectedInputField(onChange, onBlur, ref, value) {
1062
1094
  switch (inputType) {
1063
1095
  case 'text':
1064
1096
  return /*#__PURE__*/React__default.createElement(StackedInput, {
@@ -1082,7 +1114,6 @@ function Input(_ref) {
1082
1114
  className: "input-" + inputType + " " + (className != null ? className : ''),
1083
1115
  name: name,
1084
1116
  id: name,
1085
- isRequired: isRequired,
1086
1117
  isInvalid: isInvalid,
1087
1118
  options: options,
1088
1119
  onChange: onChange,
@@ -1100,13 +1131,14 @@ function Input(_ref) {
1100
1131
  isRequired: isRequired,
1101
1132
  isInvalid: isInvalid,
1102
1133
  options: options,
1103
- onChange: onChange,
1134
+ handleOnChange: onChange,
1104
1135
  onBlur: onBlur,
1105
1136
  setValue: setValue,
1106
1137
  control: control,
1107
1138
  ref: ref,
1108
1139
  disabled: disabled,
1109
1140
  value: value,
1141
+ defaultValue: defaultValue,
1110
1142
  placeholder: placeholder
1111
1143
  });
1112
1144
 
@@ -1116,7 +1148,6 @@ function Input(_ref) {
1116
1148
  name: name,
1117
1149
  id: name,
1118
1150
  maxLength: maxLength,
1119
- isRequired: isRequired,
1120
1151
  isInvalid: isInvalid,
1121
1152
  onChange: onChange,
1122
1153
  onBlur: onBlur,
@@ -1130,7 +1161,6 @@ function Input(_ref) {
1130
1161
  className: "input-" + inputType + " " + (className != null ? className : ''),
1131
1162
  name: name,
1132
1163
  id: name,
1133
- isRequired: isRequired,
1134
1164
  isInvalid: isInvalid,
1135
1165
  options: options,
1136
1166
  onChange: onChange,
@@ -1188,7 +1218,8 @@ function Input(_ref) {
1188
1218
  default:
1189
1219
  return null;
1190
1220
  }
1191
- }, [ariaLabel, className, control, disabled, inputType, isInvalid, isRequired, maxLength, name, options, placeholder, setValue]);
1221
+ };
1222
+
1192
1223
  return /*#__PURE__*/React__default.createElement(reactHookForm.Controller, {
1193
1224
  control: control,
1194
1225
  name: name,
@@ -1196,6 +1227,8 @@ function Input(_ref) {
1196
1227
  rules: {
1197
1228
  required: isRequired
1198
1229
  },
1230
+
1231
+ /** @ts-ignore: issues with implicit */
1199
1232
  render: function render(_ref2) {
1200
1233
  var _ref2$field = _ref2.field,
1201
1234
  onBlur = _ref2$field.onBlur,
@@ -1206,7 +1239,7 @@ function Input(_ref) {
1206
1239
  id: name,
1207
1240
  isInvalid: isInvalid,
1208
1241
  position: "relative",
1209
- py: label ? 6 : 0
1242
+ py: label || helperText || isInvalid ? 6 : 0
1210
1243
  }, label && /*#__PURE__*/React__default.createElement(Label$1, {
1211
1244
  label: label,
1212
1245
  isRequired: isRequired
@@ -1258,7 +1291,8 @@ function FormSection(_ref) {
1258
1291
  isRequired: isRequired,
1259
1292
  maxLength: maxLength,
1260
1293
  isInvalid: !!form.formState.errors[name],
1261
- defaultValue: defaultValue
1294
+ defaultValue: defaultValue,
1295
+ setValue: form.setValue
1262
1296
  });
1263
1297
  }));
1264
1298
  }
@@ -1506,7 +1540,11 @@ function Table(_ref) {
1506
1540
  borderTopRightRadius: borderTopRadius ? 'md' : 0
1507
1541
  }, /*#__PURE__*/React__default.createElement(react.Table, {
1508
1542
  variant: "unstyled"
1509
- }, /*#__PURE__*/React__default.createElement(react.Thead, null, /*#__PURE__*/React__default.createElement(react.Tr, null, columnsAsConst.map(function (column) {
1543
+ }, /*#__PURE__*/React__default.createElement(react.Thead, null, /*#__PURE__*/React__default.createElement(react.Tr, {
1544
+ _odd: {
1545
+ bg: colors.label.primary.dark
1546
+ }
1547
+ }, columnsAsConst.map(function (column) {
1510
1548
  return (
1511
1549
  /*#__PURE__*/
1512
1550
  // @ts-ignore
@@ -1822,9 +1860,11 @@ function baseStyleRequiredIndicator() {
1822
1860
 
1823
1861
  function baseStyleHelperText() {
1824
1862
  return {
1863
+ position: 'absolute',
1825
1864
  color: colors.label.secondary.light,
1826
1865
  mt: 1,
1827
1866
  ml: 1,
1867
+ bottom: 0,
1828
1868
  fontSize: '13px'
1829
1869
  };
1830
1870
  }
@@ -1846,6 +1886,8 @@ var parts$2 = ['text', 'icon'];
1846
1886
  function baseStyleText() {
1847
1887
  return {
1848
1888
  color: colors.label.error,
1889
+ position: 'absolute',
1890
+ bottom: 0,
1849
1891
  mt: 1,
1850
1892
  ml: 1,
1851
1893
  fontSize: '13px'
@@ -2363,10 +2405,13 @@ var Switch = {
2363
2405
  defaultProps: defaultProps$7
2364
2406
  };
2365
2407
 
2366
- var parts$7 = ['th', 'td', 'tr', 'body'];
2408
+ var parts$7 = ['th', 'td', 'tr', 'body', 'thead'];
2367
2409
  var baseStyle$c = {
2410
+ thead: {
2411
+ bg: colors.label.primary.dark
2412
+ },
2368
2413
  th: {
2369
- height: 'fit-content',
2414
+ height: '100%',
2370
2415
  width: '100%',
2371
2416
  bg: colors.label.primary.dark,
2372
2417
  padding: '5px 8px !important'
@@ -2376,10 +2421,10 @@ var baseStyle$c = {
2376
2421
  display: 'flex',
2377
2422
  alignItems: 'center',
2378
2423
  width: '100%',
2379
- height: 'fit-content',
2424
+ height: '100%',
2380
2425
  borderRadius: 'md',
2381
2426
  _odd: {
2382
- background: colors.fill.light.tertiary
2427
+ bg: colors.fill.light.tertiary
2383
2428
  }
2384
2429
  },
2385
2430
  td: {
@@ -2744,10 +2789,12 @@ var customXQChakraTheme = /*#__PURE__*/react.extendTheme( /*#__PURE__*/_extends(
2744
2789
  */
2745
2790
 
2746
2791
  var XQThemeProvider = function XQThemeProvider(_ref) {
2747
- var children = _ref.children;
2792
+ var children = _ref.children,
2793
+ cssVarsRoot = _ref.cssVarsRoot;
2748
2794
  return /*#__PURE__*/React__default.createElement(react.ChakraProvider, {
2749
2795
  theme: customXQChakraTheme,
2750
- resetCSS: true
2796
+ resetCSS: true,
2797
+ cssVarsRoot: cssVarsRoot
2751
2798
  }, children);
2752
2799
  };
2753
2800
 
@@ -2791,5 +2838,6 @@ exports.Table = Table;
2791
2838
  exports.TabsWrapper = TabsWrapper;
2792
2839
  exports.Text = Text;
2793
2840
  exports.XQThemeProvider = XQThemeProvider;
2841
+ exports.colors = colors;
2794
2842
  exports.formatErrorResponse = formatErrorResponse;
2795
2843
  //# sourceMappingURL=ui-core.cjs.development.js.map