@instockng/storefront-ui 1.0.56 → 1.0.58

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 (274) hide show
  1. package/dist/components/ProductAddOns.d.ts +1 -2
  2. package/dist/components/ProductAddOns.d.ts.map +1 -1
  3. package/dist/components/ProductCard.d.ts +1 -1
  4. package/dist/components/ProductCard.d.ts.map +1 -1
  5. package/dist/index.d.ts +4 -0
  6. package/dist/index.d.ts.map +1 -1
  7. package/dist/index.mjs +104 -100
  8. package/dist/index10.mjs +147 -91
  9. package/dist/index100.mjs +43 -2
  10. package/dist/index101.mjs +2 -28
  11. package/dist/index102.mjs +2 -18
  12. package/dist/index103.mjs +26 -213
  13. package/dist/index104.mjs +13 -175
  14. package/dist/index105.mjs +210 -17
  15. package/dist/index106.mjs +174 -17
  16. package/dist/index107.mjs +14 -25
  17. package/dist/index108.mjs +17 -150
  18. package/dist/index109.mjs +26 -13
  19. package/dist/index11.mjs +95 -171
  20. package/dist/index110.mjs +149 -24
  21. package/dist/index111.mjs +13 -77
  22. package/dist/index112.mjs +20 -27
  23. package/dist/index113.mjs +76 -137
  24. package/dist/index114.mjs +33 -50
  25. package/dist/index115.mjs +141 -19
  26. package/dist/index116.mjs +50 -22
  27. package/dist/index117.mjs +14 -14
  28. package/dist/index118.mjs +20 -18
  29. package/dist/index119.mjs +16 -14
  30. package/dist/index12.mjs +90 -90
  31. package/dist/index120.mjs +17 -14
  32. package/dist/index121.mjs +12 -12
  33. package/dist/index122.mjs +15 -58
  34. package/dist/index123.mjs +14 -11
  35. package/dist/index124.mjs +56 -30
  36. package/dist/index125.mjs +9 -15
  37. package/dist/index126.mjs +31 -26
  38. package/dist/index127.mjs +13 -16
  39. package/dist/index128.mjs +26 -11
  40. package/dist/index129.mjs +17 -11
  41. package/dist/index13.mjs +162 -717
  42. package/dist/index130.mjs +12 -40
  43. package/dist/index131.mjs +14 -16
  44. package/dist/index132.mjs +42 -263
  45. package/dist/index133.mjs +15 -62
  46. package/dist/index134.mjs +267 -7
  47. package/dist/index135.mjs +70 -2
  48. package/dist/index136.mjs +8 -2
  49. package/dist/index137.mjs +2 -33
  50. package/dist/index138.mjs +2 -2
  51. package/dist/index139.mjs +32 -20
  52. package/dist/index14.mjs +94 -56
  53. package/dist/index140.mjs +2 -56
  54. package/dist/index141.mjs +18 -26
  55. package/dist/index142.mjs +55 -6
  56. package/dist/index143.mjs +28 -51
  57. package/dist/index144.mjs +7 -6
  58. package/dist/index145.mjs +51 -11
  59. package/dist/index146.mjs +5 -6
  60. package/dist/index147.mjs +12 -28
  61. package/dist/index148.mjs +7 -2
  62. package/dist/index149.mjs +27 -69
  63. package/dist/index15.mjs +734 -62
  64. package/dist/index150.mjs +2 -167
  65. package/dist/index151.mjs +70 -2
  66. package/dist/index152.mjs +167 -2
  67. package/dist/index153.mjs +2 -2
  68. package/dist/index154.mjs +2 -18
  69. package/dist/index155.mjs +2 -32
  70. package/dist/index156.mjs +14 -34
  71. package/dist/index157.mjs +25 -11
  72. package/dist/index158.mjs +34 -14
  73. package/dist/index159.mjs +18 -2
  74. package/dist/index16.mjs +50 -14
  75. package/dist/index160.mjs +11 -13
  76. package/dist/index161.mjs +2 -46
  77. package/dist/index162.mjs +20 -2
  78. package/dist/index163.mjs +41 -25
  79. package/dist/index164.mjs +2 -18
  80. package/dist/index165.mjs +30 -2
  81. package/dist/index166.mjs +18 -2
  82. package/dist/index167.mjs +2 -2
  83. package/dist/index168.mjs +2 -2
  84. package/dist/index169.mjs +2 -72
  85. package/dist/index17.mjs +62 -109
  86. package/dist/index170.mjs +2 -2
  87. package/dist/index171.mjs +59 -40
  88. package/dist/index173.mjs +48 -31
  89. package/dist/index174.mjs +2 -152
  90. package/dist/index175.mjs +36 -2
  91. package/dist/index176.mjs +152 -2
  92. package/dist/index177.mjs +2 -19
  93. package/dist/index178.mjs +2 -2
  94. package/dist/index179.mjs +19 -2
  95. package/dist/index18.mjs +23 -41
  96. package/dist/index180.mjs +2 -26
  97. package/dist/index181.mjs +2 -2
  98. package/dist/index182.mjs +26 -2
  99. package/dist/index183.mjs +2 -24
  100. package/dist/index184.mjs +2 -23
  101. package/dist/index185.mjs +24 -2
  102. package/dist/index186.mjs +23 -2
  103. package/dist/index187.mjs +2 -2
  104. package/dist/index188.mjs +2 -23
  105. package/dist/index19.mjs +109 -42
  106. package/dist/index190.mjs +16 -16
  107. package/dist/index191.mjs +2 -2
  108. package/dist/index192.mjs +23 -2
  109. package/dist/index193.mjs +2 -2
  110. package/dist/index194.mjs +2 -23
  111. package/dist/index195.mjs +2 -2
  112. package/dist/index196.mjs +15 -15
  113. package/dist/index198.mjs +23 -2
  114. package/dist/index199.mjs +2 -2
  115. package/dist/index2.mjs +2 -2
  116. package/dist/index20.mjs +42 -67
  117. package/dist/index200.mjs +2 -2
  118. package/dist/index201.mjs +2 -2
  119. package/dist/index203.mjs +2 -2
  120. package/dist/index205.mjs +2 -127
  121. package/dist/index206.mjs +2 -2
  122. package/dist/index207.mjs +123 -70
  123. package/dist/index208.mjs +2 -74
  124. package/dist/index209.mjs +74 -2
  125. package/dist/index21.mjs +41 -31
  126. package/dist/index210.mjs +73 -30
  127. package/dist/index211.mjs +2 -11
  128. package/dist/index212.mjs +30 -3
  129. package/dist/index213.mjs +10 -3
  130. package/dist/index214.mjs +4 -13
  131. package/dist/index215.mjs +4 -7
  132. package/dist/index216.mjs +13 -12
  133. package/dist/index217.mjs +7 -5
  134. package/dist/index218.mjs +12 -33
  135. package/dist/index219.mjs +5 -31
  136. package/dist/index22.mjs +64 -6
  137. package/dist/index220.mjs +32 -27
  138. package/dist/index221.mjs +28 -58
  139. package/dist/index222.mjs +28 -2
  140. package/dist/index223.mjs +55 -102
  141. package/dist/index224.mjs +2 -2
  142. package/dist/index225.mjs +2 -2
  143. package/dist/index226.mjs +2 -2
  144. package/dist/index227.mjs +2 -2
  145. package/dist/index228.mjs +2 -2
  146. package/dist/index229.mjs +2 -2
  147. package/dist/index23.mjs +27 -17
  148. package/dist/index231.mjs +2 -2
  149. package/dist/index232.mjs +108 -2
  150. package/dist/index233.mjs +2 -37
  151. package/dist/index235.mjs +1 -1
  152. package/dist/index237.mjs +3 -3
  153. package/dist/index238.mjs +1 -1
  154. package/dist/index239.mjs +2 -2
  155. package/dist/index24.mjs +6 -32
  156. package/dist/index240.mjs +2 -2
  157. package/dist/index241.mjs +37 -2
  158. package/dist/index242.mjs +2 -2
  159. package/dist/index243.mjs +2 -2
  160. package/dist/index245.mjs +2 -2
  161. package/dist/index248.mjs +2 -2
  162. package/dist/index249.mjs +2 -2
  163. package/dist/index25.mjs +19 -27
  164. package/dist/index250.mjs +2 -4
  165. package/dist/index253.mjs +2 -3
  166. package/dist/index254.mjs +4 -2
  167. package/dist/index255.mjs +2 -2
  168. package/dist/index256.mjs +2 -17
  169. package/dist/index257.mjs +2 -13
  170. package/dist/index258.mjs +2 -6
  171. package/dist/index259.mjs +2 -30
  172. package/dist/index26.mjs +34 -103
  173. package/dist/index260.mjs +91 -2
  174. package/dist/index261.mjs +2 -2
  175. package/dist/index262.mjs +18 -2
  176. package/dist/index263.mjs +47 -2
  177. package/dist/index264.mjs +17 -2
  178. package/dist/index265.mjs +12 -90
  179. package/dist/index266.mjs +6 -2
  180. package/dist/index267.mjs +29 -17
  181. package/dist/index268.mjs +3 -47
  182. package/dist/index269.mjs +2 -2
  183. package/dist/index27.mjs +20 -21
  184. package/dist/index270.mjs +2 -2
  185. package/dist/index271.mjs +2 -2
  186. package/dist/index273.mjs +5 -0
  187. package/dist/index274.mjs +5 -0
  188. package/dist/index28.mjs +101 -8
  189. package/dist/index29.mjs +27 -7
  190. package/dist/index3.mjs +5 -5
  191. package/dist/index30.mjs +11 -105
  192. package/dist/index31.mjs +11 -23
  193. package/dist/index32.mjs +105 -68
  194. package/dist/index33.mjs +23 -105
  195. package/dist/index34.mjs +68 -28
  196. package/dist/index35.mjs +99 -21
  197. package/dist/index36.mjs +26 -9
  198. package/dist/index37.mjs +25 -9
  199. package/dist/index38.mjs +10 -122
  200. package/dist/index39.mjs +9 -387
  201. package/dist/index4.mjs +1 -1
  202. package/dist/index40.mjs +116 -18
  203. package/dist/index41.mjs +385 -99
  204. package/dist/index42.mjs +24 -6
  205. package/dist/index43.mjs +30 -1431
  206. package/dist/index44.mjs +6 -69
  207. package/dist/index45.mjs +1433 -2
  208. package/dist/index46.mjs +68 -58
  209. package/dist/index47.mjs +2 -51
  210. package/dist/index48.mjs +60 -33
  211. package/dist/index49.mjs +49 -13
  212. package/dist/index5.mjs +1 -1
  213. package/dist/index50.mjs +32 -2262
  214. package/dist/index51.mjs +15 -36
  215. package/dist/index52.mjs +2261 -42
  216. package/dist/index53.mjs +36 -99
  217. package/dist/index54.mjs +43 -112
  218. package/dist/index55.mjs +99 -81
  219. package/dist/index56.mjs +82 -76
  220. package/dist/index57.mjs +54 -68
  221. package/dist/index58.mjs +82 -56
  222. package/dist/index59.mjs +74 -58
  223. package/dist/index6.mjs +1 -1
  224. package/dist/index60.mjs +77 -15
  225. package/dist/index61.mjs +74 -15
  226. package/dist/index62.mjs +15 -59
  227. package/dist/index63.mjs +14 -119
  228. package/dist/index64.mjs +46 -112
  229. package/dist/index65.mjs +124 -23
  230. package/dist/index66.mjs +129 -2
  231. package/dist/index67.mjs +23 -4
  232. package/dist/index68.mjs +2 -23
  233. package/dist/index69.mjs +4 -152
  234. package/dist/index7.mjs +6 -6
  235. package/dist/index70.mjs +149 -71
  236. package/dist/index71.mjs +23 -15
  237. package/dist/index72.mjs +68 -56
  238. package/dist/index73.mjs +15 -2
  239. package/dist/index74.mjs +62 -5
  240. package/dist/index75.mjs +2 -1134
  241. package/dist/index76.mjs +5 -19
  242. package/dist/index77.mjs +1119 -40
  243. package/dist/index78.mjs +14 -27
  244. package/dist/index79.mjs +55 -2
  245. package/dist/index8.mjs +34 -34
  246. package/dist/index80.mjs +29 -231
  247. package/dist/index81.mjs +2 -6
  248. package/dist/index82.mjs +228 -127
  249. package/dist/index83.mjs +4 -66
  250. package/dist/index84.mjs +124 -77
  251. package/dist/index85.mjs +65 -26
  252. package/dist/index86.mjs +84 -6
  253. package/dist/index87.mjs +26 -72
  254. package/dist/index88.mjs +8 -3
  255. package/dist/index89.mjs +75 -2
  256. package/dist/index9.mjs +17 -17
  257. package/dist/index90.mjs +3 -82
  258. package/dist/index91.mjs +2 -54
  259. package/dist/index92.mjs +82 -5
  260. package/dist/index93.mjs +53 -4
  261. package/dist/index94.mjs +5 -178
  262. package/dist/index95.mjs +5 -53
  263. package/dist/index96.mjs +178 -68
  264. package/dist/index97.mjs +50 -31
  265. package/dist/index98.mjs +69 -43
  266. package/dist/index99.mjs +34 -2
  267. package/package.json +1 -1
  268. package/src/components/OrderConfirmation.stories.tsx +2 -2
  269. package/src/components/ProductAddOns.stories.tsx +6 -6
  270. package/src/components/ProductAddOns.tsx +3 -4
  271. package/src/components/ProductCard.stories.tsx +2 -2
  272. package/src/components/ProductCard.tsx +3 -3
  273. package/src/components/ProductGrid.tsx +1 -1
  274. package/src/index.ts +6 -0
package/dist/index78.mjs CHANGED
@@ -1,36 +1,23 @@
1
1
  'use client';
2
- import { __module as u } from "./index138.mjs";
3
- import d from "react/jsx-runtime";
4
- import "react";
5
- import { __require as c } from "./index69.mjs";
6
- var n;
7
- function y() {
8
- return n ? u.exports : (n = 1, function(a, e) {
9
- Object.defineProperty(e, "__esModule", {
2
+ import { __exports as e } from "./index137.mjs";
3
+ import "./index76.mjs";
4
+ import u from "react";
5
+ import { __exports as n } from "./index81.mjs";
6
+ var o;
7
+ function d() {
8
+ return o ? e : (o = 1, function(t) {
9
+ Object.defineProperty(t, "__esModule", {
10
10
  value: !0
11
- }), Object.defineProperty(e, "default", {
11
+ }), Object.defineProperty(t, "RouterContext", {
12
12
  enumerable: !0,
13
13
  get: function() {
14
- return l;
14
+ return r;
15
15
  }
16
16
  });
17
- const f = d, o = c();
18
- function l(t) {
19
- function r(i) {
20
- return /* @__PURE__ */ (0, f.jsx)(t, {
21
- router: (0, o.useRouter)(),
22
- ...i
23
- });
24
- }
25
- if (r.getInitialProps = t.getInitialProps, r.origGetInitialProps = t.origGetInitialProps, process.env.NODE_ENV !== "production") {
26
- const i = t.displayName || t.name || "Unknown";
27
- r.displayName = "withRouter(" + i + ")";
28
- }
29
- return r;
30
- }
31
- (typeof e.default == "function" || typeof e.default == "object" && e.default !== null) && typeof e.default.__esModule > "u" && (Object.defineProperty(e.default, "__esModule", { value: !0 }), Object.assign(e.default, e), a.exports = e.default);
32
- }(u, u.exports), u.exports);
17
+ const r = (/* @__PURE__ */ n._(u)).default.createContext(null);
18
+ process.env.NODE_ENV !== "production" && (r.displayName = "RouterContext");
19
+ }(e), e);
33
20
  }
34
21
  export {
35
- y as __require
22
+ d as __require
36
23
  };
package/dist/index79.mjs CHANGED
@@ -1,5 +1,58 @@
1
1
  'use client';
2
- var e = {};
2
+ import { __exports as o } from "./index138.mjs";
3
+ import { __require as p } from "./index139.mjs";
4
+ var u;
5
+ function m() {
6
+ return u ? o : (u = 1, function(i) {
7
+ Object.defineProperty(i, "__esModule", {
8
+ value: !0
9
+ });
10
+ function f(e, r) {
11
+ for (var t in r) Object.defineProperty(e, t, {
12
+ enumerable: !0,
13
+ get: r[t]
14
+ });
15
+ }
16
+ f(i, {
17
+ /**
18
+ * Checks whether the given value is a NextError.
19
+ * This can be used to print a more detailed error message with properties like `code` & `digest`.
20
+ */
21
+ default: function() {
22
+ return s;
23
+ },
24
+ getProperError: function() {
25
+ return a;
26
+ }
27
+ });
28
+ const c = p();
29
+ function s(e) {
30
+ return typeof e == "object" && e !== null && "name" in e && "message" in e;
31
+ }
32
+ function d(e) {
33
+ const r = /* @__PURE__ */ new WeakSet();
34
+ return JSON.stringify(e, (t, n) => {
35
+ if (typeof n == "object" && n !== null) {
36
+ if (r.has(n))
37
+ return "[Circular]";
38
+ r.add(n);
39
+ }
40
+ return n;
41
+ });
42
+ }
43
+ function a(e) {
44
+ if (s(e))
45
+ return e;
46
+ if (process.env.NODE_ENV === "development") {
47
+ if (typeof e > "u")
48
+ return new Error("An undefined error was thrown, see here for more info: https://nextjs.org/docs/messages/threw-undefined");
49
+ if (e === null)
50
+ return new Error("A null error was thrown, see here for more info: https://nextjs.org/docs/messages/threw-undefined");
51
+ }
52
+ return new Error((0, c.isPlainObject)(e) ? d(e) : e + "");
53
+ }
54
+ }(o), o);
55
+ }
3
56
  export {
4
- e as __exports
57
+ m as __require
5
58
  };
package/dist/index8.mjs CHANGED
@@ -1,11 +1,11 @@
1
1
  'use client';
2
- import { jsxs as s, jsx as t, Fragment as u } from "react/jsx-runtime";
2
+ import { jsxs as l, jsx as a, Fragment as u } from "react/jsx-runtime";
3
3
  import { useState as f } from "react";
4
- import { Card as P, CardContent as S, CardFooter as j } from "./index15.mjs";
5
- import { Button as I } from "./index14.mjs";
6
- import { Badge as p } from "./index16.mjs";
4
+ import { Card as P, CardContent as S, CardFooter as j } from "./index17.mjs";
5
+ import { Button as I } from "./index16.mjs";
6
+ import { Badge as h } from "./index18.mjs";
7
7
  import { Package as O, ShoppingCart as q } from "lucide-react";
8
- import { cn as g, formatCurrency as h } from "./index20.mjs";
8
+ import { cn as p, formatCurrency as g } from "./index22.mjs";
9
9
  function D({
10
10
  product: r,
11
11
  onAddToCart: o,
@@ -19,44 +19,44 @@ function D({
19
19
  var d;
20
20
  const [c, y] = f(
21
21
  ((d = r.variants[0]) == null ? void 0 : d.id) || ""
22
- ), [m, k] = f(1), a = r.variants.find((e) => e.id === c), C = r.variants.length > 1, l = a ? a.stock === void 0 || a.stock > 0 : !1, w = (e) => {
23
- e.stopPropagation(), a && o && o(a.id, m);
22
+ ), [m, k] = f(1), t = r.variants.find((e) => e.id === c), C = r.variants.length > 1, s = t ? t.stock === void 0 || t.stock > 0 : !1, w = (e) => {
23
+ e.stopPropagation(), t && o && o(t.id, m);
24
24
  };
25
- return /* @__PURE__ */ s(
25
+ return /* @__PURE__ */ l(
26
26
  P,
27
27
  {
28
- className: g(
28
+ className: p(
29
29
  "group overflow-hidden transition-all hover:shadow-lg",
30
30
  i && "cursor-pointer",
31
31
  x
32
32
  ),
33
33
  onClick: i,
34
34
  children: [
35
- /* @__PURE__ */ s("div", { className: "relative aspect-square overflow-hidden bg-gray-100", children: [
36
- r.imageUrl ? /* @__PURE__ */ t(
35
+ /* @__PURE__ */ l("div", { className: "relative aspect-square overflow-hidden bg-gray-100", children: [
36
+ r.thumbnailUrl ? /* @__PURE__ */ a(
37
37
  "img",
38
38
  {
39
- src: r.imageUrl,
39
+ src: r.thumbnailUrl,
40
40
  alt: r.name,
41
- className: g(
41
+ className: p(
42
42
  "h-full w-full object-cover transition-transform group-hover:scale-105",
43
43
  N
44
44
  )
45
45
  }
46
- ) : /* @__PURE__ */ t("div", { className: "flex h-full w-full items-center justify-center", children: /* @__PURE__ */ t(O, { className: "h-16 w-16 text-gray-400" }) }),
47
- !l && /* @__PURE__ */ t(p, { className: "absolute right-2 top-2 bg-red-600", children: "Out of Stock" }),
48
- b && l && (a == null ? void 0 : a.stock) !== void 0 && a.stock < 10 && /* @__PURE__ */ s(p, { className: "absolute right-2 top-2 bg-orange-600", children: [
46
+ ) : /* @__PURE__ */ a("div", { className: "flex h-full w-full items-center justify-center", children: /* @__PURE__ */ a(O, { className: "h-16 w-16 text-gray-400" }) }),
47
+ !s && /* @__PURE__ */ a(h, { className: "absolute right-2 top-2 bg-red-600", children: "Out of Stock" }),
48
+ b && s && (t == null ? void 0 : t.stock) !== void 0 && t.stock < 10 && /* @__PURE__ */ l(h, { className: "absolute right-2 top-2 bg-orange-600", children: [
49
49
  "Only ",
50
- a.stock,
50
+ t.stock,
51
51
  " left"
52
52
  ] })
53
53
  ] }),
54
- /* @__PURE__ */ s(S, { className: "p-4", children: [
55
- /* @__PURE__ */ t("h3", { className: "mb-1 font-semibold line-clamp-2", children: r.name }),
56
- r.description && /* @__PURE__ */ t("p", { className: "mb-2 text-sm text-gray-600 line-clamp-2", children: r.description }),
57
- C && /* @__PURE__ */ s("div", { className: "mb-3", children: [
58
- /* @__PURE__ */ t("label", { className: "mb-1 block text-xs font-medium text-gray-700", children: "Select Option" }),
59
- /* @__PURE__ */ t(
54
+ /* @__PURE__ */ l(S, { className: "p-4", children: [
55
+ /* @__PURE__ */ a("h3", { className: "mb-1 font-semibold line-clamp-2", children: r.name }),
56
+ r.description && /* @__PURE__ */ a("p", { className: "mb-2 text-sm text-gray-600 line-clamp-2", children: r.description }),
57
+ C && /* @__PURE__ */ l("div", { className: "mb-3", children: [
58
+ /* @__PURE__ */ a("label", { className: "mb-1 block text-xs font-medium text-gray-700", children: "Select Option" }),
59
+ /* @__PURE__ */ a(
60
60
  "select",
61
61
  {
62
62
  value: c,
@@ -65,23 +65,23 @@ function D({
65
65
  },
66
66
  className: "w-full rounded-md border border-gray-300 px-2 py-1 text-sm focus:border-blue-500 focus:outline-none focus:ring-1 focus:ring-blue-500",
67
67
  onClick: (e) => e.stopPropagation(),
68
- children: r.variants.map((e) => /* @__PURE__ */ s("option", { value: e.id, children: [
68
+ children: r.variants.map((e) => /* @__PURE__ */ l("option", { value: e.id, children: [
69
69
  e.name,
70
70
  " - ",
71
- h(e.price)
71
+ g(e.price)
72
72
  ] }, e.id))
73
73
  }
74
74
  )
75
75
  ] }),
76
- /* @__PURE__ */ t("div", { className: "mb-3 text-2xl font-bold text-blue-600", children: a && h(a.price) }),
77
- /* @__PURE__ */ s("div", { className: "flex items-center gap-2", children: [
78
- /* @__PURE__ */ t("label", { className: "text-xs font-medium text-gray-700", children: "Qty:" }),
79
- /* @__PURE__ */ t(
76
+ /* @__PURE__ */ a("div", { className: "mb-3 text-2xl font-bold text-blue-600", children: t && g(t.price) }),
77
+ /* @__PURE__ */ l("div", { className: "flex items-center gap-2", children: [
78
+ /* @__PURE__ */ a("label", { className: "text-xs font-medium text-gray-700", children: "Qty:" }),
79
+ /* @__PURE__ */ a(
80
80
  "input",
81
81
  {
82
82
  type: "number",
83
83
  min: "1",
84
- max: (a == null ? void 0 : a.stock) || 999,
84
+ max: (t == null ? void 0 : t.stock) || 999,
85
85
  value: m,
86
86
  onChange: (e) => {
87
87
  e.stopPropagation(), k(Math.max(1, parseInt(e.target.value) || 1));
@@ -92,14 +92,14 @@ function D({
92
92
  )
93
93
  ] })
94
94
  ] }),
95
- /* @__PURE__ */ t(j, { className: "p-4 pt-0", children: /* @__PURE__ */ t(
95
+ /* @__PURE__ */ a(j, { className: "p-4 pt-0", children: /* @__PURE__ */ a(
96
96
  I,
97
97
  {
98
98
  onClick: w,
99
- disabled: v || !l || n,
99
+ disabled: v || !s || n,
100
100
  className: "w-full",
101
- children: n ? /* @__PURE__ */ t(u, { children: "Adding..." }) : /* @__PURE__ */ s(u, { children: [
102
- /* @__PURE__ */ t(q, { className: "mr-2 h-4 w-4" }),
101
+ children: n ? /* @__PURE__ */ a(u, { children: "Adding..." }) : /* @__PURE__ */ l(u, { children: [
102
+ /* @__PURE__ */ a(q, { className: "mr-2 h-4 w-4" }),
103
103
  "Add to Cart"
104
104
  ] })
105
105
  }
package/dist/index80.mjs CHANGED
@@ -1,238 +1,36 @@
1
1
  'use client';
2
- import R from "./index81.mjs";
3
- const { toString: T } = Object.prototype, { getPrototypeOf: A } = Object, { iterator: g, toStringTag: S } = Symbol, F = /* @__PURE__ */ ((e) => (t) => {
4
- const n = T.call(t);
5
- return e[n] || (e[n] = n.slice(8, -1).toLowerCase());
6
- })(/* @__PURE__ */ Object.create(null)), f = (e) => (e = e.toLowerCase(), (t) => F(t) === e), O = (e) => (t) => typeof t === e, { isArray: p } = Array, a = O("undefined");
7
- function d(e) {
8
- return e !== null && !a(e) && e.constructor !== null && !a(e.constructor) && c(e.constructor.isBuffer) && e.constructor.isBuffer(e);
9
- }
10
- const B = f("ArrayBuffer");
11
- function M(e) {
12
- let t;
13
- return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && B(e.buffer), t;
14
- }
15
- const k = O("string"), c = O("function"), E = O("number"), y = (e) => e !== null && typeof e == "object", N = (e) => e === !0 || e === !1, w = (e) => {
16
- if (F(e) !== "object")
17
- return !1;
18
- const t = A(e);
19
- return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(S in e) && !(g in e);
20
- }, U = (e) => {
21
- if (!y(e) || d(e))
22
- return !1;
23
- try {
24
- return Object.keys(e).length === 0 && Object.getPrototypeOf(e) === Object.prototype;
25
- } catch {
26
- return !1;
27
- }
28
- }, I = f("Date"), V = f("File"), _ = f("Blob"), q = f("FileList"), H = (e) => y(e) && c(e.pipe), z = (e) => {
29
- let t;
30
- return e && (typeof FormData == "function" && e instanceof FormData || c(e.append) && ((t = F(e)) === "formdata" || // detect form-data instance
31
- t === "object" && c(e.toString) && e.toString() === "[object FormData]"));
32
- }, J = f("URLSearchParams"), [K, $, W, G] = ["ReadableStream", "Request", "Response", "Headers"].map(f), Q = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
33
- function m(e, t, { allOwnKeys: n = !1 } = {}) {
34
- if (e === null || typeof e > "u")
35
- return;
36
- let r, s;
37
- if (typeof e != "object" && (e = [e]), p(e))
38
- for (r = 0, s = e.length; r < s; r++)
39
- t.call(null, e[r], r, e);
40
- else {
41
- if (d(e))
42
- return;
43
- const o = n ? Object.getOwnPropertyNames(e) : Object.keys(e), i = o.length;
44
- let l;
45
- for (r = 0; r < i; r++)
46
- l = o[r], t.call(null, e[l], l, e);
47
- }
48
- }
49
- function P(e, t) {
50
- if (d(e))
51
- return null;
52
- t = t.toLowerCase();
53
- const n = Object.keys(e);
54
- let r = n.length, s;
55
- for (; r-- > 0; )
56
- if (s = n[r], t === s.toLowerCase())
57
- return s;
58
- return null;
59
- }
60
- const u = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, L = (e) => !a(e) && e !== u;
61
- function h() {
62
- const { caseless: e, skipUndefined: t } = L(this) && this || {}, n = {}, r = (s, o) => {
63
- const i = e && P(n, o) || o;
64
- w(n[i]) && w(s) ? n[i] = h(n[i], s) : w(s) ? n[i] = h({}, s) : p(s) ? n[i] = s.slice() : (!t || !a(s)) && (n[i] = s);
65
- };
66
- for (let s = 0, o = arguments.length; s < o; s++)
67
- arguments[s] && m(arguments[s], r);
68
- return n;
69
- }
70
- const X = (e, t, n, { allOwnKeys: r } = {}) => (m(t, (s, o) => {
71
- n && c(s) ? e[o] = R(s, n) : e[o] = s;
72
- }, { allOwnKeys: r }), e), Y = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), Z = (e, t, n, r) => {
73
- e.prototype = Object.create(t.prototype, r), e.prototype.constructor = e, Object.defineProperty(e, "super", {
74
- value: t.prototype
75
- }), n && Object.assign(e.prototype, n);
76
- }, j = (e, t, n, r) => {
77
- let s, o, i;
78
- const l = {};
79
- if (t = t || {}, e == null) return t;
80
- do {
81
- for (s = Object.getOwnPropertyNames(e), o = s.length; o-- > 0; )
82
- i = s[o], (!r || r(i, e, t)) && !l[i] && (t[i] = e[i], l[i] = !0);
83
- e = n !== !1 && A(e);
84
- } while (e && (!n || n(e, t)) && e !== Object.prototype);
85
- return t;
86
- }, v = (e, t, n) => {
87
- e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length;
88
- const r = e.indexOf(t, n);
89
- return r !== -1 && r === n;
90
- }, ee = (e) => {
91
- if (!e) return null;
92
- if (p(e)) return e;
93
- let t = e.length;
94
- if (!E(t)) return null;
95
- const n = new Array(t);
96
- for (; t-- > 0; )
97
- n[t] = e[t];
98
- return n;
99
- }, te = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && A(Uint8Array)), ne = (e, t) => {
100
- const r = (e && e[g]).call(e);
101
- let s;
102
- for (; (s = r.next()) && !s.done; ) {
103
- const o = s.value;
104
- t.call(e, o[0], o[1]);
105
- }
106
- }, re = (e, t) => {
107
- let n;
108
- const r = [];
109
- for (; (n = e.exec(t)) !== null; )
110
- r.push(n);
111
- return r;
112
- }, se = f("HTMLFormElement"), oe = (e) => e.toLowerCase().replace(
113
- /[-_\s]([a-z\d])(\w*)/g,
114
- function(n, r, s) {
115
- return r.toUpperCase() + s;
116
- }
117
- ), x = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), ie = f("RegExp"), C = (e, t) => {
118
- const n = Object.getOwnPropertyDescriptors(e), r = {};
119
- m(n, (s, o) => {
120
- let i;
121
- (i = t(s, o, e)) !== !1 && (r[o] = i || s);
122
- }), Object.defineProperties(e, r);
123
- }, ce = (e) => {
124
- C(e, (t, n) => {
125
- if (c(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
126
- return !1;
127
- const r = e[n];
128
- if (c(r)) {
129
- if (t.enumerable = !1, "writable" in t) {
130
- t.writable = !1;
131
- return;
2
+ import { __module as u } from "./index140.mjs";
3
+ import d from "react/jsx-runtime";
4
+ import "react";
5
+ import { __require as c } from "./index70.mjs";
6
+ var n;
7
+ function y() {
8
+ return n ? u.exports : (n = 1, function(a, e) {
9
+ Object.defineProperty(e, "__esModule", {
10
+ value: !0
11
+ }), Object.defineProperty(e, "default", {
12
+ enumerable: !0,
13
+ get: function() {
14
+ return l;
132
15
  }
133
- t.set || (t.set = () => {
134
- throw Error("Can not rewrite read-only method '" + n + "'");
135
- });
136
- }
137
- });
138
- }, fe = (e, t) => {
139
- const n = {}, r = (s) => {
140
- s.forEach((o) => {
141
- n[o] = !0;
142
16
  });
143
- };
144
- return p(e) ? r(e) : r(String(e).split(t)), n;
145
- }, le = () => {
146
- }, ue = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
147
- function ae(e) {
148
- return !!(e && c(e.append) && e[S] === "FormData" && e[g]);
149
- }
150
- const pe = (e) => {
151
- const t = new Array(10), n = (r, s) => {
152
- if (y(r)) {
153
- if (t.indexOf(r) >= 0)
154
- return;
155
- if (d(r))
156
- return r;
157
- if (!("toJSON" in r)) {
158
- t[s] = r;
159
- const o = p(r) ? [] : {};
160
- return m(r, (i, l) => {
161
- const b = n(i, s + 1);
162
- !a(b) && (o[l] = b);
163
- }), t[s] = void 0, o;
17
+ const f = d, o = c();
18
+ function l(t) {
19
+ function r(i) {
20
+ return /* @__PURE__ */ (0, f.jsx)(t, {
21
+ router: (0, o.useRouter)(),
22
+ ...i
23
+ });
24
+ }
25
+ if (r.getInitialProps = t.getInitialProps, r.origGetInitialProps = t.origGetInitialProps, process.env.NODE_ENV !== "production") {
26
+ const i = t.displayName || t.name || "Unknown";
27
+ r.displayName = "withRouter(" + i + ")";
164
28
  }
29
+ return r;
165
30
  }
166
- return r;
167
- };
168
- return n(e, 0);
169
- }, de = f("AsyncFunction"), ye = (e) => e && (y(e) || c(e)) && c(e.then) && c(e.catch), D = ((e, t) => e ? setImmediate : t ? ((n, r) => (u.addEventListener("message", ({ source: s, data: o }) => {
170
- s === u && o === n && r.length && r.shift()();
171
- }, !1), (s) => {
172
- r.push(s), u.postMessage(n, "*");
173
- }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(
174
- typeof setImmediate == "function",
175
- c(u.postMessage)
176
- ), me = typeof queueMicrotask < "u" ? queueMicrotask.bind(u) : typeof process < "u" && process.nextTick || D, we = (e) => e != null && c(e[g]), Fe = {
177
- isArray: p,
178
- isArrayBuffer: B,
179
- isBuffer: d,
180
- isFormData: z,
181
- isArrayBufferView: M,
182
- isString: k,
183
- isNumber: E,
184
- isBoolean: N,
185
- isObject: y,
186
- isPlainObject: w,
187
- isEmptyObject: U,
188
- isReadableStream: K,
189
- isRequest: $,
190
- isResponse: W,
191
- isHeaders: G,
192
- isUndefined: a,
193
- isDate: I,
194
- isFile: V,
195
- isBlob: _,
196
- isRegExp: ie,
197
- isFunction: c,
198
- isStream: H,
199
- isURLSearchParams: J,
200
- isTypedArray: te,
201
- isFileList: q,
202
- forEach: m,
203
- merge: h,
204
- extend: X,
205
- trim: Q,
206
- stripBOM: Y,
207
- inherits: Z,
208
- toFlatObject: j,
209
- kindOf: F,
210
- kindOfTest: f,
211
- endsWith: v,
212
- toArray: ee,
213
- forEachEntry: ne,
214
- matchAll: re,
215
- isHTMLForm: se,
216
- hasOwnProperty: x,
217
- hasOwnProp: x,
218
- // an alias to avoid ESLint no-prototype-builtins detection
219
- reduceDescriptors: C,
220
- freezeMethods: ce,
221
- toObjectSet: fe,
222
- toCamelCase: oe,
223
- noop: le,
224
- toFiniteNumber: ue,
225
- findKey: P,
226
- global: u,
227
- isContextDefined: L,
228
- isSpecCompliantForm: ae,
229
- toJSONObject: pe,
230
- isAsyncFn: de,
231
- isThenable: ye,
232
- setImmediate: D,
233
- asap: me,
234
- isIterable: we
235
- };
31
+ (typeof e.default == "function" || typeof e.default == "object" && e.default !== null) && typeof e.default.__esModule > "u" && (Object.defineProperty(e.default, "__esModule", { value: !0 }), Object.assign(e.default, e), a.exports = e.default);
32
+ }(u, u.exports), u.exports);
33
+ }
236
34
  export {
237
- Fe as default
35
+ y as __require
238
36
  };
package/dist/index81.mjs CHANGED
@@ -1,9 +1,5 @@
1
1
  'use client';
2
- function u(n, r) {
3
- return function() {
4
- return n.apply(r, arguments);
5
- };
6
- }
2
+ var e = {};
7
3
  export {
8
- u as default
4
+ e as __exports
9
5
  };