@replohq/canopy-sdk 0.1.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/_vendor/replo-utils/lib/errors.d.ts +83 -0
- package/_vendor/replo-utils/lib/json.d.ts +6 -0
- package/_vendor/replo-utils/lib/misc.d.ts +128 -0
- package/_vendor/replo-utils/lib/misc.mjs +1 -0
- package/_vendor/replo-utils/lib/object.d.ts +31 -0
- package/_vendor/replo-utils/lib/parse.d.ts +15 -0
- package/_vendor/schemas/agentTools/customIntegrations/loaders/levanta.d.ts +49 -0
- package/_vendor/schemas/agentTools/customIntegrations/loaders/levanta.mjs +36 -0
- package/_vendor/schemas/agentTools/customIntegrations/loaders/product.d.ts +334 -0
- package/_vendor/schemas/agentTools/customIntegrations/loaders/product.mjs +50 -0
- package/_vendor/schemas/cart.d.ts +198 -0
- package/_vendor/schemas/cart.mjs +83 -0
- package/_vendor/schemas/errors.d.ts +428 -0
- package/_vendor/schemas/errors.mjs +955 -0
- package/_vendor/schemas/generated/errors.d.ts +61 -0
- package/_vendor/schemas/generated/selectMode.d.ts +95 -0
- package/_vendor/schemas/generated/selectMode.mjs +1 -0
- package/_vendor/schemas/loaderKeys.d.ts +39 -0
- package/_vendor/schemas/loaderKeys.mjs +23 -0
- package/_vendor/schemas/objectType.d.ts +895 -0
- package/_vendor/schemas/objectType.mjs +2 -0
- package/_vendor/schemas/registry.d.ts +243 -0
- package/_vendor/schemas/sandboxFiles.d.ts +35 -0
- package/_vendor/schemas/selectMode.d.ts +507 -0
- package/_vendor/schemas/selectMode.mjs +194 -0
- package/_vendor/schemas/sellingPlan.d.ts +60 -0
- package/_vendor/schemas/sellingPlan.mjs +1 -0
- package/analytics/analytics-provider.d.ts +13 -0
- package/analytics/analytics-provider.js +104 -0
- package/analytics/analytics-provider.js.map +7 -0
- package/analytics/analytics-sink.d.ts +20 -0
- package/analytics/analytics-sink.js +1 -0
- package/analytics/analytics-sink.js.map +7 -0
- package/analytics/hooks/use-product-viewed-analytics.d.ts +23 -0
- package/analytics/hooks/use-product-viewed-analytics.js +34 -0
- package/analytics/hooks/use-product-viewed-analytics.js.map +7 -0
- package/analytics/sinks/ga4-sink.d.ts +15 -0
- package/analytics/sinks/ga4-sink.js +52 -0
- package/analytics/sinks/ga4-sink.js.map +7 -0
- package/analytics/sinks/meta-sink.d.ts +14 -0
- package/analytics/sinks/meta-sink.js +44 -0
- package/analytics/sinks/meta-sink.js.map +7 -0
- package/analytics/sinks/pinterest-sink.d.ts +14 -0
- package/analytics/sinks/pinterest-sink.js +76 -0
- package/analytics/sinks/pinterest-sink.js.map +7 -0
- package/analytics/sinks/reddit-sink.d.ts +14 -0
- package/analytics/sinks/reddit-sink.js +80 -0
- package/analytics/sinks/reddit-sink.js.map +7 -0
- package/analytics/sinks/replo-sink.d.ts +14 -0
- package/analytics/sinks/replo-sink.js +57 -0
- package/analytics/sinks/replo-sink.js.map +7 -0
- package/analytics/sinks/snapchat-sink.d.ts +14 -0
- package/analytics/sinks/snapchat-sink.js +67 -0
- package/analytics/sinks/snapchat-sink.js.map +7 -0
- package/analytics/sinks/tiktok-sink.d.ts +14 -0
- package/analytics/sinks/tiktok-sink.js +79 -0
- package/analytics/sinks/tiktok-sink.js.map +7 -0
- package/analytics/sinks/window-sink.d.ts +18 -0
- package/analytics/sinks/window-sink.js +46 -0
- package/analytics/sinks/window-sink.js.map +7 -0
- package/analytics/utils/analytics-utils.d.ts +7 -0
- package/analytics/utils/analytics-utils.js +130 -0
- package/analytics/utils/analytics-utils.js.map +7 -0
- package/analytics/utils/navigation-tracker.d.ts +16 -0
- package/analytics/utils/navigation-tracker.js +44 -0
- package/analytics/utils/navigation-tracker.js.map +7 -0
- package/cart/buy-now-action.d.ts +21 -0
- package/cart/buy-now-action.js +104 -0
- package/cart/buy-now-action.js.map +7 -0
- package/cart/cart-actions.d.ts +63 -0
- package/cart/cart-actions.js +90 -0
- package/cart/cart-actions.js.map +7 -0
- package/cart/cart-loader.d.ts +9 -0
- package/cart/cart-loader.js +11 -0
- package/cart/cart-loader.js.map +7 -0
- package/cart/cart-provider.d.ts +85 -0
- package/cart/cart-provider.js +358 -0
- package/cart/cart-provider.js.map +7 -0
- package/cart/cart-types.d.ts +154 -0
- package/cart/cart-types.js +16 -0
- package/cart/cart-types.js.map +7 -0
- package/cart/gateways/cart-gateway.d.ts +10 -0
- package/cart/gateways/cart-gateway.js +19 -0
- package/cart/gateways/cart-gateway.js.map +7 -0
- package/cart/gateways/cookie-cart-gateway.d.ts +28 -0
- package/cart/gateways/cookie-cart-gateway.js +109 -0
- package/cart/gateways/cookie-cart-gateway.js.map +7 -0
- package/cart/gateways/default-cart-gateway.d.ts +19 -0
- package/cart/gateways/default-cart-gateway.js +30 -0
- package/cart/gateways/default-cart-gateway.js.map +7 -0
- package/cart/gateways/resolver-cart-gateway.d.ts +2 -0
- package/cart/gateways/resolver-cart-gateway.js +106 -0
- package/cart/gateways/resolver-cart-gateway.js.map +7 -0
- package/cart/gateways/stripe-cart-gateway.d.ts +19 -0
- package/cart/gateways/stripe-cart-gateway.js +28 -0
- package/cart/gateways/stripe-cart-gateway.js.map +7 -0
- package/cart/gateways/stripe-constants.d.ts +1 -0
- package/cart/gateways/stripe-constants.js +5 -0
- package/cart/gateways/stripe-constants.js.map +7 -0
- package/cart/hooks/use-add-to-cart.d.ts +63 -0
- package/cart/hooks/use-add-to-cart.js +120 -0
- package/cart/hooks/use-add-to-cart.js.map +7 -0
- package/cart/hooks/use-buy-now.d.ts +49 -0
- package/cart/hooks/use-buy-now.js +62 -0
- package/cart/hooks/use-buy-now.js.map +7 -0
- package/cart/utils/cart-utils.d.ts +31 -0
- package/cart/utils/cart-utils.js +48 -0
- package/cart/utils/cart-utils.js.map +7 -0
- package/cart/utils/cookie-cart-persistence.d.ts +55 -0
- package/cart/utils/cookie-cart-persistence.js +153 -0
- package/cart/utils/cookie-cart-persistence.js.map +7 -0
- package/cart/utils/variant-to-cart-line.d.ts +124 -0
- package/cart/utils/variant-to-cart-line.js +202 -0
- package/cart/utils/variant-to-cart-line.js.map +7 -0
- package/chunk-46YU2W6T.mjs +538 -0
- package/chunk-4TZVNC3W.mjs +33 -0
- package/chunk-INHK6MYI.mjs +1598 -0
- package/editor/ClientErrorBoundary.d.ts +7 -0
- package/editor/ClientErrorBoundary.js +48 -0
- package/editor/ClientErrorBoundary.js.map +7 -0
- package/editor/LinkInterceptor.d.ts +1 -0
- package/editor/LinkInterceptor.js +124 -0
- package/editor/LinkInterceptor.js.map +7 -0
- package/editor/posthog-relay.d.ts +10 -0
- package/editor/posthog-relay.js +60 -0
- package/editor/posthog-relay.js.map +7 -0
- package/editor/select-mode/EditorSelection.d.ts +24 -0
- package/editor/select-mode/EditorSelection.js +34 -0
- package/editor/select-mode/EditorSelection.js.map +7 -0
- package/editor/select-mode/descriptor/elementDescriptor.d.ts +15 -0
- package/editor/select-mode/descriptor/elementDescriptor.js +213 -0
- package/editor/select-mode/descriptor/elementDescriptor.js.map +7 -0
- package/editor/select-mode/fiber.d.ts +52 -0
- package/editor/select-mode/fiber.js +269 -0
- package/editor/select-mode/fiber.js.map +7 -0
- package/editor/select-mode/hooks/useCrosshairCursor.d.ts +12 -0
- package/editor/select-mode/hooks/useCrosshairCursor.js +20 -0
- package/editor/select-mode/hooks/useCrosshairCursor.js.map +7 -0
- package/editor/select-mode/hooks/useParentMessaging.d.ts +24 -0
- package/editor/select-mode/hooks/useParentMessaging.js +33 -0
- package/editor/select-mode/hooks/useParentMessaging.js.map +7 -0
- package/editor/select-mode/hooks/useSelectModeController.d.ts +8 -0
- package/editor/select-mode/hooks/useSelectModeController.js +49 -0
- package/editor/select-mode/hooks/useSelectModeController.js.map +7 -0
- package/editor/select-mode/hooks/useSelectionHover.d.ts +22 -0
- package/editor/select-mode/hooks/useSelectionHover.js +98 -0
- package/editor/select-mode/hooks/useSelectionHover.js.map +7 -0
- package/editor/select-mode/hooks/useSelectionInteractions.d.ts +32 -0
- package/editor/select-mode/hooks/useSelectionInteractions.js +293 -0
- package/editor/select-mode/hooks/useSelectionInteractions.js.map +7 -0
- package/editor/select-mode/hooks/useSelectionScrollSync.d.ts +28 -0
- package/editor/select-mode/hooks/useSelectionScrollSync.js +77 -0
- package/editor/select-mode/hooks/useSelectionScrollSync.js.map +7 -0
- package/editor/select-mode/interactions/selectionGeometry.d.ts +80 -0
- package/editor/select-mode/interactions/selectionGeometry.js +160 -0
- package/editor/select-mode/interactions/selectionGeometry.js.map +7 -0
- package/editor/select-mode/selectModeSession.d.ts +21 -0
- package/editor/select-mode/selectModeSession.js +7 -0
- package/editor/select-mode/selectModeSession.js.map +7 -0
- package/editor/select-mode/selectionFrame.d.ts +48 -0
- package/editor/select-mode/selectionFrame.js +74 -0
- package/editor/select-mode/selectionFrame.js.map +7 -0
- package/editor/select-mode/symbolicate.d.ts +3 -0
- package/editor/select-mode/symbolicate.js +139 -0
- package/editor/select-mode/symbolicate.js.map +7 -0
- package/env.d.ts +13 -0
- package/env.js +20 -0
- package/env.js.map +7 -0
- package/gateways/canopy-api.d.ts +84 -0
- package/gateways/canopy-api.js +203 -0
- package/gateways/canopy-api.js.map +7 -0
- package/hooks/use-client-value.d.ts +10 -0
- package/hooks/use-client-value.js +12 -0
- package/hooks/use-client-value.js.map +7 -0
- package/hooks/use-formatted-price.d.ts +15 -0
- package/hooks/use-formatted-price.js +19 -0
- package/hooks/use-formatted-price.js.map +7 -0
- package/lib/get-query-client.d.ts +2 -0
- package/lib/get-query-client.js +34 -0
- package/lib/get-query-client.js.map +7 -0
- package/lib/integration-utils.d.ts +2 -0
- package/lib/integration-utils.js +9 -0
- package/lib/integration-utils.js.map +7 -0
- package/lib/shopify-utils.d.ts +16 -0
- package/lib/shopify-utils.js +11 -0
- package/lib/shopify-utils.js.map +7 -0
- package/lib/url-utils.d.ts +4 -0
- package/lib/url-utils.js +8 -0
- package/lib/url-utils.js.map +7 -0
- package/loaders/collection-loader.d.ts +11 -0
- package/loaders/collection-loader.js +53 -0
- package/loaders/collection-loader.js.map +7 -0
- package/loaders/collection-products-loader.d.ts +12 -0
- package/loaders/collection-products-loader.js +56 -0
- package/loaders/collection-products-loader.js.map +7 -0
- package/loaders/invoke-loader-action.d.ts +11 -0
- package/loaders/invoke-loader-action.js +14 -0
- package/loaders/invoke-loader-action.js.map +7 -0
- package/loaders/invoke-loader-server.d.ts +18 -0
- package/loaders/invoke-loader-server.js +35 -0
- package/loaders/invoke-loader-server.js.map +7 -0
- package/loaders/invoke-loader.d.ts +14 -0
- package/loaders/invoke-loader.js +36 -0
- package/loaders/invoke-loader.js.map +7 -0
- package/loaders/levanta-product-loader.d.ts +11 -0
- package/loaders/levanta-product-loader.js +53 -0
- package/loaders/levanta-product-loader.js.map +7 -0
- package/loaders/loader-error-boundary.d.ts +25 -0
- package/loaders/loader-error-boundary.js +24 -0
- package/loaders/loader-error-boundary.js.map +7 -0
- package/loaders/okendo-review-aggregate-loader.d.ts +17 -0
- package/loaders/okendo-review-aggregate-loader.js +56 -0
- package/loaders/okendo-review-aggregate-loader.js.map +7 -0
- package/loaders/okendo-reviews-loader.d.ts +23 -0
- package/loaders/okendo-reviews-loader.js +54 -0
- package/loaders/okendo-reviews-loader.js.map +7 -0
- package/loaders/prefetch-loaders.d.ts +33 -0
- package/loaders/prefetch-loaders.js +46 -0
- package/loaders/prefetch-loaders.js.map +7 -0
- package/loaders/product-loader.d.ts +11 -0
- package/loaders/product-loader.js +53 -0
- package/loaders/product-loader.js.map +7 -0
- package/loaders/rebuy-recommendations-loader.d.ts +159 -0
- package/loaders/rebuy-recommendations-loader.js +57 -0
- package/loaders/rebuy-recommendations-loader.js.map +7 -0
- package/loaders/smile-earning-rules-loader.d.ts +19 -0
- package/loaders/smile-earning-rules-loader.js +44 -0
- package/loaders/smile-earning-rules-loader.js.map +7 -0
- package/loaders/smile-rewards-loader.d.ts +19 -0
- package/loaders/smile-rewards-loader.js +44 -0
- package/loaders/smile-rewards-loader.js.map +7 -0
- package/loaders/smile-vip-tiers-loader.d.ts +18 -0
- package/loaders/smile-vip-tiers-loader.js +43 -0
- package/loaders/smile-vip-tiers-loader.js.map +7 -0
- package/package.json +29 -0
- package/providers/query-provider.d.ts +1 -0
- package/providers/query-provider.js +12 -0
- package/providers/query-provider.js.map +7 -0
- package/providers/replo-provider.d.ts +1 -0
- package/providers/replo-provider.js +20 -0
- package/providers/replo-provider.js.map +7 -0
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
export type ErrorUserFacingDetailsWithMessage = {
|
|
2
|
+
type: "toast" | "fullPageModal" | "shopifyStorePassword" | "billing.addPublishedElements" | "billing.addShopifyThemeProject" | "billing.addReploSite" | "agentBilling.shopifyThemeBuilder.publishedElements.exceeded" | "agentBilling.shopifyThemeBuilder.projects.exceeded" | "agentBilling.sites.exceeded" | "agentBilling.credits.exceeded" | "agentBilling.upgradeRequired";
|
|
3
|
+
message: string;
|
|
4
|
+
isRecoverable?: boolean;
|
|
5
|
+
detail?: string[] | string;
|
|
6
|
+
key: string;
|
|
7
|
+
usage?: {
|
|
8
|
+
current: number;
|
|
9
|
+
maximum: number;
|
|
10
|
+
};
|
|
11
|
+
plan?: string;
|
|
12
|
+
callToAction?: {
|
|
13
|
+
type: "reload";
|
|
14
|
+
} | {
|
|
15
|
+
type: "installApp";
|
|
16
|
+
} | {
|
|
17
|
+
type: "goToHomepage";
|
|
18
|
+
} | {
|
|
19
|
+
type: "navigateToProjectEditor";
|
|
20
|
+
} | {
|
|
21
|
+
type: "closeModal";
|
|
22
|
+
} | {
|
|
23
|
+
type: "navigateToLink";
|
|
24
|
+
link: {
|
|
25
|
+
type: "errors.wrongJsonExtension";
|
|
26
|
+
} | {
|
|
27
|
+
type: "errors.chunkingError";
|
|
28
|
+
} | {
|
|
29
|
+
type: "errors.indexBackupError";
|
|
30
|
+
} | {
|
|
31
|
+
type: "errors.shopifyIntegrationAlreadyAssigned";
|
|
32
|
+
} | {
|
|
33
|
+
type: "errors.shopifyIntegrationMissingAccessScopes";
|
|
34
|
+
url: string;
|
|
35
|
+
} | {
|
|
36
|
+
type: "customLink";
|
|
37
|
+
url: string;
|
|
38
|
+
} | {
|
|
39
|
+
type: "errors.projectConnectedToBillingIntegrationForShopifyWorkspace";
|
|
40
|
+
} | {
|
|
41
|
+
type: "errors.themeAssetSizeLimitExceeded";
|
|
42
|
+
} | {
|
|
43
|
+
type: "errors.themeTotalSizeLimitExceeded";
|
|
44
|
+
} | {
|
|
45
|
+
type: "errors.pageMetafieldDefinitionsChanged";
|
|
46
|
+
} | {
|
|
47
|
+
type: "settings.billing";
|
|
48
|
+
};
|
|
49
|
+
};
|
|
50
|
+
};
|
|
51
|
+
export type ErrorUserFacingDetails = ErrorUserFacingDetailsWithMessage | {
|
|
52
|
+
type: "uncommon_none";
|
|
53
|
+
key: string;
|
|
54
|
+
usage?: {
|
|
55
|
+
current: number;
|
|
56
|
+
maximum: number;
|
|
57
|
+
};
|
|
58
|
+
message?: string;
|
|
59
|
+
isRecoverable?: boolean;
|
|
60
|
+
detail?: string[] | string;
|
|
61
|
+
};
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
export type DisplayMode = "browse" | "selection";
|
|
2
|
+
export type SelectModeSelectionType = "none" | "element" | "area" | "drag";
|
|
3
|
+
export type SelectModeTextMetrics = {
|
|
4
|
+
tightWidth: number;
|
|
5
|
+
lineCount: number;
|
|
6
|
+
lineHeight: number;
|
|
7
|
+
};
|
|
8
|
+
export type SelectModeClickPosition = {
|
|
9
|
+
x: number;
|
|
10
|
+
y: number;
|
|
11
|
+
};
|
|
12
|
+
export type SelectModeSourceLocation = {
|
|
13
|
+
filePath: string;
|
|
14
|
+
lineNumber: number;
|
|
15
|
+
columnNumber?: number;
|
|
16
|
+
componentName?: string;
|
|
17
|
+
};
|
|
18
|
+
export type SelectModeBoundingRect = {
|
|
19
|
+
x: number;
|
|
20
|
+
y: number;
|
|
21
|
+
left: number;
|
|
22
|
+
top: number;
|
|
23
|
+
right: number;
|
|
24
|
+
bottom: number;
|
|
25
|
+
width: number;
|
|
26
|
+
height: number;
|
|
27
|
+
};
|
|
28
|
+
export type SelectedElement = {
|
|
29
|
+
kind: "react-element";
|
|
30
|
+
selector: string;
|
|
31
|
+
tagName: string;
|
|
32
|
+
elementType: string;
|
|
33
|
+
textContent: string | null;
|
|
34
|
+
rect: SelectModeBoundingRect;
|
|
35
|
+
textMetrics: SelectModeTextMetrics | null;
|
|
36
|
+
outerHTML: string;
|
|
37
|
+
clickPosition: SelectModeClickPosition;
|
|
38
|
+
sourceLocation?: SelectModeSourceLocation;
|
|
39
|
+
};
|
|
40
|
+
export type SelectablePlanData = {
|
|
41
|
+
kind: "plan";
|
|
42
|
+
planId: string;
|
|
43
|
+
label: string;
|
|
44
|
+
rect: SelectModeBoundingRect;
|
|
45
|
+
};
|
|
46
|
+
export type SelectablePlanPayload = {
|
|
47
|
+
kind: "plan";
|
|
48
|
+
planId: string;
|
|
49
|
+
label: string;
|
|
50
|
+
};
|
|
51
|
+
export type SelectableDataPayload = SelectablePlanPayload;
|
|
52
|
+
export type SelectableData = SelectedElement | SelectablePlanData;
|
|
53
|
+
export type SelectModeSelection = {
|
|
54
|
+
type: "none";
|
|
55
|
+
} | {
|
|
56
|
+
type: "element";
|
|
57
|
+
data: SelectableData;
|
|
58
|
+
} | {
|
|
59
|
+
type: "area";
|
|
60
|
+
rect: SelectModeBoundingRect;
|
|
61
|
+
items: SelectableData[];
|
|
62
|
+
} | {
|
|
63
|
+
type: "drag";
|
|
64
|
+
rect: SelectModeBoundingRect;
|
|
65
|
+
};
|
|
66
|
+
export type SelectModeParentMessage = {
|
|
67
|
+
type: "replo:select:setDisplayMode";
|
|
68
|
+
displayMode: DisplayMode;
|
|
69
|
+
} | {
|
|
70
|
+
type: "replo:select:setSelectionType";
|
|
71
|
+
selectionType: SelectModeSelectionType;
|
|
72
|
+
};
|
|
73
|
+
export type SelectModeIframeMessage = {
|
|
74
|
+
type: "replo:select:elementSelected";
|
|
75
|
+
data: SelectableData;
|
|
76
|
+
} | {
|
|
77
|
+
type: "replo:select:hoverElement";
|
|
78
|
+
rect: SelectModeBoundingRect | null;
|
|
79
|
+
} | {
|
|
80
|
+
type: "replo:select:iframeReady";
|
|
81
|
+
} | {
|
|
82
|
+
type: "replo:select:selectedElementRectUpdate";
|
|
83
|
+
rect: SelectModeBoundingRect;
|
|
84
|
+
clickPosition: SelectModeClickPosition;
|
|
85
|
+
} | {
|
|
86
|
+
type: "replo:select:selectedAreaRectUpdate";
|
|
87
|
+
rect: SelectModeBoundingRect;
|
|
88
|
+
} | {
|
|
89
|
+
type: "replo:select:dragRectUpdated";
|
|
90
|
+
rect: SelectModeBoundingRect | null;
|
|
91
|
+
} | {
|
|
92
|
+
type: "replo:select:areaSelected";
|
|
93
|
+
rect: SelectModeBoundingRect;
|
|
94
|
+
items: SelectableData[];
|
|
95
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
/**
|
|
3
|
+
* Shared data-loader key constants. Both the integration registry and the
|
|
4
|
+
* dependency resolver import from here so the strings are never duplicated.
|
|
5
|
+
*
|
|
6
|
+
* These keys serve double duty: they identify which backend loader to invoke
|
|
7
|
+
* AND are used as React Query cache key prefixes. Loader components
|
|
8
|
+
* internally construct queryKey as `[loaderKey, args]`.
|
|
9
|
+
*
|
|
10
|
+
* Naming convention: `<integration>.<objectType>` or
|
|
11
|
+
* `<integration>.<objectType>_<qualifier>`.
|
|
12
|
+
*/
|
|
13
|
+
export declare const DATA_LOADER_KEYS: {
|
|
14
|
+
readonly SHOPIFY_PRODUCT: "shopify_storefront.product";
|
|
15
|
+
readonly SHOPIFY_COLLECTION: "shopify_storefront.collection";
|
|
16
|
+
readonly SHOPIFY_COLLECTION_PRODUCTS: "shopify_storefront.collection_products";
|
|
17
|
+
readonly REPLO_PRODUCT: "replo_products.product";
|
|
18
|
+
readonly OKENDO_PRODUCT_REVIEWS: "okendo.product_reviews";
|
|
19
|
+
readonly OKENDO_PRODUCT_REVIEW_AGGREGATE: "okendo.product_review_aggregate";
|
|
20
|
+
readonly REBUY_RECOMMENDATIONS: "rebuy.recommendations";
|
|
21
|
+
readonly LEVANTA_PRODUCT: "levanta_products.product";
|
|
22
|
+
readonly SMILE_IO_VIP_TIERS: "smile_io.vip_tiers";
|
|
23
|
+
readonly SMILE_IO_EARNING_RULES: "smile_io.earning_rules";
|
|
24
|
+
readonly SMILE_IO_REWARDS: "smile_io.rewards";
|
|
25
|
+
};
|
|
26
|
+
export type DataLoaderKey = (typeof DATA_LOADER_KEYS)[keyof typeof DATA_LOADER_KEYS];
|
|
27
|
+
export declare const dataLoaderKeySchema: z.ZodEnum<{
|
|
28
|
+
"shopify_storefront.product": "shopify_storefront.product";
|
|
29
|
+
"shopify_storefront.collection": "shopify_storefront.collection";
|
|
30
|
+
"shopify_storefront.collection_products": "shopify_storefront.collection_products";
|
|
31
|
+
"replo_products.product": "replo_products.product";
|
|
32
|
+
"okendo.product_reviews": "okendo.product_reviews";
|
|
33
|
+
"okendo.product_review_aggregate": "okendo.product_review_aggregate";
|
|
34
|
+
"rebuy.recommendations": "rebuy.recommendations";
|
|
35
|
+
"levanta_products.product": "levanta_products.product";
|
|
36
|
+
"smile_io.vip_tiers": "smile_io.vip_tiers";
|
|
37
|
+
"smile_io.earning_rules": "smile_io.earning_rules";
|
|
38
|
+
"smile_io.rewards": "smile_io.rewards";
|
|
39
|
+
}>;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
// ../schemas/loaderKeys.ts
|
|
4
|
+
var DATA_LOADER_KEYS = {
|
|
5
|
+
SHOPIFY_PRODUCT: "shopify_storefront.product",
|
|
6
|
+
SHOPIFY_COLLECTION: "shopify_storefront.collection",
|
|
7
|
+
SHOPIFY_COLLECTION_PRODUCTS: "shopify_storefront.collection_products",
|
|
8
|
+
REPLO_PRODUCT: "replo_products.product",
|
|
9
|
+
OKENDO_PRODUCT_REVIEWS: "okendo.product_reviews",
|
|
10
|
+
OKENDO_PRODUCT_REVIEW_AGGREGATE: "okendo.product_review_aggregate",
|
|
11
|
+
REBUY_RECOMMENDATIONS: "rebuy.recommendations",
|
|
12
|
+
LEVANTA_PRODUCT: "levanta_products.product",
|
|
13
|
+
SMILE_IO_VIP_TIERS: "smile_io.vip_tiers",
|
|
14
|
+
SMILE_IO_EARNING_RULES: "smile_io.earning_rules",
|
|
15
|
+
SMILE_IO_REWARDS: "smile_io.rewards"
|
|
16
|
+
};
|
|
17
|
+
var dataLoaderKeySchema = z.enum(
|
|
18
|
+
// Legacy cast - may or may not be necessary
|
|
19
|
+
// eslint-disable-next-line replo/no-as-cast
|
|
20
|
+
Object.values(DATA_LOADER_KEYS)
|
|
21
|
+
);
|
|
22
|
+
|
|
23
|
+
export { DATA_LOADER_KEYS, dataLoaderKeySchema };
|