@commercelayer/app-elements 1.22.1 → 1.22.3

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 (184) hide show
  1. package/dist/InputDateComponent-VMIwGyWW.js +6884 -0
  2. package/dist/dictionaries/customers.d.ts +3 -2
  3. package/dist/dictionaries/orders.d.ts +4 -3
  4. package/dist/dictionaries/promotions.d.ts +3 -2
  5. package/dist/dictionaries/returns.d.ts +4 -3
  6. package/dist/dictionaries/shipments.d.ts +4 -3
  7. package/dist/dictionaries/stockTransfers.d.ts +4 -3
  8. package/dist/dictionaries/types.d.ts +2 -1
  9. package/dist/helpers/appsNavigation.d.ts +2 -2
  10. package/dist/helpers/attachments.d.ts +3 -2
  11. package/dist/helpers/date.d.ts +2 -1
  12. package/dist/helpers/resources.d.ts +3 -2
  13. package/dist/helpers/route.d.ts +3 -2
  14. package/dist/helpers/tracking.d.ts +4 -3
  15. package/dist/hooks/useClickAway.d.ts +2 -1
  16. package/dist/hooks/useEditMetadataOverlay.d.ts +2 -2
  17. package/dist/hooks/useOverlay.d.ts +2 -2
  18. package/dist/{main-DDo6Radk.js → main-B9GWvu3Z.js} +5005 -4970
  19. package/dist/main.d.ts +1 -0
  20. package/dist/main.js +1 -1
  21. package/dist/mocks/data/countries.d.ts +1 -1
  22. package/dist/mocks/data/customers.d.ts +1 -1
  23. package/dist/mocks/handlers.d.ts +1 -1
  24. package/dist/mocks/server.d.ts +1 -1
  25. package/dist/providers/CoreSdkProvider/CoreSdkProvider.d.ts +3 -2
  26. package/dist/providers/CoreSdkProvider/makeSdkClient.d.ts +2 -1
  27. package/dist/providers/CoreSdkProvider/useCoreApi.d.ts +5 -4
  28. package/dist/providers/ErrorBoundary.d.ts +2 -1
  29. package/dist/providers/GTMProvider.d.ts +2 -2
  30. package/dist/providers/TokenProvider/MockTokenProvider.d.ts +2 -2
  31. package/dist/providers/TokenProvider/TokenProvider.d.ts +7 -6
  32. package/dist/providers/TokenProvider/getAccessTokenFromUrl.d.ts +3 -2
  33. package/dist/providers/TokenProvider/getInfoFromJwt.d.ts +2 -1
  34. package/dist/providers/TokenProvider/getOrganization.d.ts +2 -1
  35. package/dist/providers/TokenProvider/makeSdkClient.d.ts +2 -1
  36. package/dist/providers/TokenProvider/reducer.d.ts +4 -3
  37. package/dist/providers/TokenProvider/storage.d.ts +2 -1
  38. package/dist/providers/TokenProvider/types.d.ts +2 -1
  39. package/dist/providers/TokenProvider/url.d.ts +2 -1
  40. package/dist/providers/TokenProvider/validateToken.d.ts +3 -2
  41. package/dist/providers/createApp.d.ts +4 -3
  42. package/dist/style.css +1 -1
  43. package/dist/ui/atoms/A.d.ts +3 -3
  44. package/dist/ui/atoms/Avatar.d.ts +1 -1
  45. package/dist/ui/atoms/Badge/Badge.d.ts +3 -2
  46. package/dist/ui/atoms/Button.d.ts +2 -2
  47. package/dist/ui/atoms/ButtonFilter.d.ts +2 -2
  48. package/dist/ui/atoms/Card.d.ts +337 -341
  49. package/dist/ui/atoms/EmptyState.d.ts +3 -2
  50. package/dist/ui/atoms/Grid.d.ts +2 -1
  51. package/dist/ui/atoms/Hint.d.ts +3 -2
  52. package/dist/ui/atoms/Icon/Icon.d.ts +2 -1
  53. package/dist/ui/atoms/PageHeading.d.ts +3 -2
  54. package/dist/ui/atoms/RadialProgress.d.ts +3 -2
  55. package/dist/ui/atoms/ScrollToTop.d.ts +2 -1
  56. package/dist/ui/atoms/Section.d.ts +2 -1
  57. package/dist/ui/atoms/Skeleton.d.ts +2 -1
  58. package/dist/ui/atoms/SkeletonTemplate.d.ts +3 -2
  59. package/dist/ui/atoms/Spacer.d.ts +2 -1
  60. package/dist/ui/atoms/Stack.d.ts +2 -1
  61. package/dist/ui/atoms/StatusIcon.d.ts +2 -2
  62. package/dist/ui/atoms/Table/Table.d.ts +2 -1
  63. package/dist/ui/atoms/Tabs.d.ts +2 -1
  64. package/dist/ui/atoms/Tag.d.ts +3 -2
  65. package/dist/ui/atoms/Text.d.ts +2 -1
  66. package/dist/ui/atoms/Tooltip.d.ts +4 -3
  67. package/dist/ui/composite/ActionButtons/ActionButtons.d.ts +3 -2
  68. package/dist/ui/composite/Dropdown/Dropdown.d.ts +2 -2
  69. package/dist/ui/composite/Dropdown/DropdownDivider.d.ts +2 -1
  70. package/dist/ui/composite/Dropdown/DropdownItem.d.ts +338 -343
  71. package/dist/ui/composite/Dropdown/DropdownMenu.d.ts +2 -1
  72. package/dist/ui/composite/Dropdown/DropdownSearch.d.ts +1 -1
  73. package/dist/ui/composite/HomePageLayout.d.ts +3 -2
  74. package/dist/ui/composite/List.d.ts +3 -2
  75. package/dist/ui/composite/ListDetails.d.ts +2 -1
  76. package/dist/ui/composite/ListDetailsItem.d.ts +2 -1
  77. package/dist/ui/composite/ListItem.d.ts +3 -2
  78. package/dist/ui/composite/PageError.d.ts +2 -2
  79. package/dist/ui/composite/PageLayout.d.ts +4 -3
  80. package/dist/ui/composite/Report.d.ts +2 -1
  81. package/dist/ui/composite/SearchBar.d.ts +1 -1
  82. package/dist/ui/composite/TableData.d.ts +2 -2
  83. package/dist/ui/composite/Timeline.d.ts +4 -3
  84. package/dist/ui/forms/Form/HookedForm.d.ts +2 -2
  85. package/dist/ui/forms/Input/HookedInput.d.ts +2 -2
  86. package/dist/ui/forms/Input/Input.d.ts +3 -3
  87. package/dist/ui/forms/InputCheckbox/HookedInputCheckbox.d.ts +2 -2
  88. package/dist/ui/forms/InputCheckbox/InputCheckbox.d.ts +3 -3
  89. package/dist/ui/forms/InputCheckboxGroup/HookedInputCheckboxGroup.d.ts +2 -2
  90. package/dist/ui/forms/InputCheckboxGroup/InputCheckboxGroup.d.ts +4 -3
  91. package/dist/ui/forms/InputCheckboxGroup/InputCheckboxGroupItem.d.ts +3 -2
  92. package/dist/ui/forms/InputCheckboxGroup/reducer.d.ts +3 -2
  93. package/dist/ui/forms/InputCurrency/HookedInputCurrency.d.ts +2 -2
  94. package/dist/ui/forms/InputCurrency/InputCurrency.d.ts +5 -5
  95. package/dist/ui/forms/InputCurrency/utils.d.ts +2 -1
  96. package/dist/ui/forms/InputCurrencyRange.d.ts +4 -4
  97. package/dist/ui/forms/InputDate/HookedInputDate.d.ts +2 -2
  98. package/dist/ui/forms/InputDate/InputDate.d.ts +4 -4
  99. package/dist/ui/forms/InputDate/InputDateComponent.d.ts +4 -4
  100. package/dist/ui/forms/InputDateRange/HookedInputDateRange.d.ts +2 -2
  101. package/dist/ui/forms/InputDateRange/InputDateRange.d.ts +4 -4
  102. package/dist/ui/forms/InputFile.d.ts +3 -3
  103. package/dist/ui/forms/InputJson.d.ts +2 -2
  104. package/dist/ui/forms/InputRadioGroup/HookedInputRadioGroup.d.ts +2 -2
  105. package/dist/ui/forms/InputRadioGroup/InputRadioGroup.d.ts +3 -2
  106. package/dist/ui/forms/InputReadonly.d.ts +4 -4
  107. package/dist/ui/forms/InputResourceGroup/FullList.d.ts +2 -2
  108. package/dist/ui/forms/InputResourceGroup/HookedInputResourceGroup.d.ts +2 -2
  109. package/dist/ui/forms/InputResourceGroup/InputResourceGroup.d.ts +3 -3
  110. package/dist/ui/forms/InputResourceGroup/utils.d.ts +3 -2
  111. package/dist/ui/forms/InputSelect/AsyncComponent.d.ts +5 -5
  112. package/dist/ui/forms/InputSelect/HookedInputSelect.d.ts +2 -2
  113. package/dist/ui/forms/InputSelect/InputSelect.d.ts +5 -4
  114. package/dist/ui/forms/InputSelect/SelectComponent.d.ts +4 -4
  115. package/dist/ui/forms/InputSelect/overrides.d.ts +3 -3
  116. package/dist/ui/forms/InputSelect/styles.d.ts +4 -3
  117. package/dist/ui/forms/InputSelect/utils.d.ts +2 -1
  118. package/dist/ui/forms/InputSimpleSelect/HookedInputSimpleSelect.d.ts +2 -2
  119. package/dist/ui/forms/InputSimpleSelect/InputSimpleSelect.d.ts +3 -3
  120. package/dist/ui/forms/InputSpinner/HookedInputSpinner.d.ts +2 -2
  121. package/dist/ui/forms/InputSpinner/InputSpinner.d.ts +3 -3
  122. package/dist/ui/forms/InputSwitch/HookedInputSwitch.d.ts +2 -2
  123. package/dist/ui/forms/InputSwitch/InputSwitch.d.ts +3 -3
  124. package/dist/ui/forms/InputTextArea/HookedInputTextArea.d.ts +2 -2
  125. package/dist/ui/forms/InputTextArea/InputTextArea.d.ts +3 -3
  126. package/dist/ui/forms/InputToggleButton/HookedInputToggleButton.d.ts +2 -2
  127. package/dist/ui/forms/InputToggleButton/InputToggleButton.d.ts +3 -3
  128. package/dist/ui/forms/ReactHookForm/setApiFormErrors.d.ts +2 -1
  129. package/dist/ui/forms/ReactHookForm/useValidationFeedback.d.ts +2 -1
  130. package/dist/ui/internals/FlexRow.d.ts +2 -1
  131. package/dist/ui/internals/InputWrapper.d.ts +3 -3
  132. package/dist/ui/resources/ResourceAddress/ResourceAddress.d.ts +2 -1
  133. package/dist/ui/resources/ResourceAddress/ResourceAddressForm.d.ts +2 -1
  134. package/dist/ui/resources/ResourceLineItems/ResourceLineItems.d.ts +4 -3
  135. package/dist/ui/resources/ResourceLineItems/types.d.ts +2 -1
  136. package/dist/ui/resources/ResourceList/ResourceList.d.ts +7 -7
  137. package/dist/ui/resources/ResourceList/VisibilityTrigger.d.ts +2 -1
  138. package/dist/ui/resources/ResourceList/infiniteFetcher.d.ts +4 -3
  139. package/dist/ui/resources/ResourceList/metricsApiClient.d.ts +6 -5
  140. package/dist/ui/resources/ResourceList/reducer.d.ts +3 -2
  141. package/dist/ui/resources/ResourceListItem/ResourceListItem.d.ts +3 -2
  142. package/dist/ui/resources/ResourceListItem/common.d.ts +2 -1
  143. package/dist/ui/resources/ResourceListItem/transformers/customers.d.ts +3 -2
  144. package/dist/ui/resources/ResourceListItem/transformers/orders.d.ts +3 -2
  145. package/dist/ui/resources/ResourceListItem/transformers/promotions.d.ts +3 -2
  146. package/dist/ui/resources/ResourceListItem/transformers/returns.d.ts +3 -2
  147. package/dist/ui/resources/ResourceListItem/transformers/shipments.d.ts +3 -2
  148. package/dist/ui/resources/ResourceListItem/transformers/stockTransfers.d.ts +3 -2
  149. package/dist/ui/resources/ResourceListItem/types.d.ts +3 -3
  150. package/dist/ui/resources/ResourceMetadata/ResourceMetadata.d.ts +2 -1
  151. package/dist/ui/resources/ResourceMetadata/ResourceMetadataForm.d.ts +3 -2
  152. package/dist/ui/resources/ResourceMetadata/utils.d.ts +9 -0
  153. package/dist/ui/resources/ResourceMetadata/utils.test.d.ts +1 -0
  154. package/dist/ui/resources/ResourceOrderTimeline.d.ts +2 -1
  155. package/dist/ui/resources/ResourceShipmentParcels.d.ts +2 -1
  156. package/dist/ui/resources/ResourceShipmentParcels.mocks.d.ts +18 -17
  157. package/dist/ui/resources/ResourceTags.d.ts +2 -1
  158. package/dist/ui/resources/useResourceFilters/FieldCurrencyRange.d.ts +2 -2
  159. package/dist/ui/resources/useResourceFilters/FieldOptions.d.ts +2 -2
  160. package/dist/ui/resources/useResourceFilters/FieldTextSearch.d.ts +2 -2
  161. package/dist/ui/resources/useResourceFilters/FieldTimeRange.d.ts +2 -2
  162. package/dist/ui/resources/useResourceFilters/FiltersForm.d.ts +2 -2
  163. package/dist/ui/resources/useResourceFilters/FiltersNav.d.ts +2 -2
  164. package/dist/ui/resources/useResourceFilters/FiltersSearchBar.d.ts +3 -3
  165. package/dist/ui/resources/useResourceFilters/adaptFormValuesToSdk.d.ts +3 -2
  166. package/dist/ui/resources/useResourceFilters/adaptFormValuesToUrlQuery.d.ts +2 -1
  167. package/dist/ui/resources/useResourceFilters/adaptSdkToMetrics.d.ts +4 -3
  168. package/dist/ui/resources/useResourceFilters/adaptSdkToUrlQuery.d.ts +3 -2
  169. package/dist/ui/resources/useResourceFilters/adaptUrlQueryToFormValues.d.ts +2 -1
  170. package/dist/ui/resources/useResourceFilters/adaptUrlQueryToSdk.d.ts +3 -2
  171. package/dist/ui/resources/useResourceFilters/adaptUrlQueryToUrlQuery.d.ts +2 -1
  172. package/dist/ui/resources/useResourceFilters/adapters.d.ts +2 -1
  173. package/dist/ui/resources/useResourceFilters/adapters.types.d.ts +10 -9
  174. package/dist/ui/resources/useResourceFilters/mockedInstructions.d.ts +2 -1
  175. package/dist/ui/resources/useResourceFilters/timeUtils.d.ts +2 -1
  176. package/dist/ui/resources/useResourceFilters/types.d.ts +3 -2
  177. package/dist/ui/resources/useResourceFilters/useResourceFilters.d.ts +8 -8
  178. package/dist/ui/resources/useResourceFilters/utils.d.ts +2 -1
  179. package/dist/utils/children.d.ts +2 -1
  180. package/dist/utils/extractHeaders.d.ts +2 -1
  181. package/dist/utils/text.d.ts +2 -1
  182. package/dist/vendor.css +1 -1
  183. package/package.json +24 -24
  184. package/dist/InputDateComponent-B8HvJdHg.js +0 -5363
@@ -1,5 +1,6 @@
1
- import { type ReactNode } from 'react';
2
- import { type StatusIconProps } from './StatusIcon';
1
+ import { StatusIconProps } from './StatusIcon';
2
+ import { ReactNode } from 'react';
3
+
3
4
  export interface EmptyStateProps {
4
5
  title: string;
5
6
  description?: ReactNode;
@@ -1,4 +1,5 @@
1
- import React, { type ReactNode } from 'react';
1
+ import { default as React, ReactNode } from 'react';
2
+
2
3
  export interface GridProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'children'> {
3
4
  /**
4
5
  * Grid items
@@ -1,5 +1,6 @@
1
- import { type ReactNode } from 'react';
2
- import { type IconProps } from './Icon';
1
+ import { IconProps } from './Icon';
2
+ import { ReactNode } from 'react';
3
+
3
4
  export interface HintProps {
4
5
  icon?: IconProps['name'];
5
6
  className?: string;
@@ -1,5 +1,6 @@
1
- import { type ComponentPropsWithRef } from 'react';
2
1
  import { iconMapping } from './icons';
2
+ import { ComponentPropsWithRef } from 'react';
3
+
3
4
  type IconWeight = 'regular' | 'bold' | 'light';
4
5
  export interface IconProps extends ComponentPropsWithRef<'svg'> {
5
6
  /**
@@ -1,5 +1,6 @@
1
- import { type ReactNode } from 'react';
2
- import { type BadgeProps } from './Badge';
1
+ import { BadgeProps } from './Badge';
2
+ import { ReactNode } from 'react';
3
+
3
4
  export interface PageHeadingProps {
4
5
  /**
5
6
  * Main page title wrapped in a h1 element
@@ -1,5 +1,6 @@
1
- import { type SVGAttributes } from 'react';
2
- import { type StatusIconProps } from './StatusIcon';
1
+ import { StatusIconProps } from './StatusIcon';
2
+ import { SVGAttributes } from 'react';
3
+
3
4
  export interface RadialProgressProps extends SVGAttributes<SVGElement> {
4
5
  /**
5
6
  * Progress percentage express as number from 0 to 100.
@@ -1,4 +1,5 @@
1
- import { type FC } from 'react';
1
+ import { FC } from 'react';
2
+
2
3
  /**
3
4
  * This component lets the window scrolls back to top once the window.location.pathname is changed
4
5
  */
@@ -1,4 +1,5 @@
1
- import React, { type ReactNode } from 'react';
1
+ import { default as React, ReactNode } from 'react';
2
+
2
3
  export interface SectionProps {
3
4
  /** The content of the section. */
4
5
  children: React.ReactNode;
@@ -1,4 +1,5 @@
1
- import { type ReactNode } from 'react';
1
+ import { ReactNode } from 'react';
2
+
2
3
  export interface SkeletonProps {
3
4
  /**
4
5
  * This prevents Skeleton to appear immediately.
@@ -1,5 +1,6 @@
1
- import { type FC, type FunctionComponent, type ReactNode, type ReactPortal } from 'react';
2
- import { type Simplify } from 'type-fest';
1
+ import { Simplify } from 'type-fest';
2
+ import { FC, FunctionComponent, ReactNode, ReactPortal } from 'react';
3
+
3
4
  type ReactNodeNoPortal = Exclude<ReactNode, ReactPortal>;
4
5
  export type SkeletonTemplateProps<P = Record<string, unknown>> = Simplify<P & {
5
6
  /**
@@ -1,4 +1,5 @@
1
- import { type ReactNode } from 'react';
1
+ import { ReactNode } from 'react';
2
+
2
3
  export interface SpacerProps extends React.HTMLAttributes<HTMLDivElement> {
3
4
  /**
4
5
  * Value to be applied as `margin-top`
@@ -1,4 +1,5 @@
1
- import { type ReactNode } from 'react';
1
+ import { ReactNode } from 'react';
2
+
2
3
  export interface StackProps {
3
4
  children: ReactNode;
4
5
  }
@@ -1,5 +1,5 @@
1
- /// <reference types="react" />
2
- import { type iconMapping } from './Icon/icons';
1
+ import { iconMapping } from './Icon/icons';
2
+
3
3
  export interface StatusIconProps extends React.HTMLAttributes<HTMLDivElement> {
4
4
  /**
5
5
  * Name of the icon to display
@@ -1,4 +1,5 @@
1
- import React from 'react';
1
+ import { default as React } from 'react';
2
+
2
3
  export interface TableProps {
3
4
  thead?: React.ReactNode;
4
5
  tbody?: React.ReactNode;
@@ -1,4 +1,5 @@
1
- import React, { type ReactNode } from 'react';
1
+ import { default as React, ReactNode } from 'react';
2
+
2
3
  export interface TabsProps {
3
4
  /**
4
5
  * Used for accessability
@@ -1,5 +1,6 @@
1
- import { type FlexRowProps } from '../internals/FlexRow';
2
- import { type FC } from 'react';
1
+ import { FC } from 'react';
2
+ import { FlexRowProps } from '../internals/FlexRow';
3
+
3
4
  type Props = Pick<FlexRowProps, 'children'> & {
4
5
  /**
5
6
  * Icon component
@@ -1,4 +1,5 @@
1
- import { type ReactNode } from 'react';
1
+ import { ReactNode } from 'react';
2
+
2
3
  type TextVariant = 'danger' | 'success' | 'primary' | 'warning' | 'info' | 'plain' | 'disabled';
3
4
  type TextSize = 'small' | 'regular' | 'large' | 'inherit';
4
5
  type TextWeight = 'regular' | 'medium' | 'semibold' | 'bold' | 'inherit';
@@ -1,5 +1,6 @@
1
- import { type ReactNode } from 'react';
2
- import { type PlacesType, type TooltipRefProps } from 'react-tooltip';
1
+ import { PlacesType, TooltipRefProps } from 'react-tooltip';
2
+ import { ReactNode } from 'react';
3
+
3
4
  export { type TooltipRefProps } from 'react-tooltip';
4
5
  export interface TooltipProps {
5
6
  /** Tooltip unique identifier */
@@ -21,4 +22,4 @@ export interface TooltipProps {
21
22
  *
22
23
  * This component is a wrapper around react-tooltip.
23
24
  */
24
- export declare const Tooltip: import("react").ForwardRefExoticComponent<TooltipProps & import("react").RefAttributes<TooltipRefProps>>;
25
+ export declare const Tooltip: import('react').ForwardRefExoticComponent<TooltipProps & import('react').RefAttributes<TooltipRefProps>>;
@@ -1,5 +1,6 @@
1
- import { type ButtonProps } from '../../atoms/Button';
2
- import { type MouseEventHandler } from 'react';
1
+ import { MouseEventHandler } from 'react';
2
+ import { ButtonProps } from '../../atoms/Button';
3
+
3
4
  export interface ActionButtonsProps {
4
5
  actions: Array<{
5
6
  label: string;
@@ -1,5 +1,5 @@
1
- /// <reference types="react" />
2
- import { type DropdownMenuProps } from './DropdownMenu';
1
+ import { DropdownMenuProps } from './DropdownMenu';
2
+
3
3
  export interface DropdownProps extends Pick<DropdownMenuProps, 'menuHeader' | 'menuPosition'> {
4
4
  /** The trigger for the dropdown menu. Can be a JSX Element or simply a `string`. */
5
5
  dropdownLabel?: React.ReactNode;
@@ -1,4 +1,5 @@
1
- import { type FC } from 'react';
1
+ import { FC } from 'react';
2
+
2
3
  export interface DropdownDividerProps extends React.HTMLAttributes<HTMLElement> {
3
4
  children?: React.ReactNode;
4
5
  }