@commercelayer/app-elements 2.5.2 → 2.6.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.
- package/dist/{InputDateComponent-BM05fdrS.js → InputDateComponent-Bj8mqPi-.js} +1 -1
- package/dist/hooks/useEditMetadataOverlay.d.ts +13 -7
- package/dist/hooks/useEditTagsOverlay.d.ts +24 -0
- package/dist/{main-55uQIndh.js → main-Ba8EFW4S.js} +14746 -14672
- package/dist/main.d.ts +2 -0
- package/dist/main.js +110 -108
- package/dist/style.css +1 -1
- package/dist/ui/resources/ResourceDetails/ResourceDetails.d.ts +13 -0
- package/dist/ui/resources/ResourceDetails/index.d.ts +1 -0
- package/dist/ui/resources/ResourceMetadata/ResourceMetadata.d.ts +5 -11
- package/dist/ui/resources/ResourceMetadata/index.d.ts +1 -1
- package/dist/ui/resources/ResourceTags.d.ts +2 -13
- package/package.json +1 -1
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Resource } from '@commercelayer/sdk';
|
|
2
|
+
|
|
3
|
+
export interface ResourceDetailsProps {
|
|
4
|
+
resource: Resource;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* This component provides a listed visualization of details attributes of a given resource.
|
|
8
|
+
*/
|
|
9
|
+
export declare const ResourceDetails: import('../../atoms/SkeletonTemplate').SkeletonTemplateComponent<{
|
|
10
|
+
resource: Resource;
|
|
11
|
+
delayMs?: number | undefined;
|
|
12
|
+
isLoading?: boolean | undefined;
|
|
13
|
+
}>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { ResourceDetails, type ResourceDetailsProps } from './ResourceDetails';
|
|
@@ -1,14 +1,7 @@
|
|
|
1
|
+
import { EditMetadataOverlayProps } from '../../../hooks/useEditMetadataOverlay';
|
|
1
2
|
import { ListableResourceType } from '@commercelayer/sdk';
|
|
2
3
|
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Title shown as first line in edit overlay heading
|
|
6
|
-
*/
|
|
7
|
-
title: string;
|
|
8
|
-
/**
|
|
9
|
-
* Optional description shown as second line in edit overlay heading
|
|
10
|
-
*/
|
|
11
|
-
description?: string;
|
|
4
|
+
interface MetadataOverlay extends Omit<EditMetadataOverlayProps, 'resourceId' | 'resourceType' | 'mode'> {
|
|
12
5
|
}
|
|
13
6
|
export type ResourceMetadataMode = 'simple' | 'advanced';
|
|
14
7
|
export interface ResourceMetadataProps {
|
|
@@ -24,7 +17,7 @@ export interface ResourceMetadataProps {
|
|
|
24
17
|
/**
|
|
25
18
|
* Edit overlay configuration
|
|
26
19
|
*/
|
|
27
|
-
overlay:
|
|
20
|
+
overlay: MetadataOverlay;
|
|
28
21
|
}
|
|
29
22
|
export declare const updatableTypes: readonly ["string", "number", "boolean"];
|
|
30
23
|
export type UpdatableType = (typeof updatableTypes)[number];
|
|
@@ -41,7 +34,8 @@ export declare const ResourceMetadata: import('../../atoms/SkeletonTemplate').Sk
|
|
|
41
34
|
* Edit overlay configuration
|
|
42
35
|
*/
|
|
43
36
|
| undefined;
|
|
44
|
-
overlay:
|
|
37
|
+
overlay: MetadataOverlay;
|
|
45
38
|
delayMs?: number | undefined;
|
|
46
39
|
isLoading?: boolean | undefined;
|
|
47
40
|
}>;
|
|
41
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { ResourceMetadata, type ResourceMetadataMode, type
|
|
1
|
+
export { ResourceMetadata, type ResourceMetadataMode, type ResourceMetadataProps } from './ResourceMetadata';
|
|
@@ -1,19 +1,8 @@
|
|
|
1
|
+
import { EditTagsOverlayProps } from '../../hooks/useEditTagsOverlay';
|
|
1
2
|
import { ListableResourceType } from '@commercelayer/sdk';
|
|
2
3
|
|
|
3
4
|
type TaggableResource = Extract<ListableResourceType, 'addresses' | 'bundles' | 'customers' | 'coupons' | 'gift_cards' | 'line_items' | 'orders' | 'returns' | 'sku_options' | 'skus' | 'shipments'>;
|
|
4
|
-
interface TagsOverlay {
|
|
5
|
-
/**
|
|
6
|
-
* Title shown as first line in edit overlay heading
|
|
7
|
-
*/
|
|
8
|
-
title: string;
|
|
9
|
-
/**
|
|
10
|
-
* Optional description shown as second line in edit overlay heading
|
|
11
|
-
*/
|
|
12
|
-
description?: string;
|
|
13
|
-
/**
|
|
14
|
-
* Optional setting to define if tags app management link is to be shown in edit overlay heading
|
|
15
|
-
*/
|
|
16
|
-
showManageAction?: boolean;
|
|
5
|
+
interface TagsOverlay extends Omit<EditTagsOverlayProps, 'resourceId' | 'resourceType'> {
|
|
17
6
|
}
|
|
18
7
|
export interface ResourceTagsProps {
|
|
19
8
|
resourceType: TaggableResource;
|