@86d-app/products 0.0.3 → 0.0.6
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/.turbo/turbo-build.log +1 -0
- package/AGENTS.md +41 -41
- package/README.md +267 -7
- package/dist/__tests__/controllers.test.d.ts +2 -0
- package/dist/__tests__/controllers.test.d.ts.map +1 -0
- package/dist/__tests__/endpoint-security.test.d.ts +2 -0
- package/dist/__tests__/endpoint-security.test.d.ts.map +1 -0
- package/dist/__tests__/service-impl.test.d.ts +2 -0
- package/dist/__tests__/service-impl.test.d.ts.map +1 -0
- package/dist/__tests__/state.test.d.ts +2 -0
- package/dist/__tests__/state.test.d.ts.map +1 -0
- package/dist/admin/components/categories-admin.d.ts +2 -0
- package/dist/admin/components/categories-admin.d.ts.map +1 -0
- package/dist/admin/components/category-form.d.ts +7 -0
- package/dist/admin/components/category-form.d.ts.map +1 -0
- package/dist/admin/components/category-list.d.ts +7 -0
- package/dist/admin/components/category-list.d.ts.map +1 -0
- package/dist/admin/components/collections-admin.d.ts +2 -0
- package/dist/admin/components/collections-admin.d.ts.map +1 -0
- package/dist/admin/components/index.d.ts +9 -0
- package/dist/admin/components/index.d.ts.map +1 -0
- package/dist/admin/components/product-detail.d.ts +7 -0
- package/dist/admin/components/product-detail.d.ts.map +1 -0
- package/dist/admin/components/product-edit.d.ts +6 -0
- package/dist/admin/components/product-edit.d.ts.map +1 -0
- package/dist/admin/components/product-form.d.ts +7 -0
- package/dist/admin/components/product-form.d.ts.map +1 -0
- package/dist/admin/components/product-list.d.ts +2 -0
- package/dist/admin/components/product-list.d.ts.map +1 -0
- package/dist/admin/components/product-new.d.ts +2 -0
- package/dist/admin/components/product-new.d.ts.map +1 -0
- package/dist/admin/endpoints/add-collection-product.d.ts +15 -0
- package/dist/admin/endpoints/add-collection-product.d.ts.map +1 -0
- package/dist/admin/endpoints/bulk-action.d.ts +17 -0
- package/dist/admin/endpoints/bulk-action.d.ts.map +1 -0
- package/dist/admin/endpoints/create-category.d.ts +23 -0
- package/dist/admin/endpoints/create-category.d.ts.map +1 -0
- package/dist/admin/endpoints/create-collection.d.ts +22 -0
- package/dist/admin/endpoints/create-collection.d.ts.map +1 -0
- package/dist/admin/endpoints/create-product.d.ts +44 -0
- package/dist/admin/endpoints/create-product.d.ts.map +1 -0
- package/dist/admin/endpoints/create-variant.d.ts +35 -0
- package/dist/admin/endpoints/create-variant.d.ts.map +1 -0
- package/dist/admin/endpoints/delete-category.d.ts +18 -0
- package/dist/admin/endpoints/delete-category.d.ts.map +1 -0
- package/dist/admin/endpoints/delete-collection.d.ts +8 -0
- package/dist/admin/endpoints/delete-collection.d.ts.map +1 -0
- package/dist/admin/endpoints/delete-product.d.ts +18 -0
- package/dist/admin/endpoints/delete-product.d.ts.map +1 -0
- package/dist/admin/endpoints/delete-variant.d.ts +18 -0
- package/dist/admin/endpoints/delete-variant.d.ts.map +1 -0
- package/dist/admin/endpoints/get-product.d.ts +16 -0
- package/dist/admin/endpoints/get-product.d.ts.map +1 -0
- package/dist/admin/endpoints/import-products.d.ts +36 -0
- package/dist/admin/endpoints/import-products.d.ts.map +1 -0
- package/dist/admin/endpoints/index.d.ts +418 -0
- package/dist/admin/endpoints/index.d.ts.map +1 -0
- package/dist/admin/endpoints/list-categories.d.ts +11 -0
- package/dist/admin/endpoints/list-categories.d.ts.map +1 -0
- package/dist/admin/endpoints/list-collections.d.ts +11 -0
- package/dist/admin/endpoints/list-collections.d.ts.map +1 -0
- package/dist/admin/endpoints/list-products.d.ts +27 -0
- package/dist/admin/endpoints/list-products.d.ts.map +1 -0
- package/dist/admin/endpoints/remove-collection-product.d.ts +9 -0
- package/dist/admin/endpoints/remove-collection-product.d.ts.map +1 -0
- package/dist/admin/endpoints/update-category.d.ts +26 -0
- package/dist/admin/endpoints/update-category.d.ts.map +1 -0
- package/dist/admin/endpoints/update-collection.d.ts +19 -0
- package/dist/admin/endpoints/update-collection.d.ts.map +1 -0
- package/dist/admin/endpoints/update-product.d.ts +47 -0
- package/dist/admin/endpoints/update-product.d.ts.map +1 -0
- package/dist/admin/endpoints/update-variant.d.ts +35 -0
- package/dist/admin/endpoints/update-variant.d.ts.map +1 -0
- package/dist/controllers.d.ts +130 -0
- package/dist/controllers.d.ts.map +1 -0
- package/dist/index.d.ts +20 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/markdown.d.ts +6 -0
- package/dist/markdown.d.ts.map +1 -0
- package/dist/schema.d.ts +351 -0
- package/dist/schema.d.ts.map +1 -0
- package/dist/service-impl.d.ts +4 -0
- package/dist/service-impl.d.ts.map +1 -0
- package/dist/service.d.ts +280 -0
- package/dist/service.d.ts.map +1 -0
- package/dist/state.d.ts +38 -0
- package/dist/state.d.ts.map +1 -0
- package/dist/store/components/_hooks.d.ts +88 -0
- package/dist/store/components/_hooks.d.ts.map +1 -0
- package/dist/store/components/_types.d.ts +70 -0
- package/dist/store/components/_types.d.ts.map +1 -0
- package/dist/store/components/_utils.d.ts +5 -0
- package/dist/store/components/_utils.d.ts.map +1 -0
- package/dist/store/components/back-in-stock-notify.d.ts +8 -0
- package/dist/store/components/back-in-stock-notify.d.ts.map +1 -0
- package/dist/store/components/collection-card.d.ts +6 -0
- package/dist/store/components/collection-card.d.ts.map +1 -0
- package/dist/store/components/collection-detail.d.ts +6 -0
- package/dist/store/components/collection-detail.d.ts.map +1 -0
- package/dist/store/components/collection-grid.d.ts +6 -0
- package/dist/store/components/collection-grid.d.ts.map +1 -0
- package/dist/store/components/featured-products.d.ts +6 -0
- package/dist/store/components/featured-products.d.ts.map +1 -0
- package/dist/store/components/filter-chip.d.ts +6 -0
- package/dist/store/components/filter-chip.d.ts.map +1 -0
- package/dist/store/components/index.d.ts +37 -0
- package/dist/store/components/index.d.ts.map +1 -0
- package/dist/store/components/product-card.d.ts +7 -0
- package/dist/store/components/product-card.d.ts.map +1 -0
- package/dist/store/components/product-detail.d.ts +6 -0
- package/dist/store/components/product-detail.d.ts.map +1 -0
- package/dist/store/components/product-listing.d.ts +7 -0
- package/dist/store/components/product-listing.d.ts.map +1 -0
- package/dist/store/components/product-qa-section.d.ts +5 -0
- package/dist/store/components/product-qa-section.d.ts.map +1 -0
- package/dist/store/components/product-reviews-section.d.ts +5 -0
- package/dist/store/components/product-reviews-section.d.ts.map +1 -0
- package/dist/store/components/recently-viewed.d.ts +12 -0
- package/dist/store/components/recently-viewed.d.ts.map +1 -0
- package/dist/store/components/recommended-products.d.ts +7 -0
- package/dist/store/components/recommended-products.d.ts.map +1 -0
- package/dist/store/components/related-products.d.ts +7 -0
- package/dist/store/components/related-products.d.ts.map +1 -0
- package/dist/store/components/star-display.d.ts +6 -0
- package/dist/store/components/star-display.d.ts.map +1 -0
- package/dist/store/components/star-picker.d.ts +6 -0
- package/dist/store/components/star-picker.d.ts.map +1 -0
- package/dist/store/components/stock-badge.d.ts +5 -0
- package/dist/store/components/stock-badge.d.ts.map +1 -0
- package/dist/store/endpoints/get-category.d.ts +22 -0
- package/dist/store/endpoints/get-category.d.ts.map +1 -0
- package/dist/store/endpoints/get-collection.d.ts +17 -0
- package/dist/store/endpoints/get-collection.d.ts.map +1 -0
- package/dist/store/endpoints/get-featured.d.ts +10 -0
- package/dist/store/endpoints/get-featured.d.ts.map +1 -0
- package/dist/store/endpoints/get-product.d.ts +17 -0
- package/dist/store/endpoints/get-product.d.ts.map +1 -0
- package/dist/store/endpoints/get-related.d.ts +11 -0
- package/dist/store/endpoints/get-related.d.ts.map +1 -0
- package/dist/store/endpoints/index.d.ts +130 -0
- package/dist/store/endpoints/index.d.ts.map +1 -0
- package/dist/store/endpoints/list-categories.d.ts +6 -0
- package/dist/store/endpoints/list-categories.d.ts.map +1 -0
- package/dist/store/endpoints/list-collections.d.ts +10 -0
- package/dist/store/endpoints/list-collections.d.ts.map +1 -0
- package/dist/store/endpoints/list-products.d.ts +26 -0
- package/dist/store/endpoints/list-products.d.ts.map +1 -0
- package/dist/store/endpoints/search-products.d.ts +12 -0
- package/dist/store/endpoints/search-products.d.ts.map +1 -0
- package/dist/store/endpoints/store-search.d.ts +18 -0
- package/dist/store/endpoints/store-search.d.ts.map +1 -0
- package/package.json +3 -3
- package/src/__tests__/endpoint-security.test.ts +457 -0
- package/src/__tests__/service-impl.test.ts +1745 -0
- package/src/admin/endpoints/create-category.ts +5 -2
- package/src/admin/endpoints/create-collection.ts +1 -1
- package/src/admin/endpoints/create-product.ts +5 -2
- package/src/admin/endpoints/delete-category.ts +1 -1
- package/src/admin/endpoints/delete-collection.ts +1 -1
- package/src/admin/endpoints/delete-product.ts +1 -1
- package/src/admin/endpoints/delete-variant.ts +1 -1
- package/src/admin/endpoints/list-categories.ts +1 -1
- package/src/admin/endpoints/list-collections.ts +1 -1
- package/src/admin/endpoints/list-products.ts +1 -1
- package/src/admin/endpoints/remove-collection-product.ts +1 -1
- package/src/admin/endpoints/update-category.ts +5 -2
- package/src/admin/endpoints/update-collection.ts +1 -1
- package/src/admin/endpoints/update-product.ts +5 -2
- package/src/admin/endpoints/update-variant.ts +1 -1
- package/src/service-impl.ts +1139 -0
- package/src/service.ts +312 -0
- package/src/store/components/_hooks.ts +81 -0
- package/src/store/components/_utils.ts +8 -0
- package/src/store/components/collection-detail.tsx +21 -1
- package/src/store/components/collection-grid.tsx +5 -1
- package/src/store/components/featured-products.tsx +5 -1
- package/src/store/components/index.tsx +2 -0
- package/src/store/components/product-card.mdx +1 -1
- package/src/store/components/product-card.tsx +25 -5
- package/src/store/components/product-detail.mdx +2 -0
- package/src/store/components/product-detail.tsx +55 -8
- package/src/store/components/product-listing.tsx +25 -4
- package/src/store/components/product-qa-section.mdx +21 -0
- package/src/store/components/product-qa-section.tsx +503 -0
- package/src/store/components/recommended-products.mdx +6 -0
- package/src/store/components/recommended-products.tsx +119 -0
- package/src/store/endpoints/get-category.ts +2 -2
- package/src/store/endpoints/get-collection.ts +1 -1
- package/src/store/endpoints/get-featured.ts +1 -1
- package/src/store/endpoints/get-product.ts +1 -1
- package/src/store/endpoints/get-related.ts +2 -2
- package/src/store/endpoints/list-collections.ts +3 -3
- package/src/store/endpoints/list-products.ts +9 -9
- package/src/store/endpoints/store-search.ts +1 -1
- package/COMPONENTS.md +0 -231
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"product-detail.d.ts","sourceRoot":"","sources":["../../../src/store/components/product-detail.tsx"],"names":[],"mappings":"AA2BA,MAAM,WAAW,kBAAkB;IAClC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAChC;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,kBAAkB,+BAsftD"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export interface ProductListingProps {
|
|
2
|
+
initialCategory?: string;
|
|
3
|
+
initialSearch?: string;
|
|
4
|
+
pageSize?: number;
|
|
5
|
+
}
|
|
6
|
+
export declare function ProductListing({ initialCategory, initialSearch, pageSize, }: ProductListingProps): import("react").JSX.Element;
|
|
7
|
+
//# sourceMappingURL=product-listing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"product-listing.d.ts","sourceRoot":"","sources":["../../../src/store/components/product-listing.tsx"],"names":[],"mappings":"AASA,MAAM,WAAW,mBAAmB;IACnC,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,wBAAgB,cAAc,CAAC,EAC9B,eAAoB,EACpB,aAAkB,EAClB,QAAa,GACb,EAAE,mBAAmB,+BAwarB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"product-qa-section.d.ts","sourceRoot":"","sources":["../../../src/store/components/product-qa-section.tsx"],"names":[],"mappings":"AAqDA,MAAM,WAAW,qBAAqB;IACrC,SAAS,EAAE,MAAM,CAAC;CAClB;AAED,wBAAgB,gBAAgB,CAAC,EAAE,SAAS,EAAE,EAAE,qBAAqB,+BA8PpE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"product-reviews-section.d.ts","sourceRoot":"","sources":["../../../src/store/components/product-reviews-section.tsx"],"names":[],"mappings":"AAYA,MAAM,WAAW,0BAA0B;IAC1C,SAAS,EAAE,MAAM,CAAC;CAClB;AAED,wBAAgB,qBAAqB,CAAC,EACrC,SAAS,GACT,EAAE,0BAA0B,+BAiW5B"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export interface RecentlyViewedProductsProps {
|
|
2
|
+
/** Current product ID to exclude from the list. */
|
|
3
|
+
excludeProductId?: string;
|
|
4
|
+
/** Maximum items to show (default: 6). */
|
|
5
|
+
limit?: number;
|
|
6
|
+
/** Section title (default: "Recently viewed"). */
|
|
7
|
+
title?: string;
|
|
8
|
+
/** Analytics session ID for anonymous visitors. */
|
|
9
|
+
sessionId?: string;
|
|
10
|
+
}
|
|
11
|
+
export declare function RecentlyViewedProducts({ excludeProductId, limit, title, sessionId, }: RecentlyViewedProductsProps): import("react").JSX.Element | null;
|
|
12
|
+
//# sourceMappingURL=recently-viewed.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recently-viewed.d.ts","sourceRoot":"","sources":["../../../src/store/components/recently-viewed.tsx"],"names":[],"mappings":"AAcA,MAAM,WAAW,2BAA2B;IAC3C,mDAAmD;IACnD,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,0CAA0C;IAC1C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,kDAAkD;IAClD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,mDAAmD;IACnD,SAAS,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,wBAAgB,sBAAsB,CAAC,EACtC,gBAAgB,EAChB,KAAS,EACT,KAAyB,EACzB,SAAS,GACT,EAAE,2BAA2B,sCAqE7B"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export interface RecommendedProductsProps {
|
|
2
|
+
productId: string;
|
|
3
|
+
limit?: number;
|
|
4
|
+
title?: string;
|
|
5
|
+
}
|
|
6
|
+
export declare function RecommendedProducts({ productId, limit, title, }: RecommendedProductsProps): import("react").JSX.Element | null;
|
|
7
|
+
//# sourceMappingURL=recommended-products.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recommended-products.d.ts","sourceRoot":"","sources":["../../../src/store/components/recommended-products.tsx"],"names":[],"mappings":"AAgBA,MAAM,WAAW,wBAAwB;IACxC,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;CACf;AAED,wBAAgB,mBAAmB,CAAC,EACnC,SAAS,EACT,KAAS,EACT,KAA6B,GAC7B,EAAE,wBAAwB,sCA4F1B"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export interface RelatedProductsProps {
|
|
2
|
+
productId: string;
|
|
3
|
+
limit?: number;
|
|
4
|
+
title?: string;
|
|
5
|
+
}
|
|
6
|
+
export declare function RelatedProducts({ productId, limit, title, }: RelatedProductsProps): import("react").JSX.Element | null;
|
|
7
|
+
//# sourceMappingURL=related-products.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"related-products.d.ts","sourceRoot":"","sources":["../../../src/store/components/related-products.tsx"],"names":[],"mappings":"AAMA,MAAM,WAAW,oBAAoB;IACpC,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;CACf;AAED,wBAAgB,eAAe,CAAC,EAC/B,SAAS,EACT,KAAS,EACT,KAA6B,GAC7B,EAAE,oBAAoB,sCA6CtB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"star-display.d.ts","sourceRoot":"","sources":["../../../src/store/components/star-display.tsx"],"names":[],"mappings":"AAIA,MAAM,WAAW,gBAAgB;IAChC,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;CAC1B;AAED,wBAAgB,WAAW,CAAC,EAAE,MAAM,EAAE,IAAW,EAAE,EAAE,gBAAgB,+BAiBpE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"star-picker.d.ts","sourceRoot":"","sources":["../../../src/store/components/star-picker.tsx"],"names":[],"mappings":"AAKA,MAAM,WAAW,eAAe;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;CAC9B;AAED,wBAAgB,UAAU,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,eAAe,+BAU9D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stock-badge.d.ts","sourceRoot":"","sources":["../../../src/store/components/stock-badge.tsx"],"names":[],"mappings":"AAIA,MAAM,WAAW,eAAe;IAC/B,SAAS,EAAE,MAAM,CAAC;CAClB;AAED,wBAAgB,UAAU,CAAC,EAAE,SAAS,EAAE,EAAE,eAAe,+BAUxD"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { z } from "@86d-app/core";
|
|
2
|
+
import type { Category } from "../../controllers";
|
|
3
|
+
export declare const getCategory: import("better-call").StrictEndpoint<"/categories/:id", {
|
|
4
|
+
method: "GET";
|
|
5
|
+
params: z.ZodObject<{
|
|
6
|
+
id: z.ZodString;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
query: z.ZodOptional<z.ZodObject<{
|
|
9
|
+
includeProducts: z.ZodOptional<z.ZodString>;
|
|
10
|
+
}, z.core.$strip>>;
|
|
11
|
+
}, {
|
|
12
|
+
error: string;
|
|
13
|
+
status: number;
|
|
14
|
+
category?: never;
|
|
15
|
+
products?: never;
|
|
16
|
+
} | {
|
|
17
|
+
category: Category;
|
|
18
|
+
products: unknown[] | undefined;
|
|
19
|
+
error?: never;
|
|
20
|
+
status?: never;
|
|
21
|
+
}>;
|
|
22
|
+
//# sourceMappingURL=get-category.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-category.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/get-category.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,CAAC,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,KAAK,EAAE,QAAQ,EAAW,MAAM,mBAAmB,CAAC;AAE3D,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;EAyDvB,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { z } from "@86d-app/core";
|
|
2
|
+
import type { CollectionWithProducts } from "../../controllers";
|
|
3
|
+
export declare const getCollection: import("better-call").StrictEndpoint<"/collections/:id", {
|
|
4
|
+
method: "GET";
|
|
5
|
+
params: z.ZodObject<{
|
|
6
|
+
id: z.ZodString;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
}, {
|
|
9
|
+
error: string;
|
|
10
|
+
status: number;
|
|
11
|
+
collection?: never;
|
|
12
|
+
} | {
|
|
13
|
+
collection: CollectionWithProducts;
|
|
14
|
+
error?: never;
|
|
15
|
+
status?: never;
|
|
16
|
+
}>;
|
|
17
|
+
//# sourceMappingURL=get-collection.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-collection.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/get-collection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,CAAC,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,KAAK,EAAc,sBAAsB,EAAE,MAAM,mBAAmB,CAAC;AAE5E,eAAO,MAAM,aAAa;;;;;;;;;;;;;EA0CzB,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { z } from "@86d-app/core";
|
|
2
|
+
export declare const getFeaturedProducts: import("better-call").StrictEndpoint<"/products/featured", {
|
|
3
|
+
method: "GET";
|
|
4
|
+
query: z.ZodOptional<z.ZodObject<{
|
|
5
|
+
limit: z.ZodOptional<z.ZodString>;
|
|
6
|
+
}, z.core.$strip>>;
|
|
7
|
+
}, {
|
|
8
|
+
products: unknown;
|
|
9
|
+
}>;
|
|
10
|
+
//# sourceMappingURL=get-featured.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-featured.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/get-featured.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,CAAC,EAAE,MAAM,eAAe,CAAC;AAEvD,eAAO,MAAM,mBAAmB;;;;;;;EAe/B,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { z } from "@86d-app/core";
|
|
2
|
+
import type { ProductWithVariants } from "../../controllers";
|
|
3
|
+
export declare const getProduct: import("better-call").StrictEndpoint<"/products/:id", {
|
|
4
|
+
method: "GET";
|
|
5
|
+
params: z.ZodObject<{
|
|
6
|
+
id: z.ZodString;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
}, {
|
|
9
|
+
error: string;
|
|
10
|
+
status: number;
|
|
11
|
+
product?: never;
|
|
12
|
+
} | {
|
|
13
|
+
product: ProductWithVariants;
|
|
14
|
+
error?: never;
|
|
15
|
+
status?: never;
|
|
16
|
+
}>;
|
|
17
|
+
//# sourceMappingURL=get-product.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-product.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/get-product.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,CAAC,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,KAAK,EAAW,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAEtE,eAAO,MAAM,UAAU;;;;;;;;;;;;;EAgDtB,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { z } from "@86d-app/core";
|
|
2
|
+
export declare const getRelatedProducts: import("better-call").StrictEndpoint<"/products/:id/related", {
|
|
3
|
+
method: "GET";
|
|
4
|
+
params: z.ZodObject<{
|
|
5
|
+
id: z.ZodString;
|
|
6
|
+
}, z.core.$strip>;
|
|
7
|
+
query: z.ZodOptional<z.ZodObject<{
|
|
8
|
+
limit: z.ZodOptional<z.ZodString>;
|
|
9
|
+
}, z.core.$strip>>;
|
|
10
|
+
}, unknown>;
|
|
11
|
+
//# sourceMappingURL=get-related.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-related.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/get-related.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,CAAC,EAAE,MAAM,eAAe,CAAC;AAEvD,eAAO,MAAM,kBAAkB;;;;;;;;WAiB9B,CAAC"}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
export declare const storeEndpoints: {
|
|
2
|
+
"/products": import("better-call").StrictEndpoint<"/products", {
|
|
3
|
+
method: "GET";
|
|
4
|
+
query: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
5
|
+
page: import("zod").ZodOptional<import("zod").ZodString>;
|
|
6
|
+
limit: import("zod").ZodOptional<import("zod").ZodString>;
|
|
7
|
+
category: import("zod").ZodOptional<import("zod").ZodString>;
|
|
8
|
+
featured: import("zod").ZodOptional<import("zod").ZodString>;
|
|
9
|
+
search: import("zod").ZodOptional<import("zod").ZodString>;
|
|
10
|
+
sort: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
11
|
+
createdAt: "createdAt";
|
|
12
|
+
name: "name";
|
|
13
|
+
price: "price";
|
|
14
|
+
updatedAt: "updatedAt";
|
|
15
|
+
}>>;
|
|
16
|
+
order: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
17
|
+
asc: "asc";
|
|
18
|
+
desc: "desc";
|
|
19
|
+
}>>;
|
|
20
|
+
minPrice: import("zod").ZodOptional<import("zod").ZodString>;
|
|
21
|
+
maxPrice: import("zod").ZodOptional<import("zod").ZodString>;
|
|
22
|
+
inStock: import("zod").ZodOptional<import("zod").ZodString>;
|
|
23
|
+
tag: import("zod").ZodOptional<import("zod").ZodString>;
|
|
24
|
+
}, import("zod/v4/core").$strip>>;
|
|
25
|
+
}, unknown>;
|
|
26
|
+
"/products/featured": import("better-call").StrictEndpoint<"/products/featured", {
|
|
27
|
+
method: "GET";
|
|
28
|
+
query: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
29
|
+
limit: import("zod").ZodOptional<import("zod").ZodString>;
|
|
30
|
+
}, import("zod/v4/core").$strip>>;
|
|
31
|
+
}, {
|
|
32
|
+
products: unknown;
|
|
33
|
+
}>;
|
|
34
|
+
"/products/search": import("better-call").StrictEndpoint<"/products/search", {
|
|
35
|
+
method: "GET";
|
|
36
|
+
query: import("zod").ZodObject<{
|
|
37
|
+
q: import("zod").ZodString;
|
|
38
|
+
limit: import("zod").ZodOptional<import("zod").ZodString>;
|
|
39
|
+
}, import("zod/v4/core").$strip>;
|
|
40
|
+
}, {
|
|
41
|
+
products: unknown;
|
|
42
|
+
query: string;
|
|
43
|
+
}>;
|
|
44
|
+
"/products/store-search": import("better-call").StrictEndpoint<"/products/store-search", {
|
|
45
|
+
method: "GET";
|
|
46
|
+
query: import("zod").ZodObject<{
|
|
47
|
+
q: import("zod").ZodString;
|
|
48
|
+
limit: import("zod").ZodOptional<import("zod").ZodString>;
|
|
49
|
+
}, import("zod/v4/core").$strip>;
|
|
50
|
+
}, {
|
|
51
|
+
results: {
|
|
52
|
+
id: string;
|
|
53
|
+
label: string;
|
|
54
|
+
href: string;
|
|
55
|
+
image?: string;
|
|
56
|
+
subtitle?: string;
|
|
57
|
+
group?: string;
|
|
58
|
+
}[];
|
|
59
|
+
}>;
|
|
60
|
+
"/products/:id": import("better-call").StrictEndpoint<"/products/:id", {
|
|
61
|
+
method: "GET";
|
|
62
|
+
params: import("zod").ZodObject<{
|
|
63
|
+
id: import("zod").ZodString;
|
|
64
|
+
}, import("zod/v4/core").$strip>;
|
|
65
|
+
}, {
|
|
66
|
+
error: string;
|
|
67
|
+
status: number;
|
|
68
|
+
product?: never;
|
|
69
|
+
} | {
|
|
70
|
+
product: import("../../controllers").ProductWithVariants;
|
|
71
|
+
error?: never;
|
|
72
|
+
status?: never;
|
|
73
|
+
}>;
|
|
74
|
+
"/products/:id/related": import("better-call").StrictEndpoint<"/products/:id/related", {
|
|
75
|
+
method: "GET";
|
|
76
|
+
params: import("zod").ZodObject<{
|
|
77
|
+
id: import("zod").ZodString;
|
|
78
|
+
}, import("zod/v4/core").$strip>;
|
|
79
|
+
query: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
80
|
+
limit: import("zod").ZodOptional<import("zod").ZodString>;
|
|
81
|
+
}, import("zod/v4/core").$strip>>;
|
|
82
|
+
}, unknown>;
|
|
83
|
+
"/categories": import("better-call").StrictEndpoint<"/categories", {
|
|
84
|
+
method: "GET";
|
|
85
|
+
}, {
|
|
86
|
+
categories: unknown;
|
|
87
|
+
}>;
|
|
88
|
+
"/categories/:id": import("better-call").StrictEndpoint<"/categories/:id", {
|
|
89
|
+
method: "GET";
|
|
90
|
+
params: import("zod").ZodObject<{
|
|
91
|
+
id: import("zod").ZodString;
|
|
92
|
+
}, import("zod/v4/core").$strip>;
|
|
93
|
+
query: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
94
|
+
includeProducts: import("zod").ZodOptional<import("zod").ZodString>;
|
|
95
|
+
}, import("zod/v4/core").$strip>>;
|
|
96
|
+
}, {
|
|
97
|
+
error: string;
|
|
98
|
+
status: number;
|
|
99
|
+
category?: never;
|
|
100
|
+
products?: never;
|
|
101
|
+
} | {
|
|
102
|
+
category: import("../../controllers").Category;
|
|
103
|
+
products: unknown[] | undefined;
|
|
104
|
+
error?: never;
|
|
105
|
+
status?: never;
|
|
106
|
+
}>;
|
|
107
|
+
"/collections": import("better-call").StrictEndpoint<"/collections", {
|
|
108
|
+
method: "GET";
|
|
109
|
+
query: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
110
|
+
page: import("zod").ZodOptional<import("zod").ZodString>;
|
|
111
|
+
limit: import("zod").ZodOptional<import("zod").ZodString>;
|
|
112
|
+
featured: import("zod").ZodOptional<import("zod").ZodString>;
|
|
113
|
+
}, import("zod/v4/core").$strip>>;
|
|
114
|
+
}, unknown>;
|
|
115
|
+
"/collections/:id": import("better-call").StrictEndpoint<"/collections/:id", {
|
|
116
|
+
method: "GET";
|
|
117
|
+
params: import("zod").ZodObject<{
|
|
118
|
+
id: import("zod").ZodString;
|
|
119
|
+
}, import("zod/v4/core").$strip>;
|
|
120
|
+
}, {
|
|
121
|
+
error: string;
|
|
122
|
+
status: number;
|
|
123
|
+
collection?: never;
|
|
124
|
+
} | {
|
|
125
|
+
collection: import("../../controllers").CollectionWithProducts;
|
|
126
|
+
error?: never;
|
|
127
|
+
status?: never;
|
|
128
|
+
}>;
|
|
129
|
+
};
|
|
130
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/index.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAW1B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-categories.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/list-categories.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,cAAc;;;;EAU1B,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { z } from "@86d-app/core";
|
|
2
|
+
export declare const listCollections: import("better-call").StrictEndpoint<"/collections", {
|
|
3
|
+
method: "GET";
|
|
4
|
+
query: z.ZodOptional<z.ZodObject<{
|
|
5
|
+
page: z.ZodOptional<z.ZodString>;
|
|
6
|
+
limit: z.ZodOptional<z.ZodString>;
|
|
7
|
+
featured: z.ZodOptional<z.ZodString>;
|
|
8
|
+
}, z.core.$strip>>;
|
|
9
|
+
}, unknown>;
|
|
10
|
+
//# sourceMappingURL=list-collections.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-collections.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/list-collections.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,CAAC,EAAE,MAAM,eAAe,CAAC;AAEvD,eAAO,MAAM,eAAe;;;;;;;WAmB3B,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { z } from "@86d-app/core";
|
|
2
|
+
export declare const listProducts: import("better-call").StrictEndpoint<"/products", {
|
|
3
|
+
method: "GET";
|
|
4
|
+
query: z.ZodOptional<z.ZodObject<{
|
|
5
|
+
page: z.ZodOptional<z.ZodString>;
|
|
6
|
+
limit: z.ZodOptional<z.ZodString>;
|
|
7
|
+
category: z.ZodOptional<z.ZodString>;
|
|
8
|
+
featured: z.ZodOptional<z.ZodString>;
|
|
9
|
+
search: z.ZodOptional<z.ZodString>;
|
|
10
|
+
sort: z.ZodOptional<z.ZodEnum<{
|
|
11
|
+
createdAt: "createdAt";
|
|
12
|
+
name: "name";
|
|
13
|
+
price: "price";
|
|
14
|
+
updatedAt: "updatedAt";
|
|
15
|
+
}>>;
|
|
16
|
+
order: z.ZodOptional<z.ZodEnum<{
|
|
17
|
+
asc: "asc";
|
|
18
|
+
desc: "desc";
|
|
19
|
+
}>>;
|
|
20
|
+
minPrice: z.ZodOptional<z.ZodString>;
|
|
21
|
+
maxPrice: z.ZodOptional<z.ZodString>;
|
|
22
|
+
inStock: z.ZodOptional<z.ZodString>;
|
|
23
|
+
tag: z.ZodOptional<z.ZodString>;
|
|
24
|
+
}, z.core.$strip>>;
|
|
25
|
+
}, unknown>;
|
|
26
|
+
//# sourceMappingURL=list-products.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-products.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/list-products.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,CAAC,EAAE,MAAM,eAAe,CAAC;AAEvD,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;WAyBxB,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { z } from "@86d-app/core";
|
|
2
|
+
export declare const searchProducts: import("better-call").StrictEndpoint<"/products/search", {
|
|
3
|
+
method: "GET";
|
|
4
|
+
query: z.ZodObject<{
|
|
5
|
+
q: z.ZodString;
|
|
6
|
+
limit: z.ZodOptional<z.ZodString>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
}, {
|
|
9
|
+
products: unknown;
|
|
10
|
+
query: string;
|
|
11
|
+
}>;
|
|
12
|
+
//# sourceMappingURL=search-products.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-products.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/search-products.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,CAAC,EAAE,MAAM,eAAe,CAAC;AAEvD,eAAO,MAAM,cAAc;;;;;;;;;EAe1B,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { z } from "@86d-app/core";
|
|
2
|
+
export declare const storeSearch: import("better-call").StrictEndpoint<"/products/store-search", {
|
|
3
|
+
method: "GET";
|
|
4
|
+
query: z.ZodObject<{
|
|
5
|
+
q: z.ZodString;
|
|
6
|
+
limit: z.ZodOptional<z.ZodString>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
}, {
|
|
9
|
+
results: {
|
|
10
|
+
id: string;
|
|
11
|
+
label: string;
|
|
12
|
+
href: string;
|
|
13
|
+
image?: string;
|
|
14
|
+
subtitle?: string;
|
|
15
|
+
group?: string;
|
|
16
|
+
}[];
|
|
17
|
+
}>;
|
|
18
|
+
//# sourceMappingURL=store-search.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"store-search.d.ts","sourceRoot":"","sources":["../../../src/store/endpoints/store-search.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,CAAC,EAAE,MAAM,eAAe,CAAC;AAgCvD,eAAO,MAAM,WAAW;;;;;;;;YAgBjB,MAAM;eACH,MAAM;cACP,MAAM;gBACJ,MAAM;mBACH,MAAM;gBACT,MAAM;;EAkDhB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@86d-app/products",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.6",
|
|
4
4
|
"description": "Product catalog module for 86d commerce platform",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"commerce",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"url": "https://github.com/86d-app/86d.git",
|
|
17
17
|
"directory": "modules/products"
|
|
18
18
|
},
|
|
19
|
-
"homepage": "https://
|
|
19
|
+
"homepage": "https://86d.app",
|
|
20
20
|
"type": "module",
|
|
21
21
|
"exports": {
|
|
22
22
|
"./components": "./src/store/components",
|
|
@@ -43,4 +43,4 @@
|
|
|
43
43
|
"typescript": "catalog:",
|
|
44
44
|
"vitest": "catalog:vite"
|
|
45
45
|
}
|
|
46
|
-
}
|
|
46
|
+
}
|