@7shifts/sous-chef 1.5.7 → 1.5.9

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 (181) hide show
  1. package/dist/actions/PaginationControls/PaginationControls.d.ts +1 -0
  2. package/dist/controls/ToolbarSelect/ToolbarSelect.d.ts +17 -0
  3. package/dist/controls/ToolbarSelect/ToolbarSelect.styles.d.ts +5 -0
  4. package/dist/controls/ToolbarSelect/index.d.ts +1 -0
  5. package/dist/controls/index.d.ts +2 -0
  6. package/dist/core/DataTableRow/DataTableRowActions/DataTableRowActions.d.ts +6 -0
  7. package/dist/core/DataTableRow/DataTableRowActions/index.d.ts +1 -0
  8. package/dist/feedback/InlineBanner/ButtonCTA/ButtonCTA.d.ts +10 -0
  9. package/dist/feedback/InlineBanner/ButtonCTA/index.d.ts +1 -0
  10. package/dist/feedback/InlineBanner/InlineBanner.d.ts +14 -0
  11. package/dist/feedback/InlineBanner/InlineBannerCTA/InlineBannerCTA.d.ts +11 -0
  12. package/dist/feedback/InlineBanner/InlineBannerCTA/index.d.ts +1 -0
  13. package/dist/feedback/InlineBanner/InlineBannerIcon/InlineBannerIcon.d.ts +6 -0
  14. package/dist/feedback/InlineBanner/InlineBannerIcon/index.d.ts +1 -0
  15. package/dist/feedback/InlineBanner/constants.d.ts +11 -0
  16. package/dist/feedback/InlineBanner/index.d.ts +1 -0
  17. package/dist/feedback/InlineBanner/types.d.ts +1 -0
  18. package/dist/forms/AsyncSelectField/AsyncSelectField.d.ts +14 -0
  19. package/dist/forms/AsyncSelectField/CustomList/CustomList.d.ts +8 -0
  20. package/dist/forms/AsyncSelectField/CustomList/index.d.ts +1 -0
  21. package/dist/forms/AsyncSelectField/index.d.ts +1 -0
  22. package/dist/forms/AsyncSelectField/types.d.ts +5 -0
  23. package/dist/forms/CurrencyField/CurrencyField.d.ts +11 -0
  24. package/dist/forms/CurrencyField/index.d.ts +1 -0
  25. package/dist/forms/Label/domain.d.ts +1 -0
  26. package/dist/forms/Label/useLabelTooltip.d.ts +7 -0
  27. package/dist/forms/PercentageField/PercentageField.d.ts +13 -0
  28. package/dist/forms/PercentageField/index.d.ts +1 -0
  29. package/dist/forms/SelectField/domain.d.ts +5 -0
  30. package/dist/forms/SelectField/useSelectField.d.ts +12 -0
  31. package/dist/forms/TextField/useTextField.d.ts +38 -0
  32. package/dist/forms/TimeField/TimeField.d.ts +9 -0
  33. package/dist/forms/TimeField/index.d.ts +1 -0
  34. package/dist/icons/components/IconAnalytics.d.ts +12 -0
  35. package/dist/icons/components/IconArrowDown.d.ts +12 -0
  36. package/dist/icons/components/IconArrowLeft.d.ts +12 -0
  37. package/dist/icons/components/IconArrowRight.d.ts +12 -0
  38. package/dist/icons/components/IconArrowToTop.d.ts +12 -0
  39. package/dist/icons/components/IconArrowUp.d.ts +12 -0
  40. package/dist/icons/components/IconAward.d.ts +12 -0
  41. package/dist/icons/components/IconBalanceScale.d.ts +12 -0
  42. package/dist/icons/components/IconBalanceScaleLeft.d.ts +12 -0
  43. package/dist/icons/components/IconBan.d.ts +12 -0
  44. package/dist/icons/components/IconBarsH.d.ts +12 -0
  45. package/dist/icons/components/IconBarsV.d.ts +12 -0
  46. package/dist/icons/components/IconBell.d.ts +12 -0
  47. package/dist/icons/components/IconBirthdayCake.d.ts +12 -0
  48. package/dist/icons/components/IconBold.d.ts +12 -0
  49. package/dist/icons/components/IconBolt.d.ts +12 -0
  50. package/dist/icons/components/IconBook.d.ts +12 -0
  51. package/dist/icons/components/IconBriefcase.d.ts +12 -0
  52. package/dist/icons/components/IconBullseyeArrow.d.ts +12 -0
  53. package/dist/icons/components/IconCalculator.d.ts +12 -0
  54. package/dist/icons/components/IconCalendar.d.ts +12 -0
  55. package/dist/icons/components/IconCalendarAlt.d.ts +12 -0
  56. package/dist/icons/components/IconCalendarCheck.d.ts +12 -0
  57. package/dist/icons/components/IconCalendarDay.d.ts +12 -0
  58. package/dist/icons/components/IconCalendarExclamation.d.ts +12 -0
  59. package/dist/icons/components/IconCalendarStar.d.ts +12 -0
  60. package/dist/icons/components/IconCalendarTomorrow.d.ts +12 -0
  61. package/dist/icons/components/IconCamera.d.ts +12 -0
  62. package/dist/icons/components/IconCameraSlash.d.ts +12 -0
  63. package/dist/icons/components/IconCashRegister.d.ts +12 -0
  64. package/dist/icons/components/IconChartBar.d.ts +12 -0
  65. package/dist/icons/components/IconCheck.d.ts +12 -0
  66. package/dist/icons/components/IconChevronDown.d.ts +12 -0
  67. package/dist/icons/components/IconChevronLeft.d.ts +12 -0
  68. package/dist/icons/components/IconChevronRight.d.ts +12 -0
  69. package/dist/icons/components/IconChevronUp.d.ts +12 -0
  70. package/dist/icons/components/IconClipboardList.d.ts +12 -0
  71. package/dist/icons/components/IconClock.d.ts +12 -0
  72. package/dist/icons/components/IconCog.d.ts +12 -0
  73. package/dist/icons/components/IconComment.d.ts +12 -0
  74. package/dist/icons/components/IconCommentLines.d.ts +12 -0
  75. package/dist/icons/components/IconCopy.d.ts +12 -0
  76. package/dist/icons/components/IconCreditCard.d.ts +12 -0
  77. package/dist/icons/components/IconCreditCardPlus.d.ts +12 -0
  78. package/dist/icons/components/IconDownload.d.ts +12 -0
  79. package/dist/icons/components/IconEdit.d.ts +12 -0
  80. package/dist/icons/components/IconEllipsisV.d.ts +12 -0
  81. package/dist/icons/components/IconEnvelope.d.ts +12 -0
  82. package/dist/icons/components/IconExclaimation.d.ts +12 -0
  83. package/dist/icons/components/IconExclaimationTriangle.d.ts +12 -0
  84. package/dist/icons/components/IconExpand.d.ts +12 -0
  85. package/dist/icons/components/IconExternalLink.d.ts +12 -0
  86. package/dist/icons/components/IconEye.d.ts +12 -0
  87. package/dist/icons/components/IconEyeSlash.d.ts +12 -0
  88. package/dist/icons/components/IconFile.d.ts +12 -0
  89. package/dist/icons/components/IconFilePdf.d.ts +12 -0
  90. package/dist/icons/components/IconFlag.d.ts +12 -0
  91. package/dist/icons/components/IconFourDotsCircle.d.ts +12 -0
  92. package/dist/icons/components/IconFourSquares.d.ts +12 -0
  93. package/dist/icons/components/IconGavel.d.ts +12 -0
  94. package/dist/icons/components/IconGif.d.ts +12 -0
  95. package/dist/icons/components/IconGift.d.ts +12 -0
  96. package/dist/icons/components/IconGrinBeam.d.ts +12 -0
  97. package/dist/icons/components/IconGripVertical.d.ts +12 -0
  98. package/dist/icons/components/IconHandshake.d.ts +12 -0
  99. package/dist/icons/components/IconImage.d.ts +12 -0
  100. package/dist/icons/components/IconInfoCircle.d.ts +12 -0
  101. package/dist/icons/components/IconIslandTropical.d.ts +12 -0
  102. package/dist/icons/components/IconItalic.d.ts +12 -0
  103. package/dist/icons/components/IconLaptopSearch.d.ts +12 -0
  104. package/dist/icons/components/IconLink.d.ts +12 -0
  105. package/dist/icons/components/IconList.d.ts +12 -0
  106. package/dist/icons/components/IconListOI.d.ts +12 -0
  107. package/dist/icons/components/IconLock.d.ts +12 -0
  108. package/dist/icons/components/IconMagicSolid.d.ts +12 -0
  109. package/dist/icons/components/IconMapMarker.d.ts +12 -0
  110. package/dist/icons/components/IconMegaphone.d.ts +12 -0
  111. package/dist/icons/components/IconMinus.d.ts +12 -0
  112. package/dist/icons/components/IconMinusCircle.d.ts +12 -0
  113. package/dist/icons/components/IconMoneyBill.d.ts +12 -0
  114. package/dist/icons/components/IconNotesMedical.d.ts +12 -0
  115. package/dist/icons/components/IconOvertime.d.ts +12 -0
  116. package/dist/icons/components/IconPaperPlane.d.ts +12 -0
  117. package/dist/icons/components/IconPaperPlaneClock.d.ts +12 -0
  118. package/dist/icons/components/IconPaperclip.d.ts +12 -0
  119. package/dist/icons/components/IconPencil.d.ts +12 -0
  120. package/dist/icons/components/IconPercentage.d.ts +12 -0
  121. package/dist/icons/components/IconPhone.d.ts +12 -0
  122. package/dist/icons/components/IconPlug.d.ts +12 -0
  123. package/dist/icons/components/IconPlus.d.ts +12 -0
  124. package/dist/icons/components/IconPrint.d.ts +12 -0
  125. package/dist/icons/components/IconQuestionCircle.d.ts +12 -0
  126. package/dist/icons/components/IconRepeat.d.ts +12 -0
  127. package/dist/icons/components/IconReply.d.ts +12 -0
  128. package/dist/icons/components/IconSearch.d.ts +12 -0
  129. package/dist/icons/components/IconSignOut.d.ts +12 -0
  130. package/dist/icons/components/IconSitemap.d.ts +12 -0
  131. package/dist/icons/components/IconSlidersH.d.ts +12 -0
  132. package/dist/icons/components/IconSort.d.ts +12 -0
  133. package/dist/icons/components/IconStar.d.ts +12 -0
  134. package/dist/icons/components/IconStarSolid.d.ts +12 -0
  135. package/dist/icons/components/IconStickyNoteLines.d.ts +12 -0
  136. package/dist/icons/components/IconStopwatch.d.ts +12 -0
  137. package/dist/icons/components/IconStrikethrough.d.ts +12 -0
  138. package/dist/icons/components/IconSync.d.ts +12 -0
  139. package/dist/icons/components/IconSyncExclaimation.d.ts +12 -0
  140. package/dist/icons/components/IconTachometer.d.ts +12 -0
  141. package/dist/icons/components/IconTimes.d.ts +12 -0
  142. package/dist/icons/components/IconTimesOctagon.d.ts +12 -0
  143. package/dist/icons/components/IconTrash.d.ts +12 -0
  144. package/dist/icons/components/IconUnderline.d.ts +12 -0
  145. package/dist/icons/components/IconUndo.d.ts +12 -0
  146. package/dist/icons/components/IconUniversity.d.ts +12 -0
  147. package/dist/icons/components/IconUserComputer.d.ts +12 -0
  148. package/dist/icons/components/IconUserFriends.d.ts +12 -0
  149. package/dist/icons/components/IconUserLight.d.ts +12 -0
  150. package/dist/icons/components/IconUserPlus.d.ts +12 -0
  151. package/dist/icons/components/IconUserSlash.d.ts +12 -0
  152. package/dist/icons/components/IconUserSolid.d.ts +12 -0
  153. package/dist/icons/components/IconUserTag.d.ts +12 -0
  154. package/dist/icons/components/IconUserTie.d.ts +12 -0
  155. package/dist/icons/components/IconUsers.d.ts +12 -0
  156. package/dist/icons/components/IconVideo.d.ts +12 -0
  157. package/dist/icons/components/IconVolume.d.ts +12 -0
  158. package/dist/icons/components/IconVolumeMute.d.ts +12 -0
  159. package/dist/icons/components/IconWrench.d.ts +12 -0
  160. package/dist/icons/components/index.d.ts +126 -0
  161. package/dist/icons/icon-typescript-template.d.ts +9 -0
  162. package/dist/index.css +3 -3
  163. package/dist/index.js +4 -2
  164. package/dist/index.js.map +1 -1
  165. package/dist/index.modern.js +4 -2
  166. package/dist/index.modern.js.map +1 -1
  167. package/dist/media/Chip/Chip.d.ts +11 -0
  168. package/dist/media/Chip/constants.d.ts +8 -0
  169. package/dist/media/Chip/index.d.ts +1 -0
  170. package/dist/media/Chip/types.d.ts +1 -0
  171. package/dist/media/Pill/Pill.d.ts +10 -0
  172. package/dist/media/Pill/constants.d.ts +7 -0
  173. package/dist/media/Pill/index.d.ts +1 -0
  174. package/dist/media/Pill/types.d.ts +1 -0
  175. package/dist/overlay/Calendar/Calendar.d.ts +24 -0
  176. package/dist/overlay/Calendar/constants.d.ts +8 -0
  177. package/dist/overlay/Calendar/domain.d.ts +7 -0
  178. package/dist/overlay/Calendar/index.d.ts +1 -0
  179. package/dist/overlay/Calendar/types.d.ts +2 -0
  180. package/dist/overlay/Modal/ModalBody/useScrollShadow.d.ts +7 -0
  181. package/package.json +1 -1
@@ -4,6 +4,7 @@ declare type Props = {
4
4
  hasNext?: boolean;
5
5
  onPreviousClick: () => void;
6
6
  onNextClick: () => void;
7
+ testId?: string;
7
8
  };
8
9
  /**
9
10
  * `PaginationControls` are two buttons side by side.
@@ -0,0 +1,17 @@
1
+ import React from 'react';
2
+ import type { SelectOption, SelectOptions } from '../../forms/SelectField/types';
3
+ declare type Props<T> = {
4
+ name: string;
5
+ value?: SelectOption<T>;
6
+ placeholder?: string;
7
+ options: SelectOptions<T>;
8
+ onChange?: (e: SelectOption<T>) => void;
9
+ onBlur?: (e: SelectOption<T>) => void;
10
+ disabled?: boolean;
11
+ /** Use a prefix for things like icons or symbols (“$”, “¥”, “£”). */
12
+ prefix: React.ReactNode;
13
+ testId?: string;
14
+ };
15
+ /** Toolbar component to make a possible selection from predefined options. */
16
+ declare const ToolbarSelect: <T extends unknown>({ name, value, options, onChange, onBlur, placeholder, disabled, prefix, testId }: Props<T>) => JSX.Element;
17
+ export default ToolbarSelect;
@@ -0,0 +1,5 @@
1
+ declare type GetSelectStylesControls = {
2
+ wrapToNextLine?: boolean;
3
+ };
4
+ export declare const getSelectStyles: ({ wrapToNextLine }: GetSelectStylesControls) => Object;
5
+ export {};
@@ -0,0 +1 @@
1
+ export { default } from './ToolbarSelect';
@@ -0,0 +1,2 @@
1
+ import ToolbarSelect from './ToolbarSelect';
2
+ export { ToolbarSelect };
@@ -0,0 +1,6 @@
1
+ import type { Action } from '../../DataTable/types';
2
+ declare type Props = {
3
+ actions: Action[];
4
+ };
5
+ declare const ActionsCell: ({ actions }: Props) => JSX.Element;
6
+ export default ActionsCell;
@@ -0,0 +1 @@
1
+ export { default } from './DataTableRowActions';
@@ -0,0 +1,10 @@
1
+ import { InlineBannerTheme } from '../types';
2
+ import React from 'react';
3
+ declare type ButtonCTAProps = {
4
+ button: React.ReactElement;
5
+ bannerTheme: InlineBannerTheme;
6
+ primaryCTA?: boolean;
7
+ };
8
+ /** Infers theme prop for Sous Chef Button CTAs if not explicitly passed, default is hollow, primaryCTA is Upsell if banner theme is Upsell*/
9
+ declare const ButtonCTA: ({ button, bannerTheme, primaryCTA }: ButtonCTAProps) => React.ReactElement<any, string | ((props: any) => React.ReactElement<any, any> | null) | (new (props: any) => React.Component<any, any, any>)>;
10
+ export default ButtonCTA;
@@ -0,0 +1 @@
1
+ export { default } from './ButtonCTA';
@@ -0,0 +1,14 @@
1
+ import React from 'react';
2
+ import { InlineBannerTheme } from './types';
3
+ declare type Props = {
4
+ children: React.ReactNode;
5
+ theme?: InlineBannerTheme;
6
+ title?: string;
7
+ onClose?: () => void;
8
+ caption?: string;
9
+ primaryButton?: React.ReactElement;
10
+ secondaryButton?: React.ReactElement;
11
+ testId?: string;
12
+ };
13
+ declare const InlineBanner: React.FC<Props>;
14
+ export default InlineBanner;
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import { InlineBannerTheme } from '../types';
3
+ declare type Props = {
4
+ primaryButton: React.ReactElement;
5
+ secondaryButton?: React.ReactElement;
6
+ caption?: string;
7
+ multiLine: boolean;
8
+ bannerTheme: InlineBannerTheme;
9
+ };
10
+ declare const InlineBannerCTA: ({ primaryButton, secondaryButton, caption, multiLine, bannerTheme }: Props) => JSX.Element;
11
+ export default InlineBannerCTA;
@@ -0,0 +1 @@
1
+ export { default } from './InlineBannerCTA';
@@ -0,0 +1,6 @@
1
+ import { InlineBannerTheme } from '../types';
2
+ declare type BannerIconProps = {
3
+ theme: InlineBannerTheme;
4
+ };
5
+ declare const InlineBannerIcon: ({ theme }: BannerIconProps) => JSX.Element;
6
+ export default InlineBannerIcon;
@@ -0,0 +1 @@
1
+ export { default } from './InlineBannerIcon';
@@ -0,0 +1,11 @@
1
+ export declare const BANNER_THEME: {
2
+ INFO: "info";
3
+ WARNING: "warning";
4
+ SUCCESS: "success";
5
+ DANGER: "danger";
6
+ UPSELL: "upsell";
7
+ };
8
+ export declare const BUTTON_THEME: {
9
+ HOLLOW: "hollow";
10
+ UPSELL: "upsell";
11
+ };
@@ -0,0 +1 @@
1
+ export { default } from './InlineBanner';
@@ -0,0 +1 @@
1
+ export declare type InlineBannerTheme = 'info' | 'warning' | 'success' | 'danger' | 'upsell';
@@ -0,0 +1,14 @@
1
+ import type { Props as SelectProps } from '../SelectField/SelectField';
2
+ import { AsyncSelectOptions } from './types';
3
+ declare type Props<T> = {
4
+ /** It is a function that takes the input search as parameter and returns a Promise with all the options and if there are more options to load. If it brings all the options on the first load, it won't call the `loadOptions` to perform the search. */
5
+ loadOptions: (inputValue: string) => Promise<AsyncSelectOptions<T>>;
6
+ /** It fires `loadOptions` again if this key value changes. Used when it depends on other fields to load its options */
7
+ key?: string | number;
8
+ } & Omit<SelectProps<T>, 'options'>;
9
+ /**
10
+ * Component to make possible choose from async options. It looks exactly as the [SelectField](./?path=/docs/forms-selectfield--default) but, this one handle asynchronous options.
11
+ * Instead of passing a `options` props, this component requires a `loadOptions` prop.
12
+ * */
13
+ declare const AsyncSelectField: <T extends unknown>({ loadOptions, ...props }: Props<T>) => JSX.Element;
14
+ export default AsyncSelectField;
@@ -0,0 +1,8 @@
1
+ import { ComponentProps } from 'react';
2
+ import { components } from 'react-select';
3
+ declare type Props = ComponentProps<typeof components.MenuList> & {
4
+ hasMoreOptions: boolean;
5
+ hasMoreOptionsFirstLoad: boolean | null | undefined;
6
+ };
7
+ declare const CustomList: ({ children, hasMoreOptions, hasMoreOptionsFirstLoad, ...props }: Props) => JSX.Element;
8
+ export default CustomList;
@@ -0,0 +1 @@
1
+ export { default } from './CustomList';
@@ -0,0 +1 @@
1
+ export { default } from './AsyncSelectField';
@@ -0,0 +1,5 @@
1
+ import { SelectOptions } from '../SelectField/types';
2
+ export declare type AsyncSelectOptions<T> = {
3
+ options: SelectOptions<T>;
4
+ hasMore: boolean;
5
+ };
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import type { Props as TextFieldProps } from '../TextField/TextField';
3
+ /**
4
+ * `CurrencyField` is like `TextField` but it auto-format the value when the user leaves the field.
5
+ *
6
+ * At the end, it is just a string formatted nicely. **You are in charge of validating the value and parsing it back to a value that you can use on your application**.
7
+ */
8
+ declare const CurrencyField: React.ForwardRefExoticComponent<TextFieldProps & {
9
+ currencySymbol: string;
10
+ } & Pick<TextFieldProps, "disabled" | "id" | "testId" | "caption" | "label" | "name" | "onFocus" | "onBlur" | "onChange" | "onKeyDown" | "error" | "value" | "placeholder" | "autoFocus" | "defaultValue" | "autoComplete" | "maxLength"> & React.RefAttributes<HTMLInputElement>>;
11
+ export default CurrencyField;
@@ -0,0 +1 @@
1
+ export { default } from './CurrencyField';
@@ -0,0 +1 @@
1
+ export declare const isEllipsisActive: (e: HTMLElement) => boolean;
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ declare type UseLabelTooltip = {
3
+ showTooltip: boolean;
4
+ shouldTruncate: boolean;
5
+ };
6
+ export declare const useLabelTooltip: (labelId: string, tooltipContent: React.ReactNode) => UseLabelTooltip;
7
+ export {};
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ import type { Props as TextFieldProps } from '../TextField/TextField';
3
+ /**
4
+ * `PercentageField` is an extended `TextField` input with validation and formatting in place to properly display percentage values.
5
+ * In its default state it only allows integers between 0 and 100, but it can be configured to allow decimals and negative values.
6
+ */
7
+ declare const PercentageField: React.ForwardRefExoticComponent<{
8
+ max?: number | undefined;
9
+ min?: number | undefined;
10
+ precision?: number | undefined;
11
+ stepSize?: number | undefined;
12
+ } & Pick<TextFieldProps, "disabled" | "id" | "testId" | "caption" | "label" | "name" | "onFocus" | "onBlur" | "onChange" | "onKeyDown" | "error" | "value" | "placeholder" | "prefix" | "autoFocus" | "defaultValue" | "autoComplete"> & React.RefAttributes<HTMLInputElement>>;
13
+ export default PercentageField;
@@ -0,0 +1 @@
1
+ export { default } from './PercentageField';
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This helper method helps to check if the user is scrolling inside the select options so,
3
+ * it does not close the menu when using the prop menuShouldScrollIntoView
4
+ **/
5
+ export declare const isScrollingTheSelectMenu: (element: HTMLElement) => boolean;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import type { Props } from './SelectField';
3
+ export declare const useSelectField: <T extends unknown>({ asToolbarFilter, caption, disabled, error, id, isClearable, label, menuShouldScrollIntoView, name, noOptionsMessage, options, onBlur, onChange, placeholder, value, defaultValue, CustomOption: UserCustomOption, SelectedOptionPrefix, testId }: Props<T>) => {
4
+ selectProps: Pick<import("react-select").Props<import("react-select").OptionTypeBase, boolean, import("react-select").GroupTypeBase<any>>, React.ReactText> & import("react-select/src/stateManager").Props<import("react-select").OptionTypeBase, boolean, import("react-select").GroupTypeBase<any>> & import("react-select").Props<import("react-select").OptionTypeBase, boolean, import("react-select").GroupTypeBase<any>>;
5
+ fieldProps: {
6
+ caption: React.ReactNode;
7
+ error: React.ReactNode;
8
+ id: string;
9
+ label: React.ReactNode;
10
+ name: string;
11
+ };
12
+ };
@@ -0,0 +1,38 @@
1
+ /// <reference types="react" />
2
+ import { RefType } from '../../utils/types';
3
+ import type { Props } from './TextField';
4
+ declare type UseTextFieldProps = Props & {
5
+ ref: RefType<HTMLInputElement>;
6
+ };
7
+ export declare const useTextField: ({ autoComplete, autoFocus, defaultValue, disabled, error, id, maxLength, name, caption, label, onBlur, onChange, onFocus, onKeyDown, placeholder, value, ref, testId }: UseTextFieldProps) => {
8
+ inputProps: {
9
+ 'aria-describedby': string;
10
+ 'aria-invalid': boolean;
11
+ autoComplete: "on" | "off" | undefined;
12
+ autoFocus: boolean | undefined;
13
+ className: string;
14
+ 'data-testid': string;
15
+ disabled: boolean | undefined;
16
+ defaultValue: string | undefined;
17
+ id: string;
18
+ maxLength: number | undefined;
19
+ name: string;
20
+ onBlur: (e: import("react").ChangeEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
21
+ onChange: (e: import("react").ChangeEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
22
+ onFocus: (e: import("react").FocusEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
23
+ onKeyDown: (e: import("react").KeyboardEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
24
+ placeholder: string | undefined;
25
+ ref: RefType<HTMLInputElement>;
26
+ size: number;
27
+ type: string;
28
+ value: string | undefined;
29
+ };
30
+ fieldProps: {
31
+ caption: import("react").ReactNode;
32
+ error: import("react").ReactNode;
33
+ label: import("react").ReactNode;
34
+ id: string;
35
+ name: string;
36
+ };
37
+ };
38
+ export {};
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ import type { Props as TextFieldProps } from '../TextField/TextField';
3
+ /**
4
+ * `TimeField` are like `TextField` but it auto-format the value when the user leaves the field.
5
+ *
6
+ * At the end, it is just a string formatted nicely. **You are in charge of validating the value and parsing it back to a value that you can use on your application**.
7
+ */
8
+ declare const TimeField: React.ForwardRefExoticComponent<Pick<TextFieldProps, "disabled" | "id" | "testId" | "caption" | "label" | "name" | "onFocus" | "onBlur" | "onChange" | "onKeyDown" | "error" | "value" | "placeholder" | "autoFocus" | "defaultValue" | "autoComplete" | "maxLength"> & React.RefAttributes<HTMLInputElement>>;
9
+ export default TimeField;
@@ -0,0 +1 @@
1
+ export { default } from './TimeField';
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconAnalytics: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconAnalytics;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconArrowDown: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconArrowDown;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconArrowLeft: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconArrowLeft;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconArrowRight: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconArrowRight;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconArrowToTop: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconArrowToTop;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconArrowUp: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconArrowUp;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconAward: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconAward;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBalanceScale: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBalanceScale;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBalanceScaleLeft: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBalanceScaleLeft;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBan: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBan;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBarsH: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBarsH;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBarsV: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBarsV;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBell: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBell;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBirthdayCake: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBirthdayCake;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBold: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBold;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBolt: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBolt;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBook: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBook;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBriefcase: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBriefcase;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconBullseyeArrow: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconBullseyeArrow;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconCalculator: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconCalculator;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconCalendar: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconCalendar;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconCalendarAlt: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconCalendarAlt;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconCalendarCheck: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconCalendarCheck;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconCalendarDay: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconCalendarDay;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { IconSize } from '../types';
3
+ declare type Props = {
4
+ size?: IconSize;
5
+ color?: string;
6
+ testId?: string;
7
+ } & React.SVGProps<SVGSVGElement>;
8
+ declare const IconCalendarExclamation: {
9
+ ({ testId, ...props }: Props): JSX.Element;
10
+ displayName: string;
11
+ };
12
+ export default IconCalendarExclamation;