@develemit/commerce-admin 0.7.0 → 0.8.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/CHANGELOG.md +61 -0
- package/README.md +7 -4
- package/dist/client/admin-client.d.ts +1 -0
- package/dist/client/errors.d.ts +4 -0
- package/dist/client/index.js +1 -1
- package/dist/{client-DCL5DSHP.js → client-ClTCzt-p.js} +34 -28
- package/dist/client-ClTCzt-p.js.map +1 -0
- package/dist/components/admin-layout/admin-layout.d.ts +2 -1
- package/dist/components/admin-layout/current-item.d.ts +1 -0
- package/dist/components/admin-layout/nav-items.d.ts +3 -0
- package/dist/components/admin-layout/use-current-href.d.ts +1 -0
- package/dist/components/empty-state/empty-state.d.ts +1 -1
- package/dist/index.js +1255 -912
- package/dist/index.js.map +1 -1
- package/dist/lib/admin-labels.d.ts +3 -0
- package/dist/lib/currency-symbol.d.ts +1 -0
- package/dist/lib/order-action-labels.d.ts +2 -0
- package/dist/lib/order-labels.d.ts +1 -1
- package/dist/lib/product-draft.d.ts +3 -0
- package/dist/lib/product-flow-labels.d.ts +9 -0
- package/dist/lib/product-labels.d.ts +8 -0
- package/dist/lib/provider.d.ts +2 -0
- package/dist/lib/stock-labels.d.ts +2 -0
- package/dist/lib/use-batch-upload.d.ts +1 -0
- package/dist/lib/use-product-autosave.d.ts +4 -0
- package/dist/lib/use-product-pages.d.ts +1 -0
- package/dist/styles.css +470 -29
- package/dist/views/orders/admin-order-detail.d.ts +2 -1
- package/dist/views/orders/order-actions.d.ts +2 -1
- package/dist/views/orders/resolve-button.d.ts +3 -1
- package/dist/views/orders/ship-form.d.ts +4 -1
- package/dist/views/products/add-several/photo-picker.d.ts +3 -1
- package/dist/views/products/admin-product-images.d.ts +2 -0
- package/dist/views/products/finish-drafts/piece-summary.d.ts +2 -1
- package/dist/views/products/finish-drafts/use-publish-pieces.d.ts +2 -0
- package/dist/views/products/product-flow/flow-actions.d.ts +3 -0
- package/dist/views/products/product-flow/flow-frame.d.ts +4 -2
- package/dist/views/products/product-flow/materials-field.d.ts +6 -0
- package/dist/views/products/product-flow/use-product-flow.d.ts +5 -0
- package/dist/views/products/product-sheet/delete-draft-button.d.ts +9 -0
- package/dist/views/shipping/shipping-rate-row.d.ts +2 -1
- package/package.json +2 -2
- package/dist/client-DCL5DSHP.js.map +0 -1
|
@@ -17,6 +17,9 @@ export interface AdminLabels {
|
|
|
17
17
|
shippingRates: string;
|
|
18
18
|
more: string;
|
|
19
19
|
closeMore: string;
|
|
20
|
+
viewShop: string;
|
|
21
|
+
badge: (count: number | string) => string;
|
|
22
|
+
productsBadge: (count: number | string) => string;
|
|
20
23
|
};
|
|
21
24
|
statuses: Record<string, string>;
|
|
22
25
|
errors: Record<AdminErrorKey, string>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function currencySymbol(currency: string, locale: string): string;
|
|
@@ -4,8 +4,11 @@ export declare function hasDraftContent(form: ProductForm): boolean;
|
|
|
4
4
|
export declare function draftInput(form: ProductForm, currency?: string): AdminProductInput;
|
|
5
5
|
export declare function draftPatch(base: AdminProduct, form: ProductForm): AdminProductPatch;
|
|
6
6
|
export declare function basicsReady(form: ProductForm): boolean;
|
|
7
|
+
export declare function basicsMissing(form: ProductForm): Array<'name' | 'price' | 'category'>;
|
|
8
|
+
export declare function titleCase(value: string): string;
|
|
7
9
|
export declare function splitMaterials(value: string): string[];
|
|
8
10
|
export declare function toggleMaterial(value: string, material: string): string;
|
|
11
|
+
export declare function mergeMaterials(picked: string[], custom: string): string;
|
|
9
12
|
export declare function appendPrompt(description: string, prompt: string): string;
|
|
10
13
|
export declare function currencySymbol(locale: string, currency: string): string;
|
|
11
14
|
export declare function fillText(template: string, values: Record<string, string>): string;
|
|
@@ -24,6 +24,15 @@ export interface ProductFlowLabels {
|
|
|
24
24
|
oneOfAKind: string;
|
|
25
25
|
howMany: string;
|
|
26
26
|
descriptionPrompts: string[];
|
|
27
|
+
descriptionPlaceholder: string;
|
|
28
|
+
sizePlaceholder: string;
|
|
29
|
+
altPlaceholder: string;
|
|
30
|
+
previewHeadingLive: string;
|
|
31
|
+
saveChanges: string;
|
|
32
|
+
seeInShop: string;
|
|
33
|
+
continueNeeds: string;
|
|
34
|
+
addPhotoTile: string;
|
|
35
|
+
stepCount: string;
|
|
27
36
|
materialsOther: string;
|
|
28
37
|
size: string;
|
|
29
38
|
altTitle: string;
|
|
@@ -10,6 +10,10 @@ export interface ProductLabels {
|
|
|
10
10
|
filters: Record<ProductFilter, string>;
|
|
11
11
|
empty: Record<ProductFilter, string>;
|
|
12
12
|
noMatches: string;
|
|
13
|
+
emptyActions: {
|
|
14
|
+
start: string;
|
|
15
|
+
clearSearch: string;
|
|
16
|
+
};
|
|
13
17
|
loadMore: string;
|
|
14
18
|
welcome: {
|
|
15
19
|
title: string;
|
|
@@ -46,6 +50,10 @@ export interface ProductLabels {
|
|
|
46
50
|
copyLink: string;
|
|
47
51
|
linkCopied: string;
|
|
48
52
|
archive: string;
|
|
53
|
+
deleteDraft: string;
|
|
54
|
+
deleteTitle: string;
|
|
55
|
+
deleteBody: string;
|
|
56
|
+
deleteConfirm: string;
|
|
49
57
|
undo: string;
|
|
50
58
|
missingTitle: string;
|
|
51
59
|
missing: Record<string, string>;
|
package/dist/lib/provider.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ export interface LinkProps {
|
|
|
7
7
|
href: string;
|
|
8
8
|
children: ReactNode;
|
|
9
9
|
className?: string;
|
|
10
|
+
'aria-current'?: 'page';
|
|
10
11
|
}
|
|
11
12
|
export interface AdminImageProps {
|
|
12
13
|
src: string;
|
|
@@ -31,6 +32,7 @@ export interface AdminConfig {
|
|
|
31
32
|
discount: (id: string) => string;
|
|
32
33
|
newDiscount: string;
|
|
33
34
|
storefrontProduct?: (slug: string) => string;
|
|
35
|
+
storefront?: string;
|
|
34
36
|
};
|
|
35
37
|
client: AdminClient | null;
|
|
36
38
|
labels: AdminLabels;
|
|
@@ -4,6 +4,7 @@ export interface StockLabels {
|
|
|
4
4
|
introTitle: string;
|
|
5
5
|
introBody: string;
|
|
6
6
|
choose: string;
|
|
7
|
+
dropHint: string;
|
|
7
8
|
progress: string;
|
|
8
9
|
failedTitle: string;
|
|
9
10
|
retry: string;
|
|
@@ -29,6 +30,7 @@ export interface StockLabels {
|
|
|
29
30
|
title: string;
|
|
30
31
|
lede: string;
|
|
31
32
|
needsDetails: string;
|
|
33
|
+
openPiece: string;
|
|
32
34
|
untitled: string;
|
|
33
35
|
publish: string;
|
|
34
36
|
keepDrafts: string;
|
|
@@ -21,6 +21,7 @@ export declare function useProductAutosave({ initial, form, currency, delayMs, }
|
|
|
21
21
|
quantity: number;
|
|
22
22
|
status: "draft" | "active" | "archived";
|
|
23
23
|
featured: boolean;
|
|
24
|
+
everPublished: boolean;
|
|
24
25
|
images: {
|
|
25
26
|
id: string;
|
|
26
27
|
url: string;
|
|
@@ -44,6 +45,7 @@ export declare function useProductAutosave({ initial, form, currency, delayMs, }
|
|
|
44
45
|
quantity: number;
|
|
45
46
|
status: "draft" | "active" | "archived";
|
|
46
47
|
featured: boolean;
|
|
48
|
+
everPublished: boolean;
|
|
47
49
|
images: {
|
|
48
50
|
id: string;
|
|
49
51
|
url: string;
|
|
@@ -64,6 +66,7 @@ export declare function useProductAutosave({ initial, form, currency, delayMs, }
|
|
|
64
66
|
quantity: number;
|
|
65
67
|
status: "draft" | "active" | "archived";
|
|
66
68
|
featured: boolean;
|
|
69
|
+
everPublished: boolean;
|
|
67
70
|
images: {
|
|
68
71
|
id: string;
|
|
69
72
|
url: string;
|
|
@@ -84,6 +87,7 @@ export declare function useProductAutosave({ initial, form, currency, delayMs, }
|
|
|
84
87
|
quantity: number;
|
|
85
88
|
status: "draft" | "active" | "archived";
|
|
86
89
|
featured: boolean;
|
|
90
|
+
everPublished: boolean;
|
|
87
91
|
images: {
|
|
88
92
|
id: string;
|
|
89
93
|
url: string;
|