@shopify/shop-minis-react 0.0.19 → 0.0.20

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 (44) hide show
  1. package/dist/components/MinisContainer.js +13 -11
  2. package/dist/components/MinisContainer.js.map +1 -1
  3. package/dist/components/atoms/list.js +52 -0
  4. package/dist/components/atoms/list.js.map +1 -0
  5. package/dist/components/atoms/pagination.js +10 -0
  6. package/dist/components/atoms/pagination.js.map +1 -0
  7. package/dist/components/atoms/tracking-pixel.js +32 -0
  8. package/dist/components/atoms/tracking-pixel.js.map +1 -0
  9. package/dist/index.js +187 -185
  10. package/dist/index.js.map +1 -1
  11. package/dist/internal/useShopActions.js.map +1 -1
  12. package/dist/internal/useShopActionsDataFetching.js +26 -26
  13. package/dist/internal/useShopActionsDataFetching.js.map +1 -1
  14. package/dist/internal/useShopActionsPaginatedDataFetching.js.map +1 -1
  15. package/dist/mocks.js +267 -0
  16. package/dist/mocks.js.map +1 -0
  17. package/dist/shop-minis-react/node_modules/.pnpm/@babel_runtime@7.27.6/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js +8 -0
  18. package/dist/shop-minis-react/node_modules/.pnpm/@babel_runtime@7.27.6/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js.map +1 -0
  19. package/dist/shop-minis-react/node_modules/.pnpm/@babel_runtime@7.27.6/node_modules/@babel/runtime/helpers/esm/extends.js +13 -0
  20. package/dist/shop-minis-react/node_modules/.pnpm/@babel_runtime@7.27.6/node_modules/@babel/runtime/helpers/esm/extends.js.map +1 -0
  21. package/dist/shop-minis-react/node_modules/.pnpm/@babel_runtime@7.27.6/node_modules/@babel/runtime/helpers/esm/inheritsLoose.js +8 -0
  22. package/dist/shop-minis-react/node_modules/.pnpm/@babel_runtime@7.27.6/node_modules/@babel/runtime/helpers/esm/inheritsLoose.js.map +1 -0
  23. package/dist/shop-minis-react/node_modules/.pnpm/@babel_runtime@7.27.6/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js +9 -0
  24. package/dist/shop-minis-react/node_modules/.pnpm/@babel_runtime@7.27.6/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js.map +1 -0
  25. package/dist/shop-minis-react/node_modules/.pnpm/memoize-one@5.2.1/node_modules/memoize-one/dist/memoize-one.esm.js +28 -0
  26. package/dist/shop-minis-react/node_modules/.pnpm/memoize-one@5.2.1/node_modules/memoize-one/dist/memoize-one.esm.js.map +1 -0
  27. package/dist/shop-minis-react/node_modules/.pnpm/react-intersection-observer@9.16.0_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-intersection-observer/dist/index.js +135 -0
  28. package/dist/shop-minis-react/node_modules/.pnpm/react-intersection-observer@9.16.0_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-intersection-observer/dist/index.js.map +1 -0
  29. package/dist/shop-minis-react/node_modules/.pnpm/react-window@1.8.11_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-window/dist/index.esm.js +375 -0
  30. package/dist/shop-minis-react/node_modules/.pnpm/react-window@1.8.11_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-window/dist/index.esm.js.map +1 -0
  31. package/dist/shop-minis-react.css +1 -0
  32. package/package.json +9 -4
  33. package/src/components/MinisContainer.tsx +4 -1
  34. package/src/components/atoms/list.tsx +101 -0
  35. package/src/components/atoms/pagination.tsx +19 -0
  36. package/src/components/atoms/tracking-pixel.tsx +40 -0
  37. package/src/components/index.ts +1 -0
  38. package/src/index.css +1 -0
  39. package/src/internal/useShopActions.ts +1 -1
  40. package/src/internal/useShopActionsDataFetching.ts +6 -7
  41. package/src/internal/useShopActionsPaginatedDataFetching.ts +3 -6
  42. package/src/mocks.ts +20 -8
  43. package/src/stories/List.stories.tsx +68 -0
  44. package/src/styles/utilities.css +22 -0
@@ -1,29 +1,31 @@
1
- import { jsx as r, jsxs as c } from "react/jsx-runtime";
1
+ import { jsx as r, jsxs as d } from "react/jsx-runtime";
2
2
  import { useState as m, useEffect as l } from "react";
3
- import { ImagePickerProvider as u } from "../providers/ImagePickerProvider.js";
4
- function p({ children: s }) {
5
- const [a, t] = m(!1);
3
+ import { injectMocks as u } from "../mocks.js";
4
+ import { ImagePickerProvider as f } from "../providers/ImagePickerProvider.js";
5
+ u();
6
+ function S({ children: a }) {
7
+ const [i, t] = m(!1);
6
8
  return l(() => {
7
9
  const n = () => window.minisSDK ? (t(!0), !0) : !1;
8
10
  if (n())
9
11
  return;
10
12
  const e = (o) => {
11
- const { type: d } = JSON.parse(o.data);
12
- d === "MINIS_SDK_READY" && t(!0);
13
+ const { type: c } = JSON.parse(o.data);
14
+ c === "MINIS_SDK_READY" && t(!0);
13
15
  };
14
16
  window.addEventListener("message", e), document.addEventListener("message", e);
15
- const i = setInterval(() => {
16
- n() && clearInterval(i);
17
+ const s = setInterval(() => {
18
+ n() && clearInterval(s);
17
19
  }, 100);
18
20
  return () => {
19
- window.removeEventListener("message", e), document.removeEventListener("message", e);
21
+ clearInterval(s), window.removeEventListener("message", e), document.removeEventListener("message", e);
20
22
  };
21
- }, []), a ? /* @__PURE__ */ r(u, { children: s }) : /* @__PURE__ */ r("div", { className: "h-screen bg-gray-50 flex items-center justify-center", children: /* @__PURE__ */ c("div", { className: "text-center", children: [
23
+ }, []), i ? /* @__PURE__ */ r(f, { children: a }) : /* @__PURE__ */ r("div", { className: "h-screen bg-gray-50 flex items-center justify-center", children: /* @__PURE__ */ d("div", { className: "text-center", children: [
22
24
  /* @__PURE__ */ r("div", { className: "animate-spin rounded-full h-8 w-8 border-b-2 border-gray-900 mx-auto mb-4" }),
23
25
  /* @__PURE__ */ r("p", { className: "text-gray-600", children: "Loading..." })
24
26
  ] }) });
25
27
  }
26
28
  export {
27
- p as MinisContainer
29
+ S as MinisContainer
28
30
  };
29
31
  //# sourceMappingURL=MinisContainer.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MinisContainer.js","sources":["../../src/components/MinisContainer.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react'\n\nimport {ImagePickerProvider} from '../providers/ImagePickerProvider'\n\nexport function MinisContainer({children}: {children: React.ReactNode}) {\n const [isSDKReady, setIsSDKReady] = useState(false)\n\n useEffect(() => {\n // Function to check if SDK is ready\n const checkSDKReady = () => {\n if (window.minisSDK) {\n setIsSDKReady(true)\n return true\n }\n return false\n }\n\n // Check immediately\n if (checkSDKReady()) {\n return\n }\n\n // If not ready, set up a listener for the MINIS_SDK_READY event\n const handleSDKReady = (event: any) => {\n const {type} = JSON.parse(event.data)\n\n if (type === 'MINIS_SDK_READY') {\n setIsSDKReady(true)\n }\n }\n\n // Listen for the MINIS_SDK_READY event\n window.addEventListener('message', handleSDKReady)\n document.addEventListener('message', handleSDKReady)\n\n // Also poll for SDK availability as a fallback\n const pollInterval = setInterval(() => {\n if (checkSDKReady()) {\n clearInterval(pollInterval)\n }\n }, 100)\n\n // Cleanup\n return () => {\n // clearInterval(pollInterval);\n window.removeEventListener('message', handleSDKReady)\n document.removeEventListener('message', handleSDKReady)\n }\n }, [])\n\n // Don't render anything until SDK is ready\n if (!isSDKReady) {\n return (\n <div className=\"h-screen bg-gray-50 flex items-center justify-center\">\n <div className=\"text-center\">\n <div className=\"animate-spin rounded-full h-8 w-8 border-b-2 border-gray-900 mx-auto mb-4\" />\n <p className=\"text-gray-600\">Loading...</p>\n </div>\n </div>\n )\n }\n\n return <ImagePickerProvider>{children}</ImagePickerProvider>\n}\n"],"names":["MinisContainer","children","isSDKReady","setIsSDKReady","useState","useEffect","checkSDKReady","handleSDKReady","event","type","pollInterval","jsx","ImagePickerProvider","jsxs"],"mappings":";;;AAIgB,SAAAA,EAAe,EAAC,UAAAC,KAAwC;AACtE,QAAM,CAACC,GAAYC,CAAa,IAAIC,EAAS,EAAK;AA8ClD,SA5CAC,EAAU,MAAM;AAEd,UAAMC,IAAgB,MAChB,OAAO,YACTH,EAAc,EAAI,GACX,MAEF;AAIT,QAAIG;AACF;AAII,UAAAC,IAAiB,CAACC,MAAe;AACrC,YAAM,EAAC,MAAAC,EAAI,IAAI,KAAK,MAAMD,EAAM,IAAI;AAEpC,MAAIC,MAAS,qBACXN,EAAc,EAAI;AAAA,IAEtB;AAGO,WAAA,iBAAiB,WAAWI,CAAc,GACxC,SAAA,iBAAiB,WAAWA,CAAc;AAG7C,UAAAG,IAAe,YAAY,MAAM;AACrC,MAAIJ,OACF,cAAcI,CAAY;AAAA,OAE3B,GAAG;AAGN,WAAO,MAAM;AAEJ,aAAA,oBAAoB,WAAWH,CAAc,GAC3C,SAAA,oBAAoB,WAAWA,CAAc;AAAA,IACxD;AAAA,EACF,GAAG,EAAE,GAGAL,IAWE,gBAAAS,EAACC,KAAqB,UAAAX,GAAS,sBATjC,OAAI,EAAA,WAAU,wDACb,UAAC,gBAAAY,EAAA,OAAA,EAAI,WAAU,eACb,UAAA;AAAA,IAAC,gBAAAF,EAAA,OAAA,EAAI,WAAU,4EAA4E,CAAA;AAAA,IAC1F,gBAAAA,EAAA,KAAA,EAAE,WAAU,iBAAgB,UAAU,aAAA,CAAA;AAAA,EAAA,EAAA,CACzC,EACF,CAAA;AAKN;"}
1
+ {"version":3,"file":"MinisContainer.js","sources":["../../src/components/MinisContainer.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react'\n\nimport {injectMocks} from '../mocks'\nimport {ImagePickerProvider} from '../providers/ImagePickerProvider'\n\ninjectMocks()\n\nexport function MinisContainer({children}: {children: React.ReactNode}) {\n const [isSDKReady, setIsSDKReady] = useState(false)\n\n useEffect(() => {\n // Function to check if SDK is ready\n const checkSDKReady = () => {\n if (window.minisSDK) {\n setIsSDKReady(true)\n return true\n }\n return false\n }\n\n // Check immediately\n if (checkSDKReady()) {\n return\n }\n\n // If not ready, set up a listener for the MINIS_SDK_READY event\n const handleSDKReady = (event: any) => {\n const {type} = JSON.parse(event.data)\n\n if (type === 'MINIS_SDK_READY') {\n setIsSDKReady(true)\n }\n }\n\n // Listen for the MINIS_SDK_READY event\n window.addEventListener('message', handleSDKReady)\n document.addEventListener('message', handleSDKReady)\n\n // Also poll for SDK availability as a fallback\n const pollInterval = setInterval(() => {\n if (checkSDKReady()) {\n clearInterval(pollInterval)\n }\n }, 100)\n\n // Cleanup\n return () => {\n clearInterval(pollInterval)\n window.removeEventListener('message', handleSDKReady)\n document.removeEventListener('message', handleSDKReady)\n }\n }, [])\n\n // Don't render anything until SDK is ready\n if (!isSDKReady) {\n return (\n <div className=\"h-screen bg-gray-50 flex items-center justify-center\">\n <div className=\"text-center\">\n <div className=\"animate-spin rounded-full h-8 w-8 border-b-2 border-gray-900 mx-auto mb-4\" />\n <p className=\"text-gray-600\">Loading...</p>\n </div>\n </div>\n )\n }\n\n return <ImagePickerProvider>{children}</ImagePickerProvider>\n}\n"],"names":["injectMocks","MinisContainer","children","isSDKReady","setIsSDKReady","useState","useEffect","checkSDKReady","handleSDKReady","event","type","pollInterval","jsx","ImagePickerProvider","jsxs"],"mappings":";;;;AAKAA,EAAY;AAEI,SAAAC,EAAe,EAAC,UAAAC,KAAwC;AACtE,QAAM,CAACC,GAAYC,CAAa,IAAIC,EAAS,EAAK;AA8ClD,SA5CAC,EAAU,MAAM;AAEd,UAAMC,IAAgB,MAChB,OAAO,YACTH,EAAc,EAAI,GACX,MAEF;AAIT,QAAIG;AACF;AAII,UAAAC,IAAiB,CAACC,MAAe;AACrC,YAAM,EAAC,MAAAC,EAAI,IAAI,KAAK,MAAMD,EAAM,IAAI;AAEpC,MAAIC,MAAS,qBACXN,EAAc,EAAI;AAAA,IAEtB;AAGO,WAAA,iBAAiB,WAAWI,CAAc,GACxC,SAAA,iBAAiB,WAAWA,CAAc;AAG7C,UAAAG,IAAe,YAAY,MAAM;AACrC,MAAIJ,OACF,cAAcI,CAAY;AAAA,OAE3B,GAAG;AAGN,WAAO,MAAM;AACX,oBAAcA,CAAY,GACnB,OAAA,oBAAoB,WAAWH,CAAc,GAC3C,SAAA,oBAAoB,WAAWA,CAAc;AAAA,IACxD;AAAA,EACF,GAAG,EAAE,GAGAL,IAWE,gBAAAS,EAACC,KAAqB,UAAAX,GAAS,sBATjC,OAAI,EAAA,WAAU,wDACb,UAAC,gBAAAY,EAAA,OAAA,EAAI,WAAU,eACb,UAAA;AAAA,IAAC,gBAAAF,EAAA,OAAA,EAAI,WAAU,4EAA4E,CAAA;AAAA,IAC1F,gBAAAA,EAAA,KAAA,EAAE,WAAU,iBAAgB,UAAU,aAAA,CAAA;AAAA,EAAA,EAAA,CACzC,EACF,CAAA;AAKN;"}
@@ -0,0 +1,52 @@
1
+ import { jsxs as u, jsx as o } from "react/jsx-runtime";
2
+ import { useCallback as f } from "react";
3
+ import { VariableSizeList as V } from "../../shop-minis-react/node_modules/.pnpm/react-window@1.8.11_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-window/dist/index.esm.js";
4
+ import { cn as j } from "../../lib/utils.js";
5
+ /* empty css */
6
+ import { Pagination as C } from "./pagination.js";
7
+ const N = V;
8
+ function q({
9
+ items: r,
10
+ height: p,
11
+ renderItem: l,
12
+ className: m,
13
+ showScrollbar: v = !1,
14
+ header: t,
15
+ headerHeight: n,
16
+ itemSizeForRow: s,
17
+ fetchMore: a,
18
+ overscanCount: b,
19
+ ...L
20
+ }) {
21
+ const g = f(
22
+ ({ index: i, style: c }) => t && i === 0 ? /* @__PURE__ */ u("div", { style: c, children: [
23
+ t,
24
+ /* @__PURE__ */ o("div", { style: { top: n }, children: l(r[0], 0) })
25
+ ] }) : a && i === r.length - 1 ? /* @__PURE__ */ u("div", { style: c, children: [
26
+ l(r[i], i),
27
+ /* @__PURE__ */ o("div", { style: { bottom: 0 }, children: /* @__PURE__ */ o(C, { fetchMore: a }) })
28
+ ] }) : /* @__PURE__ */ o("div", { style: c, children: l(r[i], i) }),
29
+ [r, l, t, a, n]
30
+ ), z = f(
31
+ (i) => t && i === 0 ? (n || 0) + s(i) : s(i),
32
+ [s, t, n]
33
+ ), S = j(v ? void 0 : "no-scrollbars", m);
34
+ return /* @__PURE__ */ o(
35
+ N,
36
+ {
37
+ className: S,
38
+ height: p,
39
+ direction: "vertical",
40
+ width: "100%",
41
+ itemCount: r.length,
42
+ overscanCount: b,
43
+ itemSize: z,
44
+ ...L,
45
+ children: g
46
+ }
47
+ );
48
+ }
49
+ export {
50
+ q as List
51
+ };
52
+ //# sourceMappingURL=list.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"list.js","sources":["../../../src/components/atoms/list.tsx"],"sourcesContent":["import {ComponentType, useCallback} from 'react'\n\nimport {\n VariableSizeList as _VariableSizeList,\n VariableSizeListProps,\n} from 'react-window'\n\nimport {cn} from '../../lib/utils'\nimport '../../styles/utilities.css'\n\nimport {Pagination} from './pagination'\n\nconst VariableSizeList =\n _VariableSizeList as unknown as ComponentType<VariableSizeListProps>\n\ninterface Props<T = any>\n extends Omit<\n VariableSizeListProps<T>,\n 'children' | 'itemCount' | 'width' | 'itemSize' | 'direction'\n > {\n items: T[]\n renderItem: (item: T, index: number) => React.ReactNode\n itemSizeForRow: (index: number) => number\n showScrollbar?: boolean\n header?: React.ReactNode\n headerHeight?: number\n fetchMore?: () => void\n}\n\nexport function List<T = any>({\n items,\n height,\n renderItem,\n className,\n showScrollbar = false,\n header,\n headerHeight,\n itemSizeForRow,\n fetchMore,\n overscanCount,\n ...listProps\n}: Props<T>) {\n const rowRenderer = useCallback(\n ({index, style}: {index: number; style: React.CSSProperties}) => {\n // prepend the header to the first row if it exists\n if (header && index === 0) {\n return (\n <div style={style}>\n {header}\n <div style={{top: headerHeight}}>{renderItem(items[0], 0)}</div>\n </div>\n )\n }\n\n // append the pagination spinner to the last row if fetchMore exists\n if (fetchMore && index === items.length - 1) {\n return (\n <div style={style}>\n {renderItem(items[index], index)}\n <div style={{bottom: 0}}>\n <Pagination fetchMore={fetchMore} />\n </div>\n </div>\n )\n }\n\n return <div style={style}>{renderItem(items[index], index)}</div>\n },\n [items, renderItem, header, fetchMore, headerHeight]\n )\n\n const getItemSize = useCallback(\n (index: number) => {\n // include the header height in the first row height\n if (header && index === 0) {\n const _headerHeight = headerHeight || 0\n return _headerHeight + itemSizeForRow(index)\n }\n\n return itemSizeForRow(index)\n },\n [itemSizeForRow, header, headerHeight]\n )\n\n const classNames = cn(showScrollbar ? undefined : 'no-scrollbars', className)\n\n return (\n <VariableSizeList\n className={classNames}\n height={height}\n direction=\"vertical\"\n width=\"100%\"\n itemCount={items.length}\n overscanCount={overscanCount}\n itemSize={getItemSize}\n {...listProps}\n >\n {rowRenderer}\n </VariableSizeList>\n )\n}\n"],"names":["VariableSizeList","_VariableSizeList","List","items","height","renderItem","className","showScrollbar","header","headerHeight","itemSizeForRow","fetchMore","overscanCount","listProps","rowRenderer","useCallback","index","style","jsxs","jsx","Pagination","getItemSize","classNames","cn"],"mappings":";;;;;;AAYA,MAAMA,IACJC;AAgBK,SAASC,EAAc;AAAA,EAC5B,OAAAC;AAAA,EACA,QAAAC;AAAA,EACA,YAAAC;AAAA,EACA,WAAAC;AAAA,EACA,eAAAC,IAAgB;AAAA,EAChB,QAAAC;AAAA,EACA,cAAAC;AAAA,EACA,gBAAAC;AAAA,EACA,WAAAC;AAAA,EACA,eAAAC;AAAA,EACA,GAAGC;AACL,GAAa;AACX,QAAMC,IAAcC;AAAA,IAClB,CAAC,EAAC,OAAAC,GAAO,OAAAC,QAEHT,KAAUQ,MAAU,IAEpB,gBAAAE,EAAC,SAAI,OAAAD,GACF,UAAA;AAAA,MAAAT;AAAA,MACA,gBAAAW,EAAA,OAAA,EAAI,OAAO,EAAC,KAAKV,EAAA,GAAgB,UAAAJ,EAAWF,EAAM,CAAC,GAAG,CAAC,EAAE,CAAA;AAAA,IAAA,GAC5D,IAKAQ,KAAaK,MAAUb,EAAM,SAAS,IAEtC,gBAAAe,EAAC,SAAI,OAAAD,GACF,UAAA;AAAA,MAAWZ,EAAAF,EAAMa,CAAK,GAAGA,CAAK;AAAA,MAC/B,gBAAAG,EAAC,OAAI,EAAA,OAAO,EAAC,QAAQ,KACnB,UAAA,gBAAAA,EAACC,GAAW,EAAA,WAAAT,EAAsB,CAAA,EACpC,CAAA;AAAA,IAAA,GACF,IAIG,gBAAAQ,EAAC,SAAI,OAAAF,GAAe,UAAAZ,EAAWF,EAAMa,CAAK,GAAGA,CAAK,GAAE;AAAA,IAE7D,CAACb,GAAOE,GAAYG,GAAQG,GAAWF,CAAY;AAAA,EACrD,GAEMY,IAAcN;AAAA,IAClB,CAACC,MAEKR,KAAUQ,MAAU,KACAP,KAAgB,KACfC,EAAeM,CAAK,IAGtCN,EAAeM,CAAK;AAAA,IAE7B,CAACN,GAAgBF,GAAQC,CAAY;AAAA,EACvC,GAEMa,IAAaC,EAAGhB,IAAgB,SAAY,iBAAiBD,CAAS;AAG1E,SAAA,gBAAAa;AAAA,IAACnB;AAAA,IAAA;AAAA,MACC,WAAWsB;AAAA,MACX,QAAAlB;AAAA,MACA,WAAU;AAAA,MACV,OAAM;AAAA,MACN,WAAWD,EAAM;AAAA,MACjB,eAAAS;AAAA,MACA,UAAUS;AAAA,MACT,GAAGR;AAAA,MAEH,UAAAC;AAAA,IAAA;AAAA,EACH;AAEJ;"}
@@ -0,0 +1,10 @@
1
+ import { jsx as o } from "react/jsx-runtime";
2
+ import { Skeleton as e } from "../ui/skeleton.js";
3
+ import { TrackingPixel as i } from "./tracking-pixel.js";
4
+ function c({ loadingComponent: r, fetchMore: n }) {
5
+ return /* @__PURE__ */ o(i, { onImpression: n, children: r ?? /* @__PURE__ */ o(e, { className: "h-10 w-full p-8" }) });
6
+ }
7
+ export {
8
+ c as Pagination
9
+ };
10
+ //# sourceMappingURL=pagination.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pagination.js","sources":["../../../src/components/atoms/pagination.tsx"],"sourcesContent":["import {Skeleton} from '../ui/skeleton'\n\nimport {TrackingPixel} from './tracking-pixel'\n\ninterface Props {\n loadingComponent?: React.ReactNode\n isFetchingMore?: boolean\n fetchMore: () => void\n}\n\nexport function Pagination({loadingComponent, fetchMore}: Props) {\n const loadingPlaceholder = loadingComponent ?? (\n <Skeleton className=\"h-10 w-full p-8\" />\n )\n\n return (\n <TrackingPixel onImpression={fetchMore}>{loadingPlaceholder}</TrackingPixel>\n )\n}\n"],"names":["Pagination","loadingComponent","fetchMore","jsx","TrackingPixel","Skeleton"],"mappings":";;;AAUO,SAASA,EAAW,EAAC,kBAAAC,GAAkB,WAAAC,KAAmB;AAK/D,SACG,gBAAAC,EAAAC,GAAA,EAAc,cAAcF,GAAY,UALhBD,KACxB,gBAAAE,EAAAE,GAAA,EAAS,WAAU,mBAAkB,GAIsB;AAEhE;"}
@@ -0,0 +1,32 @@
1
+ import { jsx as m } from "react/jsx-runtime";
2
+ import { useCallback as n } from "react";
3
+ import { InView as c } from "../../shop-minis-react/node_modules/.pnpm/react-intersection-observer@9.16.0_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-intersection-observer/dist/index.js";
4
+ const x = ({
5
+ children: o,
6
+ onImpression: r,
7
+ triggerOnce: i = !1,
8
+ threshold: t,
9
+ className: a
10
+ }) => {
11
+ const e = n(
12
+ (f) => {
13
+ f && r?.();
14
+ },
15
+ [r]
16
+ );
17
+ return /* @__PURE__ */ m(
18
+ c,
19
+ {
20
+ as: "div",
21
+ onChange: e,
22
+ triggerOnce: i,
23
+ className: a,
24
+ threshold: t,
25
+ children: o
26
+ }
27
+ );
28
+ };
29
+ export {
30
+ x as TrackingPixel
31
+ };
32
+ //# sourceMappingURL=tracking-pixel.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tracking-pixel.js","sources":["../../../src/components/atoms/tracking-pixel.tsx"],"sourcesContent":["import {useCallback} from 'react'\n\nimport {InView} from 'react-intersection-observer'\n\ninterface Props {\n children: React.ReactNode\n onImpression?: () => void\n triggerOnce?: boolean\n threshold?: number\n className?: string\n}\n\nexport const TrackingPixel = ({\n children,\n onImpression,\n triggerOnce = false,\n threshold,\n className,\n}: Props) => {\n const onChange = useCallback(\n (inView: boolean) => {\n if (inView) {\n onImpression?.()\n }\n },\n [onImpression]\n )\n\n return (\n <InView\n as=\"div\"\n onChange={onChange}\n triggerOnce={triggerOnce}\n className={className}\n threshold={threshold}\n >\n {children}\n </InView>\n )\n}\n"],"names":["TrackingPixel","children","onImpression","triggerOnce","threshold","className","onChange","useCallback","inView","jsx","InView"],"mappings":";;;AAYO,MAAMA,IAAgB,CAAC;AAAA,EAC5B,UAAAC;AAAA,EACA,cAAAC;AAAA,EACA,aAAAC,IAAc;AAAA,EACd,WAAAC;AAAA,EACA,WAAAC;AACF,MAAa;AACX,QAAMC,IAAWC;AAAA,IACf,CAACC,MAAoB;AACnB,MAAIA,KACaN,IAAA;AAAA,IAEnB;AAAA,IACA,CAACA,CAAY;AAAA,EACf;AAGE,SAAA,gBAAAO;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,IAAG;AAAA,MACH,UAAAJ;AAAA,MACA,aAAAH;AAAA,MACA,WAAAE;AAAA,MACA,WAAAD;AAAA,MAEC,UAAAH;AAAA,IAAA;AAAA,EACH;AAEJ;"}
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { DATA_NAVIGATION_TYPE_ATTRIBUTE as o, NAVIGATION_TYPES as t } from "./types/index.js";
2
- import { MinisContainer as l } from "./components/MinisContainer.js";
2
+ import { MinisContainer as i } from "./components/MinisContainer.js";
3
3
  import { ProductCard as p } from "./components/commerce/product-card.js";
4
4
  import { ProductLink as m } from "./components/commerce/product-link.js";
5
5
  import { MerchantCard as u, MerchantCardPrimitive as x } from "./components/commerce/merchant-card.js";
@@ -13,206 +13,208 @@ import { IconButton as v } from "./components/atoms/icon-button.js";
13
13
  import { ThumbhashImage as k } from "./components/atoms/thumbhash-image.js";
14
14
  import { Touchable as F } from "./components/atoms/touchable.js";
15
15
  import { AlertDialogAtom as M } from "./components/atoms/alert-dialog.js";
16
- import { Accordion as B, AccordionContent as L, AccordionItem as y, AccordionTrigger as G } from "./components/ui/accordion.js";
17
- import { Alert as O, AlertDescription as U, AlertTitle as V } from "./components/ui/alert.js";
18
- import { AlertDialog as z, AlertDialogAction as Y, AlertDialogCancel as W, AlertDialogContent as j, AlertDialogDescription as q, AlertDialogFooter as J, AlertDialogHeader as K, AlertDialogOverlay as Q, AlertDialogPortal as X, AlertDialogTitle as Z, AlertDialogTrigger as $ } from "./components/ui/alert-dialog.js";
19
- import { Avatar as er, AvatarFallback as or, AvatarImage as tr } from "./components/ui/avatar.js";
20
- import { Card as lr, CardAction as ir, CardContent as pr, CardDescription as sr, CardFooter as mr, CardHeader as nr, CardTitle as ur } from "./components/ui/card.js";
21
- import { Carousel as fr, CarouselContent as cr, CarouselItem as dr, CarouselNext as Sr, CarouselPrevious as gr } from "./components/ui/carousel.js";
22
- import { Checkbox as Ar } from "./components/ui/checkbox.js";
23
- import { Dialog as Pr, DialogClose as Tr, DialogContent as hr, DialogDescription as Ir, DialogFooter as wr, DialogHeader as vr, DialogOverlay as br, DialogPortal as kr, DialogTitle as Er, DialogTrigger as Fr } from "./components/ui/dialog.js";
24
- import { Drawer as Mr, DrawerClose as Nr, DrawerContent as Br, DrawerDescription as Lr, DrawerFooter as yr, DrawerHeader as Gr, DrawerOverlay as Hr, DrawerPortal as Or, DrawerTitle as Ur, DrawerTrigger as Vr } from "./components/ui/drawer.js";
25
- import { Input as zr } from "./components/ui/input.js";
26
- import { Label as Wr } from "./components/ui/label.js";
27
- import { Progress as qr } from "./components/ui/progress.js";
28
- import { RadioGroup as Kr, RadioGroupItem as Qr } from "./components/ui/radio-group.js";
29
- import { ResizableHandle as Zr, ResizablePanel as $r, ResizablePanelGroup as re } from "./components/ui/resizable.js";
30
- import { ScrollArea as oe, ScrollBar as te } from "./components/ui/scroll-area.js";
31
- import { Select as le, SelectContent as ie, SelectGroup as pe, SelectItem as se, SelectLabel as me, SelectScrollDownButton as ne, SelectScrollUpButton as ue, SelectSeparator as xe, SelectTrigger as fe, SelectValue as ce } from "./components/ui/select.js";
32
- import { Separator as Se } from "./components/ui/separator.js";
33
- import { Sheet as De, SheetClose as Ae, SheetContent as Ce, SheetDescription as Pe, SheetFooter as Te, SheetHeader as he, SheetTitle as Ie, SheetTrigger as we } from "./components/ui/sheet.js";
34
- import { Toaster as be } from "./components/ui/sonner.js";
35
- import { Skeleton as Ee } from "./components/ui/skeleton.js";
36
- import { useRecentProducts as Re } from "./hooks/user/useRecentProducts.js";
37
- import { useRecentShops as Ne } from "./hooks/user/useRecentShops.js";
38
- import { useSavedProducts as Le } from "./hooks/user/useSavedProducts.js";
39
- import { useSavedProductsActions as Ge } from "./hooks/user/useSavedProductsActions.js";
40
- import { useFollowedShops as Oe } from "./hooks/user/useFollowedShops.js";
41
- import { useFollowedShopsActions as Ve } from "./hooks/user/useFollowedShopsActions.js";
42
- import { useCurrentUser as ze } from "./hooks/user/useCurrentUser.js";
43
- import { useOrders as We } from "./hooks/user/useOrders.js";
44
- import { useBuyerAttributes as qe } from "./hooks/user/useBuyerAttributes.js";
45
- import { useProductListActions as Ke } from "./hooks/product/useProductListActions.js";
46
- import { useProductLists as Xe } from "./hooks/product/useProductLists.js";
47
- import { useProductList as $e } from "./hooks/product/useProductList.js";
48
- import { useProduct as eo } from "./hooks/product/useProduct.js";
49
- import { useProducts as to } from "./hooks/product/useProducts.js";
50
- import { useProductVariants as lo } from "./hooks/product/useProductVariants.js";
51
- import { useProductMedia as po } from "./hooks/product/useProductMedia.js";
52
- import { useProductSearch as mo } from "./hooks/product/useProductSearch.js";
53
- import { useRecommendedProducts as uo } from "./hooks/product/useRecommendedProducts.js";
54
- import { usePopularProducts as fo } from "./hooks/product/usePopularProducts.js";
55
- import { useCuratedProducts as So } from "./hooks/product/useCuratedProducts.js";
56
- import { useAsyncStorage as Do } from "./hooks/storage/useAsyncStorage.js";
57
- import { useSecureStorage as Co } from "./hooks/storage/useSecureStorage.js";
58
- import { useImageUpload as To } from "./hooks/storage/useImageUpload.js";
59
- import { useShopNavigation as Io } from "./hooks/navigation/useShopNavigation.js";
60
- import { useCloseMini as vo } from "./hooks/navigation/useCloseMini.js";
61
- import { useDeeplink as ko } from "./hooks/navigation/useDeeplink.js";
62
- import { useNavigateWithTransition as Fo } from "./hooks/navigation/useNavigateWithTransition.js";
63
- import { useShop as Mo } from "./hooks/shop/useShop.js";
64
- import { useShopCartActions as Bo } from "./hooks/shop/useShopCartActions.js";
65
- import { useRecommendedShops as yo } from "./hooks/shop/useRecommendedShops.js";
66
- import { useErrorToast as Ho } from "./hooks/util/useErrorToast.js";
67
- import { useErrorScreen as Uo } from "./hooks/util/useErrorScreen.js";
68
- import { useShare as _o } from "./hooks/util/useShare.js";
69
- import { useImagePicker as Yo } from "./hooks/util/useImagePicker.js";
70
- import { MiniEntityNotFoundError as jo, MiniError as qo, MiniNetworkError as Jo, formatError as Ko } from "./utils/errors.js";
71
- import { parseUrl as Xo } from "./utils/parseUrl.js";
72
- import { Consent as $o, ConsentStatus as rt } from "./shop-minis-platform/src/types/permissions.js";
16
+ import { List as B } from "./components/atoms/list.js";
17
+ import { Accordion as y, AccordionContent as G, AccordionItem as H, AccordionTrigger as O } from "./components/ui/accordion.js";
18
+ import { Alert as V, AlertDescription as _, AlertTitle as z } from "./components/ui/alert.js";
19
+ import { AlertDialog as W, AlertDialogAction as j, AlertDialogCancel as q, AlertDialogContent as J, AlertDialogDescription as K, AlertDialogFooter as Q, AlertDialogHeader as X, AlertDialogOverlay as Z, AlertDialogPortal as $, AlertDialogTitle as rr, AlertDialogTrigger as er } from "./components/ui/alert-dialog.js";
20
+ import { Avatar as tr, AvatarFallback as ar, AvatarImage as ir } from "./components/ui/avatar.js";
21
+ import { Card as pr, CardAction as sr, CardContent as mr, CardDescription as nr, CardFooter as ur, CardHeader as xr, CardTitle as fr } from "./components/ui/card.js";
22
+ import { Carousel as dr, CarouselContent as Sr, CarouselItem as gr, CarouselNext as Dr, CarouselPrevious as Ar } from "./components/ui/carousel.js";
23
+ import { Checkbox as Pr } from "./components/ui/checkbox.js";
24
+ import { Dialog as hr, DialogClose as Ir, DialogContent as wr, DialogDescription as vr, DialogFooter as br, DialogHeader as kr, DialogOverlay as Er, DialogPortal as Fr, DialogTitle as Rr, DialogTrigger as Mr } from "./components/ui/dialog.js";
25
+ import { Drawer as Br, DrawerClose as Lr, DrawerContent as yr, DrawerDescription as Gr, DrawerFooter as Hr, DrawerHeader as Or, DrawerOverlay as Ur, DrawerPortal as Vr, DrawerTitle as _r, DrawerTrigger as zr } from "./components/ui/drawer.js";
26
+ import { Input as Wr } from "./components/ui/input.js";
27
+ import { Label as qr } from "./components/ui/label.js";
28
+ import { Progress as Kr } from "./components/ui/progress.js";
29
+ import { RadioGroup as Xr, RadioGroupItem as Zr } from "./components/ui/radio-group.js";
30
+ import { ResizableHandle as re, ResizablePanel as ee, ResizablePanelGroup as oe } from "./components/ui/resizable.js";
31
+ import { ScrollArea as ae, ScrollBar as ie } from "./components/ui/scroll-area.js";
32
+ import { Select as pe, SelectContent as se, SelectGroup as me, SelectItem as ne, SelectLabel as ue, SelectScrollDownButton as xe, SelectScrollUpButton as fe, SelectSeparator as ce, SelectTrigger as de, SelectValue as Se } from "./components/ui/select.js";
33
+ import { Separator as De } from "./components/ui/separator.js";
34
+ import { Sheet as Ce, SheetClose as Pe, SheetContent as Te, SheetDescription as he, SheetFooter as Ie, SheetHeader as we, SheetTitle as ve, SheetTrigger as be } from "./components/ui/sheet.js";
35
+ import { Toaster as Ee } from "./components/ui/sonner.js";
36
+ import { Skeleton as Re } from "./components/ui/skeleton.js";
37
+ import { useRecentProducts as Ne } from "./hooks/user/useRecentProducts.js";
38
+ import { useRecentShops as Le } from "./hooks/user/useRecentShops.js";
39
+ import { useSavedProducts as Ge } from "./hooks/user/useSavedProducts.js";
40
+ import { useSavedProductsActions as Oe } from "./hooks/user/useSavedProductsActions.js";
41
+ import { useFollowedShops as Ve } from "./hooks/user/useFollowedShops.js";
42
+ import { useFollowedShopsActions as ze } from "./hooks/user/useFollowedShopsActions.js";
43
+ import { useCurrentUser as We } from "./hooks/user/useCurrentUser.js";
44
+ import { useOrders as qe } from "./hooks/user/useOrders.js";
45
+ import { useBuyerAttributes as Ke } from "./hooks/user/useBuyerAttributes.js";
46
+ import { useProductListActions as Xe } from "./hooks/product/useProductListActions.js";
47
+ import { useProductLists as $e } from "./hooks/product/useProductLists.js";
48
+ import { useProductList as eo } from "./hooks/product/useProductList.js";
49
+ import { useProduct as to } from "./hooks/product/useProduct.js";
50
+ import { useProducts as io } from "./hooks/product/useProducts.js";
51
+ import { useProductVariants as po } from "./hooks/product/useProductVariants.js";
52
+ import { useProductMedia as mo } from "./hooks/product/useProductMedia.js";
53
+ import { useProductSearch as uo } from "./hooks/product/useProductSearch.js";
54
+ import { useRecommendedProducts as fo } from "./hooks/product/useRecommendedProducts.js";
55
+ import { usePopularProducts as So } from "./hooks/product/usePopularProducts.js";
56
+ import { useCuratedProducts as Do } from "./hooks/product/useCuratedProducts.js";
57
+ import { useAsyncStorage as Co } from "./hooks/storage/useAsyncStorage.js";
58
+ import { useSecureStorage as To } from "./hooks/storage/useSecureStorage.js";
59
+ import { useImageUpload as Io } from "./hooks/storage/useImageUpload.js";
60
+ import { useShopNavigation as vo } from "./hooks/navigation/useShopNavigation.js";
61
+ import { useCloseMini as ko } from "./hooks/navigation/useCloseMini.js";
62
+ import { useDeeplink as Fo } from "./hooks/navigation/useDeeplink.js";
63
+ import { useNavigateWithTransition as Mo } from "./hooks/navigation/useNavigateWithTransition.js";
64
+ import { useShop as Bo } from "./hooks/shop/useShop.js";
65
+ import { useShopCartActions as yo } from "./hooks/shop/useShopCartActions.js";
66
+ import { useRecommendedShops as Ho } from "./hooks/shop/useRecommendedShops.js";
67
+ import { useErrorToast as Uo } from "./hooks/util/useErrorToast.js";
68
+ import { useErrorScreen as _o } from "./hooks/util/useErrorScreen.js";
69
+ import { useShare as Yo } from "./hooks/util/useShare.js";
70
+ import { useImagePicker as jo } from "./hooks/util/useImagePicker.js";
71
+ import { MiniEntityNotFoundError as Jo, MiniError as Ko, MiniNetworkError as Qo, formatError as Xo } from "./utils/errors.js";
72
+ import { parseUrl as $o } from "./utils/parseUrl.js";
73
+ import { Consent as et, ConsentStatus as ot } from "./shop-minis-platform/src/types/permissions.js";
73
74
  export {
74
- B as Accordion,
75
- L as AccordionContent,
76
- y as AccordionItem,
77
- G as AccordionTrigger,
78
- O as Alert,
79
- U as AlertDescription,
80
- z as AlertDialog,
81
- Y as AlertDialogAction,
75
+ y as Accordion,
76
+ G as AccordionContent,
77
+ H as AccordionItem,
78
+ O as AccordionTrigger,
79
+ V as Alert,
80
+ _ as AlertDescription,
81
+ W as AlertDialog,
82
+ j as AlertDialogAction,
82
83
  M as AlertDialogAtom,
83
- W as AlertDialogCancel,
84
- j as AlertDialogContent,
85
- q as AlertDialogDescription,
86
- J as AlertDialogFooter,
87
- K as AlertDialogHeader,
88
- Q as AlertDialogOverlay,
89
- X as AlertDialogPortal,
90
- Z as AlertDialogTitle,
91
- $ as AlertDialogTrigger,
92
- V as AlertTitle,
93
- er as Avatar,
94
- or as AvatarFallback,
95
- tr as AvatarImage,
84
+ q as AlertDialogCancel,
85
+ J as AlertDialogContent,
86
+ K as AlertDialogDescription,
87
+ Q as AlertDialogFooter,
88
+ X as AlertDialogHeader,
89
+ Z as AlertDialogOverlay,
90
+ $ as AlertDialogPortal,
91
+ rr as AlertDialogTitle,
92
+ er as AlertDialogTrigger,
93
+ z as AlertTitle,
94
+ tr as Avatar,
95
+ ar as AvatarFallback,
96
+ ir as AvatarImage,
96
97
  T as Button,
97
- lr as Card,
98
- ir as CardAction,
99
- pr as CardContent,
100
- sr as CardDescription,
101
- mr as CardFooter,
102
- nr as CardHeader,
103
- ur as CardTitle,
104
- fr as Carousel,
105
- cr as CarouselContent,
106
- dr as CarouselItem,
107
- Sr as CarouselNext,
108
- gr as CarouselPrevious,
109
- Ar as Checkbox,
110
- $o as Consent,
111
- rt as ConsentStatus,
98
+ pr as Card,
99
+ sr as CardAction,
100
+ mr as CardContent,
101
+ nr as CardDescription,
102
+ ur as CardFooter,
103
+ xr as CardHeader,
104
+ fr as CardTitle,
105
+ dr as Carousel,
106
+ Sr as CarouselContent,
107
+ gr as CarouselItem,
108
+ Dr as CarouselNext,
109
+ Ar as CarouselPrevious,
110
+ Pr as Checkbox,
111
+ et as Consent,
112
+ ot as ConsentStatus,
112
113
  o as DATA_NAVIGATION_TYPE_ATTRIBUTE,
113
- Pr as Dialog,
114
- Tr as DialogClose,
115
- hr as DialogContent,
116
- Ir as DialogDescription,
117
- wr as DialogFooter,
118
- vr as DialogHeader,
119
- br as DialogOverlay,
120
- kr as DialogPortal,
121
- Er as DialogTitle,
122
- Fr as DialogTrigger,
123
- Mr as Drawer,
124
- Nr as DrawerClose,
125
- Br as DrawerContent,
126
- Lr as DrawerDescription,
127
- yr as DrawerFooter,
128
- Gr as DrawerHeader,
129
- Hr as DrawerOverlay,
130
- Or as DrawerPortal,
131
- Ur as DrawerTitle,
132
- Vr as DrawerTrigger,
114
+ hr as Dialog,
115
+ Ir as DialogClose,
116
+ wr as DialogContent,
117
+ vr as DialogDescription,
118
+ br as DialogFooter,
119
+ kr as DialogHeader,
120
+ Er as DialogOverlay,
121
+ Fr as DialogPortal,
122
+ Rr as DialogTitle,
123
+ Mr as DialogTrigger,
124
+ Br as Drawer,
125
+ Lr as DrawerClose,
126
+ yr as DrawerContent,
127
+ Gr as DrawerDescription,
128
+ Hr as DrawerFooter,
129
+ Or as DrawerHeader,
130
+ Ur as DrawerOverlay,
131
+ Vr as DrawerPortal,
132
+ _r as DrawerTitle,
133
+ zr as DrawerTrigger,
133
134
  I as FavoriteButton,
134
135
  v as IconButton,
135
- zr as Input,
136
- Wr as Label,
136
+ Wr as Input,
137
+ qr as Label,
138
+ B as List,
137
139
  u as MerchantCard,
138
140
  x as MerchantCardPrimitive,
139
141
  S as MerchantCardSkeleton,
140
- jo as MiniEntityNotFoundError,
141
- qo as MiniError,
142
- Jo as MiniNetworkError,
143
- l as MinisContainer,
142
+ Jo as MiniEntityNotFoundError,
143
+ Ko as MiniError,
144
+ Qo as MiniNetworkError,
145
+ i as MinisContainer,
144
146
  t as NAVIGATION_TYPES,
145
147
  p as ProductCard,
146
148
  c as ProductCardSkeleton,
147
149
  m as ProductLink,
148
- qr as Progress,
149
- Kr as RadioGroup,
150
- Qr as RadioGroupItem,
151
- Zr as ResizableHandle,
152
- $r as ResizablePanel,
153
- re as ResizablePanelGroup,
154
- oe as ScrollArea,
155
- te as ScrollBar,
156
- le as Select,
157
- ie as SelectContent,
158
- pe as SelectGroup,
159
- se as SelectItem,
160
- me as SelectLabel,
161
- ne as SelectScrollDownButton,
162
- ue as SelectScrollUpButton,
163
- xe as SelectSeparator,
164
- fe as SelectTrigger,
165
- ce as SelectValue,
166
- Se as Separator,
167
- De as Sheet,
168
- Ae as SheetClose,
169
- Ce as SheetContent,
170
- Pe as SheetDescription,
171
- Te as SheetFooter,
172
- he as SheetHeader,
173
- Ie as SheetTitle,
174
- we as SheetTrigger,
175
- Ee as Skeleton,
150
+ Kr as Progress,
151
+ Xr as RadioGroup,
152
+ Zr as RadioGroupItem,
153
+ re as ResizableHandle,
154
+ ee as ResizablePanel,
155
+ oe as ResizablePanelGroup,
156
+ ae as ScrollArea,
157
+ ie as ScrollBar,
158
+ pe as Select,
159
+ se as SelectContent,
160
+ me as SelectGroup,
161
+ ne as SelectItem,
162
+ ue as SelectLabel,
163
+ xe as SelectScrollDownButton,
164
+ fe as SelectScrollUpButton,
165
+ ce as SelectSeparator,
166
+ de as SelectTrigger,
167
+ Se as SelectValue,
168
+ De as Separator,
169
+ Ce as Sheet,
170
+ Pe as SheetClose,
171
+ Te as SheetContent,
172
+ he as SheetDescription,
173
+ Ie as SheetFooter,
174
+ we as SheetHeader,
175
+ ve as SheetTitle,
176
+ be as SheetTrigger,
177
+ Re as Skeleton,
176
178
  k as ThumbhashImage,
177
- be as Toaster,
179
+ Ee as Toaster,
178
180
  F as Touchable,
179
181
  D as TransitionContainer,
180
182
  C as TransitionLink,
181
- Ko as formatError,
182
- Xo as parseUrl,
183
- Do as useAsyncStorage,
184
- qe as useBuyerAttributes,
185
- vo as useCloseMini,
186
- So as useCuratedProducts,
187
- ze as useCurrentUser,
188
- ko as useDeeplink,
189
- Uo as useErrorScreen,
190
- Ho as useErrorToast,
191
- Oe as useFollowedShops,
192
- Ve as useFollowedShopsActions,
193
- Yo as useImagePicker,
194
- To as useImageUpload,
195
- Fo as useNavigateWithTransition,
196
- We as useOrders,
197
- fo as usePopularProducts,
198
- eo as useProduct,
199
- $e as useProductList,
200
- Ke as useProductListActions,
201
- Xe as useProductLists,
202
- po as useProductMedia,
203
- mo as useProductSearch,
204
- lo as useProductVariants,
205
- to as useProducts,
206
- Re as useRecentProducts,
207
- Ne as useRecentShops,
208
- uo as useRecommendedProducts,
209
- yo as useRecommendedShops,
210
- Le as useSavedProducts,
211
- Ge as useSavedProductsActions,
212
- Co as useSecureStorage,
213
- _o as useShare,
214
- Mo as useShop,
215
- Bo as useShopCartActions,
216
- Io as useShopNavigation
183
+ Xo as formatError,
184
+ $o as parseUrl,
185
+ Co as useAsyncStorage,
186
+ Ke as useBuyerAttributes,
187
+ ko as useCloseMini,
188
+ Do as useCuratedProducts,
189
+ We as useCurrentUser,
190
+ Fo as useDeeplink,
191
+ _o as useErrorScreen,
192
+ Uo as useErrorToast,
193
+ Ve as useFollowedShops,
194
+ ze as useFollowedShopsActions,
195
+ jo as useImagePicker,
196
+ Io as useImageUpload,
197
+ Mo as useNavigateWithTransition,
198
+ qe as useOrders,
199
+ So as usePopularProducts,
200
+ to as useProduct,
201
+ eo as useProductList,
202
+ Xe as useProductListActions,
203
+ $e as useProductLists,
204
+ mo as useProductMedia,
205
+ uo as useProductSearch,
206
+ po as useProductVariants,
207
+ io as useProducts,
208
+ Ne as useRecentProducts,
209
+ Le as useRecentShops,
210
+ fo as useRecommendedProducts,
211
+ Ho as useRecommendedShops,
212
+ Ge as useSavedProducts,
213
+ Oe as useSavedProductsActions,
214
+ To as useSecureStorage,
215
+ Yo as useShare,
216
+ Bo as useShop,
217
+ yo as useShopCartActions,
218
+ vo as useShopNavigation
217
219
  };
218
220
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"useShopActions.js","sources":["../../src/internal/useShopActions.ts"],"sourcesContent":["import {ShopActions} from '../types'\n\nexport function useShopActions(): ShopActions {\n return window.minisSDK\n}\n"],"names":["useShopActions"],"mappings":"AAEO,SAASA,IAA8B;AAC5C,SAAO,OAAO;AAChB;"}
1
+ {"version":3,"file":"useShopActions.js","sources":["../../src/internal/useShopActions.ts"],"sourcesContent":["import {ShopActions} from '@shopify/shop-minis-platform/actions'\n\nexport function useShopActions(): ShopActions {\n return window.minisSDK\n}\n"],"names":["useShopActions"],"mappings":"AAEO,SAASA,IAA8B;AAC5C,SAAO,OAAO;AAChB;"}