@haus-storefront-react/vendure-plugin-configs 1.0.4-next.7 → 1.0.4-next.8

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.
Files changed (40) hide show
  1. package/CHANGELOG.md +808 -793
  2. package/badge.js +1 -1
  3. package/badge.mjs +439 -424
  4. package/campaign.js +1 -1
  5. package/campaign.mjs +50 -106
  6. package/elastic.js +1 -1
  7. package/elastic.mjs +10 -26
  8. package/index.js +1 -1
  9. package/index.mjs +2 -4
  10. package/lib/configs/vendure-badge-plugin.d.ts +2 -2
  11. package/lib/configs/vendure-related-products-plugin.d.ts +39 -0
  12. package/lib/configs/vendure-related-products-plugin.types.d.ts +16 -0
  13. package/lib/exports/related-products.d.ts +3 -0
  14. package/lib/hooks/use-related-products.d.ts +2 -0
  15. package/package.json +13 -7
  16. package/packagesize.js +1 -1
  17. package/packagesize.mjs +15 -59
  18. package/plugin-config-DrQQb9Ry.js +1 -0
  19. package/plugin-config-DywohMgp.mjs +903 -0
  20. package/product-popularity.js +1 -1
  21. package/product-popularity.mjs +12 -22
  22. package/product-variant-specifications.js +1 -1
  23. package/product-variant-specifications.mjs +8 -18
  24. package/purchase-order-payment.js +5 -5
  25. package/purchase-order-payment.mjs +207 -631
  26. package/related-products.d.ts +2 -0
  27. package/related-products.js +1 -0
  28. package/related-products.mjs +36 -0
  29. package/src-BCHcjT-q.mjs +455 -0
  30. package/src-BqcrcEUL.mjs +2718 -0
  31. package/src-Cj3iGasO.js +6 -0
  32. package/src-CvZOxNaX.js +21 -0
  33. package/compiler-runtime-oPPev21o.js +0 -10
  34. package/compiler-runtime-qHgugrLy.mjs +0 -296
  35. package/index-BRlTlK6a.mjs +0 -3768
  36. package/index-BgBC_k8M.js +0 -1
  37. package/index-C0E-40z0.mjs +0 -19
  38. package/index-CgxqXyHf.js +0 -20
  39. package/useSdk-DOrZRSHz.mjs +0 -2634
  40. package/useSdk-YXpk8Wsi.js +0 -21
@@ -0,0 +1,2 @@
1
+ export * from './lib/exports/related-products'
2
+ export {}
@@ -0,0 +1 @@
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`}),require(`./src-Cj3iGasO.js`);const e=require(`./plugin-config-DrQQb9Ry.js`),t=require(`./src-CvZOxNaX.js`);let n=require(`@tanstack/react-query`);var r=new e.t({name:`relatedProducts`,enableFeatures:{},queryUpdates:{product:{fields:[`relatedProductIds`]},briefProducts:{fields:[`relatedProductIds`]}}});r.setRequests({relatedProducts:async e=>(await r.getSdk().createRequest({operation:`relatedProducts`,inheritFieldsFrom:`product`,variables:{input:{type:`RelatedProductsInput!`}}},{input:e},!1)).data});var i=e=>{let r=t.i();if(!r.relatedProducts)throw Error(`relatedProducts method not found in SDK. Need to register VendureRelatedProductsPlugin.`);return(0,n.useQuery)({queryKey:[`relatedProducts`,e.id,e.take,e.facetIds],queryFn:()=>r.relatedProducts(e),enabled:!!e.id})};exports.VendureRelatedProductsPlugin=r,exports.useRelatedProducts=i;
@@ -0,0 +1,36 @@
1
+ import "./src-BCHcjT-q.mjs";
2
+ import { t as e } from "./plugin-config-DywohMgp.mjs";
3
+ import { a as t } from "./src-BqcrcEUL.mjs";
4
+ import { useQuery as n } from "@tanstack/react-query";
5
+ //#region src/lib/configs/vendure-related-products-plugin.ts
6
+ var r = new e({
7
+ name: "relatedProducts",
8
+ enableFeatures: {},
9
+ queryUpdates: {
10
+ product: { fields: ["relatedProductIds"] },
11
+ briefProducts: { fields: ["relatedProductIds"] }
12
+ }
13
+ });
14
+ r.setRequests({ relatedProducts: async (e) => (await r.getSdk().createRequest({
15
+ operation: "relatedProducts",
16
+ inheritFieldsFrom: "product",
17
+ variables: { input: { type: "RelatedProductsInput!" } }
18
+ }, { input: e }, !1)).data });
19
+ //#endregion
20
+ //#region src/lib/hooks/use-related-products.ts
21
+ var i = (e) => {
22
+ let r = t();
23
+ if (!r.relatedProducts) throw Error("relatedProducts method not found in SDK. Need to register VendureRelatedProductsPlugin.");
24
+ return n({
25
+ queryKey: [
26
+ "relatedProducts",
27
+ e.id,
28
+ e.take,
29
+ e.facetIds
30
+ ],
31
+ queryFn: () => r.relatedProducts(e),
32
+ enabled: !!e.id
33
+ });
34
+ };
35
+ //#endregion
36
+ export { r as VendureRelatedProductsPlugin, i as useRelatedProducts };
@@ -0,0 +1,455 @@
1
+ import * as e from "react";
2
+ import t from "react";
3
+ //#region \0rolldown/runtime.js
4
+ var n = Object.defineProperty, r = (e, t) => () => (t || e((t = { exports: {} }).exports, t), t.exports), i = (e, t) => {
5
+ let r = {};
6
+ for (var i in e) n(r, i, {
7
+ get: e[i],
8
+ enumerable: !0
9
+ });
10
+ return t || n(r, Symbol.toStringTag, { value: "Module" }), r;
11
+ }, a = /* @__PURE__ */ ((e) => typeof require < "u" ? require : typeof Proxy < "u" ? new Proxy(e, { get: (e, t) => (typeof require < "u" ? require : e)[t] }) : e)(function(e) {
12
+ if (typeof require < "u") return require.apply(this, arguments);
13
+ throw Error("Calling `require` for \"" + e + "\" in an environment that doesn't expose the `require` function. See https://rolldown.rs/in-depth/bundling-cjs#require-external-modules for more details.");
14
+ }), o = /* @__PURE__ */ function(e) {
15
+ return e.ACTIVE_ORDER = "activeOrder", e.ACTIVE_CHANNEL = "activeChannel", e.ACTIVE_CUSTOMER = "activeCustomer", e.ACTIVE_CUSTOMER_ORDERS = "activeCustomerOrders", e.AVAILABLE_COUNTRIES = "availableCountries", e.FACETS = "facets", e.ORDER_BY_CODE = "orderByCode", e.ORDER_STATES = "orderStates", e.PRODUCT = "product", e.PAYMENT_METHODS = "paymentMethods", e.SEARCH = "search", e.SEARCH_FIELD = "searchField", e.SHIPPING_METHODS = "shippingMethods", e;
16
+ }({}), s = /* @__PURE__ */ function(e) {
17
+ return e.AlreadyLoggedInError = "ALREADY_LOGGED_IN_ERROR", e.CouponCodeExpiredError = "COUPON_CODE_EXPIRED_ERROR", e.CouponCodeInvalidError = "COUPON_CODE_INVALID_ERROR", e.CouponCodeLimitError = "COUPON_CODE_LIMIT_ERROR", e.EmailAddressConflictError = "EMAIL_ADDRESS_CONFLICT_ERROR", e.GuestCheckoutError = "GUEST_CHECKOUT_ERROR", e.IdentifierChangeTokenExpiredError = "IDENTIFIER_CHANGE_TOKEN_EXPIRED_ERROR", e.IdentifierChangeTokenInvalidError = "IDENTIFIER_CHANGE_TOKEN_INVALID_ERROR", e.IneligiblePaymentMethodError = "INELIGIBLE_PAYMENT_METHOD_ERROR", e.IneligibleShippingMethodError = "INELIGIBLE_SHIPPING_METHOD_ERROR", e.InsufficientStockError = "INSUFFICIENT_STOCK_ERROR", e.InvalidCredentialsError = "INVALID_CREDENTIALS_ERROR", e.MissingPasswordError = "MISSING_PASSWORD_ERROR", e.NativeAuthStrategyError = "NATIVE_AUTH_STRATEGY_ERROR", e.NegativeQuantityError = "NEGATIVE_QUANTITY_ERROR", e.NotVerifiedError = "NOT_VERIFIED_ERROR", e.NoActiveOrderError = "NO_ACTIVE_ORDER_ERROR", e.OrderLimitError = "ORDER_LIMIT_ERROR", e.OrderModificationError = "ORDER_MODIFICATION_ERROR", e.OrderPaymentStateError = "ORDER_PAYMENT_STATE_ERROR", e.OrderStateTransitionError = "ORDER_STATE_TRANSITION_ERROR", e.PasswordAlreadySetError = "PASSWORD_ALREADY_SET_ERROR", e.PasswordResetTokenExpiredError = "PASSWORD_RESET_TOKEN_EXPIRED_ERROR", e.PasswordResetTokenInvalidError = "PASSWORD_RESET_TOKEN_INVALID_ERROR", e.PasswordValidationError = "PASSWORD_VALIDATION_ERROR", e.PaymentDeclinedError = "PAYMENT_DECLINED_ERROR", e.PaymentFailedError = "PAYMENT_FAILED_ERROR", e.UnknownError = "UNKNOWN_ERROR", e.VerificationTokenExpiredError = "VERIFICATION_TOKEN_EXPIRED_ERROR", e.VerificationTokenInvalidError = "VERIFICATION_TOKEN_INVALID_ERROR", e;
18
+ }({}), c = /* @__PURE__ */ r(((e) => {
19
+ var t = Symbol.for("react.transitional.element"), n = Symbol.for("react.fragment");
20
+ function r(e, n, r) {
21
+ var i = null;
22
+ if (r !== void 0 && (i = "" + r), n.key !== void 0 && (i = "" + n.key), "key" in n) for (var a in r = {}, n) a !== "key" && (r[a] = n[a]);
23
+ else r = n;
24
+ return n = r.ref, {
25
+ $$typeof: t,
26
+ type: e,
27
+ key: i,
28
+ ref: n === void 0 ? null : n,
29
+ props: r
30
+ };
31
+ }
32
+ e.Fragment = n, e.jsx = r, e.jsxs = r;
33
+ })), l = /* @__PURE__ */ r(((e) => {
34
+ process.env.NODE_ENV !== "production" && (function() {
35
+ function t(e) {
36
+ if (e == null) return null;
37
+ if (typeof e == "function") return e.$$typeof === k ? null : e.displayName || e.name || null;
38
+ if (typeof e == "string") return e;
39
+ switch (e) {
40
+ case v: return "Fragment";
41
+ case b: return "Profiler";
42
+ case y: return "StrictMode";
43
+ case w: return "Suspense";
44
+ case T: return "SuspenseList";
45
+ case O: return "Activity";
46
+ }
47
+ if (typeof e == "object") switch (typeof e.tag == "number" && console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), e.$$typeof) {
48
+ case _: return "Portal";
49
+ case S: return e.displayName || "Context";
50
+ case x: return (e._context.displayName || "Context") + ".Consumer";
51
+ case C:
52
+ var n = e.render;
53
+ return e = e.displayName, e ||= (e = n.displayName || n.name || "", e === "" ? "ForwardRef" : "ForwardRef(" + e + ")"), e;
54
+ case E: return n = e.displayName || null, n === null ? t(e.type) || "Memo" : n;
55
+ case D:
56
+ n = e._payload, e = e._init;
57
+ try {
58
+ return t(e(n));
59
+ } catch {}
60
+ }
61
+ return null;
62
+ }
63
+ function n(e) {
64
+ return "" + e;
65
+ }
66
+ function r(e) {
67
+ try {
68
+ n(e);
69
+ var t = !1;
70
+ } catch {
71
+ t = !0;
72
+ }
73
+ if (t) {
74
+ t = console;
75
+ var r = t.error, i = typeof Symbol == "function" && Symbol.toStringTag && e[Symbol.toStringTag] || e.constructor.name || "Object";
76
+ return r.call(t, "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.", i), n(e);
77
+ }
78
+ }
79
+ function i(e) {
80
+ if (e === v) return "<>";
81
+ if (typeof e == "object" && e && e.$$typeof === D) return "<...>";
82
+ try {
83
+ var n = t(e);
84
+ return n ? "<" + n + ">" : "<...>";
85
+ } catch {
86
+ return "<...>";
87
+ }
88
+ }
89
+ function o() {
90
+ var e = A.A;
91
+ return e === null ? null : e.getOwner();
92
+ }
93
+ function s() {
94
+ return Error("react-stack-top-frame");
95
+ }
96
+ function c(e) {
97
+ if (j.call(e, "key")) {
98
+ var t = Object.getOwnPropertyDescriptor(e, "key").get;
99
+ if (t && t.isReactWarning) return !1;
100
+ }
101
+ return e.key !== void 0;
102
+ }
103
+ function l(e, t) {
104
+ function n() {
105
+ P || (P = !0, console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)", t));
106
+ }
107
+ n.isReactWarning = !0, Object.defineProperty(e, "key", {
108
+ get: n,
109
+ configurable: !0
110
+ });
111
+ }
112
+ function u() {
113
+ var e = t(this.type);
114
+ return F[e] || (F[e] = !0, console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")), e = this.props.ref, e === void 0 ? null : e;
115
+ }
116
+ function d(e, t, n, r, i, a) {
117
+ var o = n.ref;
118
+ return e = {
119
+ $$typeof: g,
120
+ type: e,
121
+ key: t,
122
+ props: n,
123
+ _owner: r
124
+ }, (o === void 0 ? null : o) === null ? Object.defineProperty(e, "ref", {
125
+ enumerable: !1,
126
+ value: null
127
+ }) : Object.defineProperty(e, "ref", {
128
+ enumerable: !1,
129
+ get: u
130
+ }), e._store = {}, Object.defineProperty(e._store, "validated", {
131
+ configurable: !1,
132
+ enumerable: !1,
133
+ writable: !0,
134
+ value: 0
135
+ }), Object.defineProperty(e, "_debugInfo", {
136
+ configurable: !1,
137
+ enumerable: !1,
138
+ writable: !0,
139
+ value: null
140
+ }), Object.defineProperty(e, "_debugStack", {
141
+ configurable: !1,
142
+ enumerable: !1,
143
+ writable: !0,
144
+ value: i
145
+ }), Object.defineProperty(e, "_debugTask", {
146
+ configurable: !1,
147
+ enumerable: !1,
148
+ writable: !0,
149
+ value: a
150
+ }), Object.freeze && (Object.freeze(e.props), Object.freeze(e)), e;
151
+ }
152
+ function f(e, n, i, a, s, u) {
153
+ var f = n.children;
154
+ if (f !== void 0) if (a) if (M(f)) {
155
+ for (a = 0; a < f.length; a++) p(f[a]);
156
+ Object.freeze && Object.freeze(f);
157
+ } else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
158
+ else p(f);
159
+ if (j.call(n, "key")) {
160
+ f = t(e);
161
+ var m = Object.keys(n).filter(function(e) {
162
+ return e !== "key";
163
+ });
164
+ a = 0 < m.length ? "{key: someKey, " + m.join(": ..., ") + ": ...}" : "{key: someKey}", R[f + a] || (m = 0 < m.length ? "{" + m.join(": ..., ") + ": ...}" : "{}", console.error("A props object containing a \"key\" prop is being spread into JSX:\n let props = %s;\n <%s {...props} />\nReact keys must be passed directly to JSX without using spread:\n let props = %s;\n <%s key={someKey} {...props} />", a, f, m, f), R[f + a] = !0);
165
+ }
166
+ if (f = null, i !== void 0 && (r(i), f = "" + i), c(n) && (r(n.key), f = "" + n.key), "key" in n) for (var h in i = {}, n) h !== "key" && (i[h] = n[h]);
167
+ else i = n;
168
+ return f && l(i, typeof e == "function" ? e.displayName || e.name || "Unknown" : e), d(e, f, i, o(), s, u);
169
+ }
170
+ function p(e) {
171
+ m(e) ? e._store && (e._store.validated = 1) : typeof e == "object" && e && e.$$typeof === D && (e._payload.status === "fulfilled" ? m(e._payload.value) && e._payload.value._store && (e._payload.value._store.validated = 1) : e._store && (e._store.validated = 1));
172
+ }
173
+ function m(e) {
174
+ return typeof e == "object" && !!e && e.$$typeof === g;
175
+ }
176
+ var h = a("react"), g = Symbol.for("react.transitional.element"), _ = Symbol.for("react.portal"), v = Symbol.for("react.fragment"), y = Symbol.for("react.strict_mode"), b = Symbol.for("react.profiler"), x = Symbol.for("react.consumer"), S = Symbol.for("react.context"), C = Symbol.for("react.forward_ref"), w = Symbol.for("react.suspense"), T = Symbol.for("react.suspense_list"), E = Symbol.for("react.memo"), D = Symbol.for("react.lazy"), O = Symbol.for("react.activity"), k = Symbol.for("react.client.reference"), A = h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, j = Object.prototype.hasOwnProperty, M = Array.isArray, N = console.createTask ? console.createTask : function() {
177
+ return null;
178
+ };
179
+ h = { react_stack_bottom_frame: function(e) {
180
+ return e();
181
+ } };
182
+ var P, F = {}, I = h.react_stack_bottom_frame.bind(h, s)(), L = N(i(s)), R = {};
183
+ e.Fragment = v, e.jsx = function(e, t, n) {
184
+ var r = 1e4 > A.recentlyCreatedOwnerStacks++;
185
+ return f(e, t, n, !1, r ? Error("react-stack-top-frame") : I, r ? N(i(e)) : L);
186
+ }, e.jsxs = function(e, t, n) {
187
+ var r = 1e4 > A.recentlyCreatedOwnerStacks++;
188
+ return f(e, t, n, !0, r ? Error("react-stack-top-frame") : I, r ? N(i(e)) : L);
189
+ };
190
+ })();
191
+ })), u = /* @__PURE__ */ r(((e, t) => {
192
+ process.env.NODE_ENV === "production" ? t.exports = c() : t.exports = l();
193
+ })), d = u();
194
+ function f(t) {
195
+ let n = [];
196
+ function r(r, i) {
197
+ let a = e.createContext(i), o = n.length;
198
+ n.push(a);
199
+ let s = (n) => {
200
+ let { scope: r, children: i, ...s } = n, c = r?.[t]?.[o] || a, l = e.useMemo(() => s, [s]);
201
+ return /* @__PURE__ */ (0, d.jsx)(c.Provider, {
202
+ value: l,
203
+ children: i
204
+ });
205
+ };
206
+ s.displayName = r + "Provider";
207
+ function c(n, s) {
208
+ let c = s?.[t]?.[o] || a, l = e.useContext(c);
209
+ if (l) return l;
210
+ if (i !== void 0) return i;
211
+ throw Error(`\`${n}\` must be used within \`${r}\``);
212
+ }
213
+ return [s, c];
214
+ }
215
+ function i() {
216
+ let r = n.map((t) => e.createContext(t));
217
+ return function(n) {
218
+ let i = n?.[t] || r;
219
+ return e.useMemo(() => ({ [`__scope${t}`]: {
220
+ ...n,
221
+ [t]: i
222
+ } }), [n, i]);
223
+ };
224
+ }
225
+ return i.scopeName = t, [r, i];
226
+ }
227
+ [.../* @__PURE__ */ "onClick.aria-label.aria-disabled.aria-hidden.aria-selected.aria-expanded.aria-controls.aria-describedby.aria-labelledby.aria-owns.aria-posinset.aria-setsize.aria-atomic.aria-busy.aria-current.aria-details.aria-dropeffect.aria-errormessage.aria-flowto.aria-grabbed.aria-haspopup.aria-invalid.aria-keyshortcuts.aria-live.aria-modal.aria-multiline.aria-multiselectable.aria-orientation.aria-placeholder.aria-pressed.aria-readonly.aria-relevant.aria-required.aria-roledescription.aria-rowcount.aria-rowindex.aria-rowspan.aria-sort.aria-valuemax.aria-valuemin.aria-valuenow.aria-valuetext".split(".")], [.../* @__PURE__ */ "onClick.onDoubleClick.onMouseDown.onMouseEnter.onMouseLeave.onMouseMove.onMouseOut.onMouseOver.onMouseUp.onWheel.onKeyDown.onKeyPress.onKeyUp.onFocus.onBlur.onChange.onInput.onSubmit.onReset.onSelect.onSelectStart.onSelectionChange.onInvalid.onBeforeInput.onCompositionEnd.onCompositionStart.onCompositionUpdate.onCopy.onCut.onPaste.onDrag.onDragEnd.onDragEnter.onDragExit.onDragLeave.onDragOver.onDragStart.onDrop.onScroll.onLoad.onError.onAnimationStart.onAnimationEnd.onAnimationIteration.onTransitionEnd.onGotPointerCapture.onLostPointerCapture.onPointerCancel.onPointerDown.onPointerEnter.onPointerLeave.onPointerMove.onPointerOut.onPointerOver.onPointerUp.aria-label.aria-labelledby.aria-describedby.aria-controls.aria-owns.aria-activedescendant.aria-autocomplete.aria-checked.aria-current.aria-disabled.aria-expanded.aria-haspopup.aria-hidden.aria-invalid.aria-level.aria-live.aria-modal.aria-multiline.aria-multiselectable.aria-orientation.aria-placeholder.aria-pressed.aria-readonly.aria-required.aria-selected.aria-sort.aria-valuemax.aria-valuemin.aria-valuenow.aria-valuetext.role.tabIndex.contentEditable.contextMenu.dir.draggable.dropzone.hidden.id.lang.spellCheck.style.title.translate.slot.part.class.className.dataset.innerHTML.outerHTML.accessKey.autocapitalize.autocorrect.enterKeyHint.inputMode.is.itemID.itemProp.itemRef.itemScope.itemType.nonce.popover.radioGroup.referrerPolicy.rel.security.unselectable.virtualKeyboardPolicy".split(".")];
228
+ function p(e, t) {
229
+ if (t === "web") return e;
230
+ let { src: n, alt: r, width: i, height: a, ...o } = e, s = [typeof i == "number" ? { width: i } : void 0, typeof a == "number" ? { height: a } : void 0].filter(Boolean), c;
231
+ return s.length === 1 ? c = s[0] : s.length > 1 && (c = s), {
232
+ ...o,
233
+ source: { uri: n },
234
+ ...c ? { style: c } : {}
235
+ };
236
+ }
237
+ function m(e) {
238
+ let { src: t, alt: n, ...r } = e;
239
+ return t ? {
240
+ ...r,
241
+ source: { uri: t }
242
+ } : r;
243
+ }
244
+ //#endregion
245
+ //#region ../../common/utils/src/lib/platform-primitives.tsx
246
+ var h = {
247
+ div: "View",
248
+ span: "Text",
249
+ p: "Text",
250
+ h1: "Text",
251
+ h2: "Text",
252
+ h3: "Text",
253
+ h4: "Text",
254
+ h5: "Text",
255
+ h6: "Text",
256
+ button: "Pressable",
257
+ input: "TextInput",
258
+ form: "View",
259
+ section: "View",
260
+ article: "View",
261
+ nav: "View",
262
+ header: "View",
263
+ footer: "View",
264
+ main: "View",
265
+ aside: "View",
266
+ ul: "View",
267
+ ol: "View",
268
+ li: "View",
269
+ a: "Pressable",
270
+ img: "Image",
271
+ label: "Text",
272
+ textarea: "TextInput",
273
+ select: "Pressable",
274
+ option: "Text"
275
+ };
276
+ function g(e, n) {
277
+ if (n === "web") return e;
278
+ let r = null;
279
+ try {
280
+ r = a("react-native");
281
+ } catch {
282
+ r = null;
283
+ }
284
+ if (!r) return console.warn(`react-native is not available at runtime; falling back to 'View' for '${e}'`), "div";
285
+ let i = h[e];
286
+ if (!i) return console.warn(`No native component mapping found for '${e}', falling back to View`), r.View;
287
+ if (i === "Image") {
288
+ let e = t.forwardRef((e, t) => e.src ? /* @__PURE__ */ (0, d.jsx)(r.Image, {
289
+ ref: t,
290
+ ...m(e)
291
+ }) : null);
292
+ return e.displayName = "PlatformPrimitiveImage", e;
293
+ }
294
+ return r[i] || (console.warn(`Native component '${i}' not found, falling back to View`), r.View);
295
+ }
296
+ //#endregion
297
+ //#region ../../common/utils/src/lib/slot.tsx
298
+ var _ = Symbol("radix.slottable");
299
+ function v(...e) {
300
+ return (t) => e.forEach((e) => {
301
+ typeof e == "function" ? e(t) : e != null && (e.current = t);
302
+ });
303
+ }
304
+ function y(e, t) {
305
+ let n = { ...t };
306
+ for (let r in t) {
307
+ let i = e[r], a = t[r];
308
+ /^on[A-Z]/.test(r) ? i && a ? n[r] = (...e) => {
309
+ let t = a(...e);
310
+ return i(...e), t;
311
+ } : i && (n[r] = i) : r === "style" ? n[r] = b(i, a) : r === "className" && (n[r] = [i, a].filter(Boolean).join(" "));
312
+ }
313
+ return {
314
+ ...e,
315
+ ...n
316
+ };
317
+ }
318
+ function b(e, t) {
319
+ let n = (() => {
320
+ try {
321
+ return a("react-native");
322
+ } catch {
323
+ return null;
324
+ }
325
+ })()?.StyleSheet?.flatten;
326
+ if (typeof e == "function" && typeof t == "function") return (r) => {
327
+ let i = [e(r), t(r)];
328
+ return n ? n(i) : i;
329
+ };
330
+ if (typeof e == "function") return (r) => {
331
+ let i = t ? [e(r), t] : e(r);
332
+ return n ? n(i) : i;
333
+ };
334
+ if (typeof t == "function") return (r) => {
335
+ let i = e ? [e, t(r)] : t(r);
336
+ return n ? n(i) : i;
337
+ };
338
+ let r = [e, t].filter(Boolean);
339
+ return n ? n(r) : r;
340
+ }
341
+ function x(t) {
342
+ return e.isValidElement(t) && typeof t.type == "function" && "__radixId" in t.type && t.type.__radixId === _;
343
+ }
344
+ function S(e) {
345
+ let t = Object.getOwnPropertyDescriptor(e.props, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning;
346
+ return n ? e.ref : (t = Object.getOwnPropertyDescriptor(e, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
347
+ }
348
+ function C(t, n) {
349
+ let r = e.forwardRef((t, n) => {
350
+ let { children: r, ...i } = t;
351
+ if (e.isValidElement(r)) {
352
+ let t = S(r), a = y(i, r.props);
353
+ return r.type !== e.Fragment && (a.ref = n ? v(n, t) : t), e.cloneElement(r, a);
354
+ }
355
+ return e.Children.count(r) > 1 ? e.Children.only(null) : null;
356
+ });
357
+ return r.displayName = `${t}.SlotClone`, r;
358
+ }
359
+ function w(t, n = !1, r = "div") {
360
+ if (!n) return g(r, t);
361
+ let i = C("Slot", t), a = e.forwardRef((t, n) => {
362
+ let { children: r, ...a } = t, o = e.Children.toArray(r), s = o.find(x);
363
+ if (s) {
364
+ let t = s.props.children, r = o.map((n) => n === s ? e.Children.count(t) > 1 ? e.Children.only(null) : e.isValidElement(t) ? t.props.children : null : n);
365
+ return /* @__PURE__ */ (0, d.jsx)(i, {
366
+ ...a,
367
+ ref: n,
368
+ children: e.isValidElement(t) ? e.cloneElement(t, void 0, r) : null
369
+ });
370
+ }
371
+ return /* @__PURE__ */ (0, d.jsx)(i, {
372
+ ...a,
373
+ ref: n,
374
+ children: r
375
+ });
376
+ });
377
+ return a.displayName = "Slot", a;
378
+ }
379
+ function T(e) {
380
+ let t = ({ children: e }) => e;
381
+ return t.displayName = `${e}.Slottable`, t.__radixId = _, t;
382
+ }
383
+ T("Slottable");
384
+ //#endregion
385
+ //#region ../../common/utils/src/lib/logger.ts
386
+ var E = "debug", D = () => {
387
+ try {
388
+ if (typeof window > "u" || typeof localStorage > "u") return !1;
389
+ let e = localStorage.getItem(E);
390
+ return e === "true" || e === "1";
391
+ } catch {
392
+ return !1;
393
+ }
394
+ }, O = (() => {
395
+ let e = (e, t, n = []) => t ? typeof e == "string" ? [`<${t}> ${e}`, ...n] : [
396
+ `<${t}>`,
397
+ e,
398
+ ...n
399
+ ] : Array.isArray(e) ? [...e, ...n] : [e, ...n];
400
+ return {
401
+ log: (t, n, ...r) => {
402
+ D() && console.log(...e(t, n, r));
403
+ },
404
+ info: (t, n, ...r) => {
405
+ D() && console.info(...e(t, n, r));
406
+ },
407
+ warn: (t, n, ...r) => {
408
+ D() && console.warn(...e(t, n, r));
409
+ },
410
+ error: (t, n, ...r) => {
411
+ D() && console.error(...e(t, n, r));
412
+ },
413
+ debug: (t, n, ...r) => {
414
+ D() && console.debug(...e(t, n, r));
415
+ },
416
+ group: (e, t) => {
417
+ if (D()) {
418
+ let n = typeof e == "string" ? e : void 0;
419
+ t ? console.group(n ? `<${t}> ${n}` : `<${t}>`) : console.group(n);
420
+ }
421
+ },
422
+ groupCollapsed: (e, t) => {
423
+ if (D()) {
424
+ let n = typeof e == "string" ? e : void 0;
425
+ t ? console.groupCollapsed(n ? `<${t}> ${n}` : `<${t}>`) : console.groupCollapsed(n);
426
+ }
427
+ },
428
+ groupEnd: () => {
429
+ D() && console.groupEnd();
430
+ },
431
+ table: (e, t, n) => {
432
+ D() && (t && console.log(`<${t}>`), console.table(e, n));
433
+ },
434
+ time: (e, t) => {
435
+ if (D()) {
436
+ let n = typeof e == "string" ? e : void 0;
437
+ t ? console.time(n ? `<${t}> ${n}` : `<${t}>`) : console.time(n);
438
+ }
439
+ },
440
+ timeEnd: (e, t) => {
441
+ if (D()) {
442
+ let n = typeof e == "string" ? e : void 0;
443
+ t ? console.timeEnd(n ? `<${t}> ${n}` : `<${t}>`) : console.timeEnd(n);
444
+ }
445
+ }
446
+ };
447
+ })(), k = (e) => e == null ? 0 : typeof e == "number" ? e : "value" in e ? e.value : "min" in e ? e.min : 0, A = (e) => {
448
+ let t = e.map((e) => k(e.price)), n = Math.min(...t), r = Math.max(...t);
449
+ return n === void 0 || r === void 0 ? { value: 0 } : n === r ? { value: n } : {
450
+ min: n,
451
+ max: r
452
+ };
453
+ }, j = (e, t) => typeof e == "function" ? e(t) : e;
454
+ //#endregion
455
+ export { w as a, u as c, r as d, i as f, O as i, s as l, A as n, p as o, a as p, j as r, f as s, k as t, o as u };