@commercelayer/app-elements 1.9.0 → 1.9.2

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.
@@ -1,14 +1,10 @@
1
1
  /// <reference types="react" />
2
- export interface PageErrorProps {
2
+ import { type PageHeadingProps } from '../atoms/PageHeading';
3
+ export interface PageErrorProps extends Pick<PageHeadingProps, 'navigationButton'> {
3
4
  /**
4
5
  * Main page title wrapped in a h1 element
5
6
  */
6
7
  pageTitle?: string;
7
- /**
8
- * Optional callback that will be called when "go back" button is pressed
9
- * If missing, the "go back" button will not be shown
10
- */
11
- onGoBack?: () => void;
12
8
  /**
13
9
  * The name of the error to be show above the detailed message text.
14
10
  * Example: 'Not Found'
@@ -24,7 +20,7 @@ export interface PageErrorProps {
24
20
  */
25
21
  actionButton?: JSX.Element;
26
22
  }
27
- export declare function PageError({ pageTitle, onGoBack, errorName, errorDescription, actionButton, ...rest }: PageErrorProps): JSX.Element;
23
+ export declare function PageError({ pageTitle, navigationButton, errorName, errorDescription, actionButton, ...rest }: PageErrorProps): JSX.Element;
28
24
  export declare namespace PageError {
29
25
  var displayName: string;
30
26
  }
@@ -1,7 +1,7 @@
1
1
  import type { ContainerProps } from '../atoms/Container';
2
2
  import { type PageHeadingProps } from '../atoms/PageHeading';
3
3
  import { type ReactNode } from 'react';
4
- export interface PageLayoutProps extends Pick<PageHeadingProps, 'title' | 'description' | 'onGoBack' | 'actionButton' | 'gap'>, Pick<ContainerProps, 'minHeight'> {
4
+ export interface PageLayoutProps extends Pick<PageHeadingProps, 'title' | 'description' | 'navigationButton' | 'actionButton' | 'gap'>, Pick<ContainerProps, 'minHeight'> {
5
5
  /**
6
6
  * Page content
7
7
  */
@@ -10,8 +10,12 @@ export interface PageLayoutProps extends Pick<PageHeadingProps, 'title' | 'descr
10
10
  * When mode is `test`, it will render a `TEST DATA` Badge to inform user api is working in test mode.
11
11
  */
12
12
  mode?: 'test' | 'live';
13
+ /**
14
+ * Optional prop to enable scroll to top behavior on location change
15
+ */
16
+ scrollToTop?: boolean;
13
17
  }
14
- export declare function PageLayout({ title, description, onGoBack, children, actionButton, mode, gap, minHeight, ...rest }: PageLayoutProps): JSX.Element;
18
+ export declare function PageLayout({ title, description, navigationButton, children, actionButton, mode, gap, minHeight, scrollToTop, ...rest }: PageLayoutProps): JSX.Element;
15
19
  export declare namespace PageLayout {
16
20
  var displayName: string;
17
21
  }
@@ -18,7 +18,18 @@ export interface InputReadonlyProps extends InputWrapperBaseProps {
18
18
  */
19
19
  showCopyAction?: boolean;
20
20
  }
21
- export declare function InputReadonly({ value, wrapperClassName, inputClassName, showCopyAction, label, hint, feedback, ...rest }: InputReadonlyProps): JSX.Element;
22
- export declare namespace InputReadonly {
23
- var displayName: string;
24
- }
21
+ export declare const InputReadonly: import('../atoms/SkeletonTemplate').SkeletonTemplateComponent<{
22
+ value?: string | undefined;
23
+ wrapperClassName?: string | undefined;
24
+ inputClassName?: string | undefined;
25
+ showCopyAction?: boolean | undefined;
26
+ label?: string | undefined;
27
+ hint?: {
28
+ icon?: "bulb" | undefined;
29
+ text: import("react").ReactNode;
30
+ } | undefined;
31
+ feedback?: Omit<import("./InputFeedback").InputFeedbackProps, "className"> | undefined;
32
+ inline?: boolean | undefined;
33
+ delayMs?: number | undefined;
34
+ isLoading?: boolean | undefined;
35
+ }>;
@@ -8,7 +8,7 @@ export declare const ListItemDescription: import('../../atoms/SkeletonTemplate')
8
8
  }>;
9
9
  export declare const ListItemIcon: import('../../atoms/SkeletonTemplate').SkeletonTemplateComponent<{
10
10
  color: "none" | "green" | "orange" | "red" | "gray" | "teal" | "white" | "black" | undefined;
11
- icon: "download" | "package" | "settings" | "x" | "arrowBendDownRight" | "apps" | "arrowCircleDown" | "arrowClockwise" | "arrowDown" | "arrowLeft" | "arrowsLeftRight" | "arrowUpRight" | "asterisk" | "buildings" | "caretDown" | "caretRight" | "chatCircle" | "check" | "cloud" | "credentials" | "creditCard" | "eye" | "flag" | "funnel" | "github" | "google" | "home" | "hourglass" | "lifebuoy" | "magnifyingGlass" | "minus" | "minusCircle" | "pencilSimple" | "printer" | "plus" | "pulse" | "resources" | "shoppingBag" | "signOut" | "team" | "truck" | "upload" | "user" | "userCircle" | "warning" | "warningCircle" | "xCircle";
11
+ icon: "download" | "package" | "settings" | "x" | "apps" | "appWindow" | "arrowBendDownRight" | "arrowCircleDown" | "arrowClockwise" | "arrowDown" | "arrowLeft" | "arrowsLeftRight" | "arrowUpRight" | "asterisk" | "buildings" | "caretDown" | "caretRight" | "chatCircle" | "check" | "cloud" | "credentials" | "creditCard" | "eye" | "flag" | "funnel" | "github" | "globe" | "google" | "home" | "hourglass" | "lifebuoy" | "magnifyingGlass" | "minus" | "minusCircle" | "pencilSimple" | "plus" | "printer" | "pulse" | "puzzle" | "resources" | "shoppingBag" | "signOut" | "team" | "truck" | "upload" | "user" | "userCircle" | "warning" | "warningCircle" | "xCircle";
12
12
  delayMs?: number | undefined;
13
13
  isLoading?: boolean | undefined;
14
14
  }>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@commercelayer/app-elements",
3
- "version": "1.9.0",
3
+ "version": "1.9.2",
4
4
  "type": "module",
5
5
  "license": "MIT",
6
6
  "files": [