cloudcommerce 0.0.71 → 0.0.72

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 (69) hide show
  1. package/.eslintrc.cjs +1 -0
  2. package/CHANGELOG.md +16 -0
  3. package/package.json +2 -2
  4. package/packages/api/package.json +1 -1
  5. package/packages/apps/correios/package.json +1 -1
  6. package/packages/apps/custom-shipping/package.json +1 -1
  7. package/packages/apps/discounts/package.json +1 -1
  8. package/packages/apps/frenet/CHANGELOG.md +1 -0
  9. package/packages/apps/frenet/README.md +1 -0
  10. package/packages/apps/frenet/lib/frenet.d.ts +2 -0
  11. package/packages/apps/frenet/lib/frenet.js +6 -0
  12. package/packages/apps/frenet/lib/frenet.js.map +1 -0
  13. package/packages/apps/frenet/lib/index.d.ts +1 -0
  14. package/packages/apps/frenet/lib/index.js +2 -0
  15. package/packages/apps/frenet/lib/index.js.map +1 -0
  16. package/packages/apps/frenet/lib-mjs/calculate-frenet.mjs +152 -0
  17. package/packages/apps/frenet/package.json +28 -0
  18. package/packages/apps/frenet/src/frenet.ts +7 -0
  19. package/packages/apps/frenet/src/index.ts +1 -0
  20. package/packages/apps/frenet/tsconfig.json +6 -0
  21. package/packages/apps/tiny-erp/package.json +1 -1
  22. package/packages/cli/package.json +1 -1
  23. package/packages/config/lib/config.js +9 -8
  24. package/packages/config/lib/config.js.map +1 -1
  25. package/packages/config/package.json +1 -1
  26. package/packages/config/src/config.ts +11 -10
  27. package/packages/events/package.json +1 -1
  28. package/packages/firebase/lib/config.d.ts +3 -0
  29. package/packages/firebase/lib/config.js +3 -0
  30. package/packages/firebase/lib/config.js.map +1 -1
  31. package/packages/firebase/package.json +1 -1
  32. package/packages/firebase/src/config.ts +3 -0
  33. package/packages/modules/lib/firebase/call-app-module.js +5 -0
  34. package/packages/modules/lib/firebase/call-app-module.js.map +1 -1
  35. package/packages/modules/package.json +2 -1
  36. package/packages/modules/src/firebase/call-app-module.ts +5 -0
  37. package/packages/passport/package.json +1 -1
  38. package/packages/ssr/lib/firebase/serve-storefront.js +6 -5
  39. package/packages/ssr/lib/firebase/serve-storefront.js.map +1 -1
  40. package/packages/ssr/package.json +1 -1
  41. package/packages/ssr/src/firebase/serve-storefront.ts +6 -5
  42. package/packages/storefront/dist/client/assets/{404-_...d4aa8aff.css → 404-500-_...d4aa8aff.css} +0 -0
  43. package/packages/storefront/dist/client/assets/{404-index.d9230d24.css → 404-500-index.d9230d24.css} +0 -0
  44. package/packages/storefront/dist/client/assets/{index.53a3a3e0.css → 404.b3ead908.css} +1 -1
  45. package/packages/storefront/dist/client/assets/{404.530428e5.css → 500.d5d7700b.css} +1 -1
  46. package/packages/storefront/dist/client/assets/{_...98510c96.css → _...c08e0a75.css} +1 -1
  47. package/packages/storefront/dist/client/assets/index.9745690c.css +1 -0
  48. package/packages/storefront/dist/server/entry.mjs +398 -115
  49. package/packages/storefront/package.json +3 -3
  50. package/packages/storefront/src/env.d.ts +1 -0
  51. package/packages/storefront/src/{components → lib/components}/Card.astro +0 -0
  52. package/packages/storefront/src/lib/components/LoginModal.vue +56 -0
  53. package/packages/storefront/src/{layouts → lib/layouts}/Layout.astro +8 -11
  54. package/packages/storefront/src/lib/layouts/meta/Head.astro +7 -0
  55. package/packages/storefront/src/lib/layouts/meta/Json.astro +34 -0
  56. package/packages/storefront/src/lib/ssr-context.ts +107 -0
  57. package/packages/storefront/src/lib/views/404.astro +79 -0
  58. package/packages/storefront/src/lib/views/500.astro +79 -0
  59. package/packages/storefront/src/lib/views/[...slug].astro +77 -0
  60. package/packages/storefront/src/lib/views/app/index.astro +0 -0
  61. package/packages/storefront/src/lib/views/index.astro +87 -0
  62. package/packages/storefront/src/pages/404.astro +10 -71
  63. package/packages/storefront/src/pages/500.astro +13 -0
  64. package/packages/storefront/src/pages/[...slug].astro +7 -76
  65. package/packages/storefront/src/pages/index.astro +10 -79
  66. package/packages/storefront/storefront.config.mjs +23 -6
  67. package/packages/storefront/tsconfig.json +4 -1
  68. package/packages/types/package.json +1 -1
  69. package/packages/storefront/src/types.ts +0 -18
@@ -2,11 +2,11 @@ import * as adapter from '@astrojs/node/server.js';
2
2
  import { defineComponent, h, createSSRApp } from 'vue';
3
3
  import { renderToString as renderToString$1 } from 'vue/server-renderer';
4
4
  import { escape } from 'html-escaper';
5
- /* empty css *//* empty css */import { fileURLToPath } from 'url';
6
- import { readFileSync } from 'fs';
5
+ /* empty css *//* empty css */import { fileURLToPath } from 'url';
6
+ import fs from 'fs';
7
7
  import { resolve } from 'path';
8
8
  import Deepmerge from '@fastify/deepmerge';
9
- /* empty css *//* empty css *//* empty css */import 'mime';
9
+ /* empty css *//* empty css *//* empty css *//* empty css */import 'mime';
10
10
  import 'kleur/colors';
11
11
  import 'string-width';
12
12
  import 'path-browserify';
@@ -1430,7 +1430,7 @@ api.del = del;
1430
1430
  api.delete = del;
1431
1431
  // # sourceMappingURL=api.js.map
1432
1432
 
1433
- const $$module1 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1433
+ const $$module1$5 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1434
1434
  __proto__: null,
1435
1435
  default: api,
1436
1436
  setMiddleware,
@@ -1457,19 +1457,20 @@ const _env = (Object.assign({"BASE_URL":"/","MODE":"production","DEV":false,"PRO
1457
1457
  || globalThis;
1458
1458
  const deepmerge = Deepmerge();
1459
1459
  const self = globalThis.__cloudCommerce || {
1460
- config: {
1461
- lang: _env.ECOM_LANG || DEFAULT_LANG,
1462
- currency: _env.ECOM_CURRENCY || DEFAULT_CURRENCY,
1463
- currencySymbol: _env.ECOM_CURRENCY_SYMBOL || DEFAULT_CURRENCY_SYMBOL,
1464
- countryCode: _env.ECOM_COUNTRY_CODE || DEFAULT_COUNTRY_CODE,
1465
- storeId: Number(_env.ECOM_STORE_ID),
1466
- },
1460
+ config: {},
1467
1461
  };
1468
1462
  globalThis.__cloudCommerce = self;
1469
1463
 
1470
1464
  const config = {
1471
1465
  get() {
1472
- return self.config;
1466
+ return {
1467
+ lang: _env.ECOM_LANG || DEFAULT_LANG,
1468
+ currency: _env.ECOM_CURRENCY || DEFAULT_CURRENCY,
1469
+ currencySymbol: _env.ECOM_CURRENCY_SYMBOL || DEFAULT_CURRENCY_SYMBOL,
1470
+ countryCode: _env.ECOM_COUNTRY_CODE || DEFAULT_COUNTRY_CODE,
1471
+ storeId: Number(_env.ECOM_STORE_ID),
1472
+ ...self.config,
1473
+ };
1473
1474
  },
1474
1475
  set(config) {
1475
1476
  self.config = deepmerge(self.config, config);
@@ -1480,14 +1481,12 @@ const config = {
1480
1481
  };
1481
1482
  // # sourceMappingURL=config.js.map
1482
1483
 
1483
- const getConfig = () => {
1484
+ const _getConfig = () => {
1484
1485
  const {
1485
1486
  STOREFRONT_BASE_DIR,
1486
1487
  VITE_ECOM_STORE_ID,
1487
1488
  } = (Object.assign({"BASE_URL":"/","MODE":"production","DEV":false,"PROD":true},{STOREFRONT_BASE_DIR:process.env.STOREFRONT_BASE_DIR,ECOM_STORE_ID:process.env.ECOM_STORE_ID,})) || process.env;
1488
1489
 
1489
- const { storeId, lang } = config.get();
1490
-
1491
1490
  let baseDir;
1492
1491
  if (STOREFRONT_BASE_DIR) {
1493
1492
  const currentDir = fileURLToPath(new URL('.', import.meta.url));
@@ -1500,9 +1499,24 @@ const getConfig = () => {
1500
1499
  config.set({ storeId: Number(VITE_ECOM_STORE_ID) });
1501
1500
  }
1502
1501
 
1503
- const settings = JSON.parse(
1504
- readFileSync(resolve(dirContent, 'settings.json'), 'utf8'),
1505
- );
1502
+ const {
1503
+ storeId,
1504
+ lang,
1505
+ countryCode,
1506
+ currency,
1507
+ currencySymbol,
1508
+ } = config.get();
1509
+
1510
+ const cms = (filename) => {
1511
+ if (filename.endsWith('/')) {
1512
+ const dirColl = resolve(dirContent, filename);
1513
+ return fs.readdirSync(dirColl).map((_filename) => _filename.replace('.json', ''));
1514
+ }
1515
+ const filepath = resolve(dirContent, `${filename}.json`);
1516
+ return JSON.parse(fs.readFileSync(filepath, 'utf8'));
1517
+ };
1518
+
1519
+ const settings = cms('settings');
1506
1520
  const { domain } = settings;
1507
1521
  const primaryColor = settings.primary_color || '#20c997';
1508
1522
  const secondaryColor = settings.secondary_color || '#343a40';
@@ -1510,52 +1524,193 @@ const getConfig = () => {
1510
1524
  return {
1511
1525
  storeId,
1512
1526
  lang,
1527
+ countryCode,
1528
+ currency,
1529
+ currencySymbol,
1513
1530
  domain,
1514
1531
  primaryColor,
1515
1532
  secondaryColor,
1516
1533
  settings,
1534
+ cms,
1517
1535
  };
1518
1536
  };
1519
1537
 
1538
+ const getConfig = _getConfig;
1539
+ if (!globalThis.api_prefetch_endpoints) {
1540
+ globalThis.api_prefetch_endpoints = ["categories"];
1541
+ }
1542
+ const loadPageContext = async (Astro, {
1543
+ cmsCollection,
1544
+ apiPrefetchEndpoints = globalThis.api_prefetch_endpoints
1545
+ } = {}) => {
1546
+ const { slug } = Astro.params;
1547
+ const config = getConfig();
1548
+ let cmsContent;
1549
+ let apiResource;
1550
+ let apiDoc;
1551
+ const apiState = {};
1552
+ if (slug) {
1553
+ if (cmsCollection) {
1554
+ cmsContent = config.cms(`${cmsCollection}/${slug}`);
1555
+ } else {
1556
+ const apiOptions = {
1557
+ fetch,
1558
+ isNoAuth: true
1559
+ };
1560
+ const apiFetchings = [
1561
+ api.get(`slugs/${slug}`, apiOptions),
1562
+ ...apiPrefetchEndpoints.map((endpoint) => api.get(endpoint, apiOptions))
1563
+ ];
1564
+ try {
1565
+ const [slugResponse, ...prefetchResponses] = await Promise.all(apiFetchings);
1566
+ apiResource = slugResponse.data.resource;
1567
+ apiDoc = slugResponse.data.doc;
1568
+ apiState[`${apiResource}/${apiDoc._id}`] = apiDoc;
1569
+ prefetchResponses.forEach(({ config: { endpoint }, data }) => {
1570
+ apiState[endpoint] = data;
1571
+ });
1572
+ } catch (e) {
1573
+ const error = e;
1574
+ let toUrl;
1575
+ if (error.statusCode === 404) {
1576
+ toUrl = "/404";
1577
+ Astro.response.headers.set("Cache-Control", "public, max-age=120");
1578
+ } else {
1579
+ console.error(error);
1580
+ toUrl = "/500";
1581
+ Astro.response.headers.set("X-SSR-Error", error.stack);
1582
+ }
1583
+ const err = new Error(`Load page context failed: ${error.message}`);
1584
+ err.originalError = error;
1585
+ err.redirectUrl = `${toUrl}?url=${encodeURIComponent(Astro.url.pathname)}`;
1586
+ err.astroResponse = Astro.redirect(err.redirectUrl);
1587
+ throw err;
1588
+ }
1589
+ }
1590
+ }
1591
+ return {
1592
+ ...config,
1593
+ cmsContent,
1594
+ apiResource,
1595
+ apiDoc,
1596
+ apiState
1597
+ };
1598
+ };
1599
+
1600
+ const $$module2$2 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1601
+ __proto__: null,
1602
+ default: loadPageContext,
1603
+ getConfig,
1604
+ loadPageContext
1605
+ }, Symbol.toStringTag, { value: 'Module' }));
1606
+
1607
+ const $$metadata$c = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/layouts/meta/Head.astro", { modules: [], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1608
+ const $$Astro$c = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/layouts/meta/Head.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1609
+ const $$Head = createComponent(async ($$result, $$props, $$slots) => {
1610
+ const Astro2 = $$result.createAstro($$Astro$c, $$props, $$slots);
1611
+ Astro2.self = $$Head;
1612
+ return renderTemplate`<meta charset="UTF-8">
1613
+ <meta name="viewport" content="width=device-width">
1614
+ <link rel="icon" type="image/x-icon" href="/favicon.ico">
1615
+ `;
1616
+ });
1617
+
1618
+ const $$file$c = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/layouts/meta/Head.astro";
1619
+ const $$url$c = undefined;
1620
+
1520
1621
  const $$module2$1 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1521
1622
  __proto__: null,
1522
- default: getConfig
1623
+ $$metadata: $$metadata$c,
1624
+ default: $$Head,
1625
+ file: $$file$c,
1626
+ url: $$url$c
1523
1627
  }, Symbol.toStringTag, { value: 'Module' }));
1524
1628
 
1525
1629
  var __freeze = Object.freeze;
1526
1630
  var __defProp = Object.defineProperty;
1527
1631
  var __template = (cooked, raw) => __freeze(__defProp(cooked, "raw", { value: __freeze(raw || cooked.slice()) }));
1528
1632
  var _a;
1529
- const $$metadata$5 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/layouts/Layout.astro", { modules: [{ module: $$module2$1, specifier: "../../storefront.config.mjs", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1530
- const $$Astro$5 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/layouts/Layout.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1633
+ const $$metadata$b = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/layouts/meta/Json.astro", { modules: [{ module: $$module2$2, specifier: "../../ssr-context", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1634
+ const $$Astro$b = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/layouts/meta/Json.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1635
+ const $$Json = createComponent(async ($$result, $$props, $$slots) => {
1636
+ const Astro2 = $$result.createAstro($$Astro$b, $$props, $$slots);
1637
+ Astro2.self = $$Json;
1638
+ const {
1639
+ storeId,
1640
+ lang,
1641
+ countryCode,
1642
+ currency,
1643
+ currencySymbol,
1644
+ domain,
1645
+ settings
1646
+ } = getConfig();
1647
+ const inlineClientJS = `
1648
+ window._settings = ${JSON.stringify({
1649
+ ...settings,
1650
+ store_id: storeId,
1651
+ lang,
1652
+ country_code: countryCode,
1653
+ currency,
1654
+ currency_symbol: currencySymbol
1655
+ })};`;
1656
+ const inlineJSONLd = JSON.stringify({
1657
+ "@context": "http://schema.org",
1658
+ "@type": "Organization",
1659
+ name: settings.name,
1660
+ url: `https://${domain}/`,
1661
+ logo: `https://${domain}${settings.logo}`
1662
+ });
1663
+ return renderTemplate(_a || (_a = __template(["<script>", '<\/script>\n<script type="application/ld+json">', "<\/script>\n"])), markHTMLString(inlineClientJS), markHTMLString(inlineJSONLd));
1664
+ });
1665
+
1666
+ const $$file$b = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/layouts/meta/Json.astro";
1667
+ const $$url$b = undefined;
1668
+
1669
+ const $$module3 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1670
+ __proto__: null,
1671
+ $$metadata: $$metadata$b,
1672
+ default: $$Json,
1673
+ file: $$file$b,
1674
+ url: $$url$b
1675
+ }, Symbol.toStringTag, { value: 'Module' }));
1676
+
1677
+ const $$metadata$a = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/layouts/Layout.astro", { modules: [{ module: $$module2$2, specifier: "../ssr-context", assert: {} }, { module: $$module2$1, specifier: "./meta/Head.astro", assert: {} }, { module: $$module3, specifier: "./meta/Json.astro", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1678
+ const $$Astro$a = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/layouts/Layout.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1531
1679
  const $$Layout = createComponent(async ($$result, $$props, $$slots) => {
1532
- const Astro2 = $$result.createAstro($$Astro$5, $$props, $$slots);
1680
+ const Astro2 = $$result.createAstro($$Astro$a, $$props, $$slots);
1533
1681
  Astro2.self = $$Layout;
1534
- const { title } = Astro2.props;
1535
1682
  const { lang } = getConfig();
1683
+ const { title } = Astro2.props;
1536
1684
  const STYLES = [];
1537
1685
  for (const STYLE of STYLES)
1538
1686
  $$result.styles.add(STYLE);
1539
- return renderTemplate(_a || (_a = __template(['<html lang="en" class="astro-DEZ7DR5X">\n<head>\n <meta charset="UTF-8">\n <meta name="viewport" content="width=device-width">\n <link rel="icon" type="image/x-icon" href="/favicon.ico">\n <title>', `</title>
1540
- <link rel="stylesheet" media="print" onload="this.media='all'" href="https://www.gstatic.com/firebasejs/ui/6.0.1/firebase-ui-auth.css">
1541
- `, '</head>\n<body class="astro-DEZ7DR5X">\n ', '\n <script async type="text/partytown"', "><\/script>\n</body>\n</html>\n\n"])), title, renderHead($$result), renderSlot($$result, $$slots["default"]), addAttribute(`https://www.gstatic.com/firebasejs/ui/6.0.1/firebase-ui-auth__${lang}.js`, "src"));
1687
+ return renderTemplate`<html${addAttribute(lang.replace("_", "-"), "lang")} class="astro-6U5GBOCX">
1688
+ <head>
1689
+ ${renderComponent($$result, "MetaHead", $$Head, { "class": "astro-6U5GBOCX" })}
1690
+ <title>${title}</title>
1691
+ ${renderHead($$result)}</head>
1692
+ <body class="astro-6U5GBOCX">
1693
+ ${renderSlot($$result, $$slots["default"])}
1694
+ ${renderComponent($$result, "MetaJson", $$Json, { "class": "astro-6U5GBOCX" })}
1695
+
1696
+ </body></html>`;
1542
1697
  });
1543
1698
 
1544
- const $$file$5 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/layouts/Layout.astro";
1545
- const $$url$5 = undefined;
1699
+ const $$file$a = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/layouts/Layout.astro";
1700
+ const $$url$a = undefined;
1546
1701
 
1547
- const $$module3 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1702
+ const $$module1$4 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1548
1703
  __proto__: null,
1549
- $$metadata: $$metadata$5,
1704
+ $$metadata: $$metadata$a,
1550
1705
  default: $$Layout,
1551
- file: $$file$5,
1552
- url: $$url$5
1706
+ file: $$file$a,
1707
+ url: $$url$a
1553
1708
  }, Symbol.toStringTag, { value: 'Module' }));
1554
1709
 
1555
- const $$metadata$4 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/components/Card.astro", { modules: [], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1556
- const $$Astro$4 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/components/Card.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1710
+ const $$metadata$9 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/components/Card.astro", { modules: [], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1711
+ const $$Astro$9 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/components/Card.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1557
1712
  const $$Card = createComponent(async ($$result, $$props, $$slots) => {
1558
- const Astro2 = $$result.createAstro($$Astro$4, $$props, $$slots);
1713
+ const Astro2 = $$result.createAstro($$Astro$9, $$props, $$slots);
1559
1714
  Astro2.self = $$Card;
1560
1715
  const { href, title, body } = Astro2.props;
1561
1716
  const STYLES = [];
@@ -1575,41 +1730,41 @@ const $$Card = createComponent(async ($$result, $$props, $$slots) => {
1575
1730
  `;
1576
1731
  });
1577
1732
 
1578
- const $$file$4 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/components/Card.astro";
1579
- const $$url$4 = undefined;
1733
+ const $$file$9 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/components/Card.astro";
1734
+ const $$url$9 = undefined;
1580
1735
 
1581
1736
  const $$module2 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1582
1737
  __proto__: null,
1583
- $$metadata: $$metadata$4,
1738
+ $$metadata: $$metadata$9,
1584
1739
  default: $$Card,
1585
- file: $$file$4,
1586
- url: $$url$4
1740
+ file: $$file$9,
1741
+ url: $$url$9
1587
1742
  }, Symbol.toStringTag, { value: 'Module' }));
1588
1743
 
1589
- const $$metadata$3 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/index.astro", { modules: [{ module: $$module1, specifier: "@cloudcommerce/api", assert: {} }, { module: $$module3, specifier: "../layouts/Layout.astro", assert: {} }, { module: $$module2, specifier: "../components/Card.astro", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1590
- const $$Astro$3 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/index.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1591
- const $$Index$1 = createComponent(async ($$result, $$props, $$slots) => {
1592
- const Astro2 = $$result.createAstro($$Astro$3, $$props, $$slots);
1593
- Astro2.self = $$Index$1;
1744
+ const $$metadata$8 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/index.astro", { modules: [{ module: $$module1$5, specifier: "@cloudcommerce/api", assert: {} }, { module: $$module1$4, specifier: "../layouts/Layout.astro", assert: {} }, { module: $$module2, specifier: "../components/Card.astro", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1745
+ const $$Astro$8 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/index.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1746
+ const $$Index$2 = createComponent(async ($$result, $$props, $$slots) => {
1747
+ const Astro2 = $$result.createAstro($$Astro$8, $$props, $$slots);
1748
+ Astro2.self = $$Index$2;
1594
1749
  const products = (await api.get("products")).data.result;
1595
1750
  const STYLES = [];
1596
1751
  for (const STYLE of STYLES)
1597
1752
  $$result.styles.add(STYLE);
1598
- return renderTemplate`${renderComponent($$result, "Layout", $$Layout, { "title": "Welcome to Astro.", "class": "astro-C3E44E3K" }, { "default": () => renderTemplate`${maybeRenderHead($$result)}<main class="astro-C3E44E3K">
1599
- <h1 class="astro-C3E44E3K">Welcome to <span class="text-gradient astro-C3E44E3K">Astro</span></h1>
1600
- <p class="instructions astro-C3E44E3K">
1601
- Check out the <code class="astro-C3E44E3K">src/pages</code> directory to get started.<br class="astro-C3E44E3K">
1602
- <strong class="astro-C3E44E3K">Code Challenge:</strong> Tweak the "Welcome to Astro" message above.
1753
+ return renderTemplate`${renderComponent($$result, "Layout", $$Layout, { "title": "Welcome to Astro.", "class": "astro-FWWSR4V6" }, { "default": () => renderTemplate`${maybeRenderHead($$result)}<main class="astro-FWWSR4V6">
1754
+ <h1 class="astro-FWWSR4V6">Welcome to <span class="text-gradient astro-FWWSR4V6">Astro</span></h1>
1755
+ <p class="instructions astro-FWWSR4V6">
1756
+ Check out the <code class="astro-FWWSR4V6">src/pages</code> directory to get started.<br class="astro-FWWSR4V6">
1757
+ <strong class="astro-FWWSR4V6">Code Challenge:</strong> Tweak the "Welcome to Astro" message above.
1603
1758
  </p>
1604
- <ul role="list" class="link-card-grid astro-C3E44E3K">
1605
- ${renderComponent($$result, "Card", $$Card, { "href": "https://docs.astro.build/", "title": "Documentation", "body": "Learn how Astro works and explore the official API docs.", "class": "astro-C3E44E3K" })}
1606
- ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/integrations/", "title": "Integrations", "body": "Supercharge your project with new frameworks and libraries.", "class": "astro-C3E44E3K" })}
1607
- ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/themes/", "title": "Themes", "body": "Explore a galaxy of community-built starter themes.", "class": "astro-C3E44E3K" })}
1608
- ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/chat/", "title": "Chat", "body": "Come say hi to our amazing Discord community. \u2764\uFE0F", "class": "astro-C3E44E3K" })}
1759
+ <ul role="list" class="link-card-grid astro-FWWSR4V6">
1760
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://docs.astro.build/", "title": "Documentation", "body": "Learn how Astro works and explore the official API docs.", "class": "astro-FWWSR4V6" })}
1761
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/integrations/", "title": "Integrations", "body": "Supercharge your project with new frameworks and libraries.", "class": "astro-FWWSR4V6" })}
1762
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/themes/", "title": "Themes", "body": "Explore a galaxy of community-built starter themes.", "class": "astro-FWWSR4V6" })}
1763
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/chat/", "title": "Chat", "body": "Come say hi to our amazing Discord community. \u2764\uFE0F", "class": "astro-FWWSR4V6" })}
1609
1764
  </ul>
1610
- <ul role="list" class="mt-3 fs-20 astro-C3E44E3K">
1611
- ${products.map((product) => renderTemplate`<li class="astro-C3E44E3K">
1612
- <a${addAttribute(`/${product.slug}`, "href")} class="astro-C3E44E3K">${product.sku}</a>
1765
+ <ul role="list" class="mt-3 fs-20 astro-FWWSR4V6">
1766
+ ${products.map((product) => renderTemplate`<li class="astro-FWWSR4V6">
1767
+ <a${addAttribute(`/${product.slug}`, "href")} class="astro-FWWSR4V6">${product.sku}</a>
1613
1768
  </li>`)}
1614
1769
  </ul>
1615
1770
  </main>` })}
@@ -1617,107 +1772,235 @@ const $$Index$1 = createComponent(async ($$result, $$props, $$slots) => {
1617
1772
  `;
1618
1773
  });
1619
1774
 
1620
- const $$file$3 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/index.astro";
1621
- const $$url$3 = "";
1775
+ const $$file$8 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/index.astro";
1776
+ const $$url$8 = undefined;
1777
+
1778
+ const $$module1$3 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1779
+ __proto__: null,
1780
+ $$metadata: $$metadata$8,
1781
+ default: $$Index$2,
1782
+ file: $$file$8,
1783
+ url: $$url$8
1784
+ }, Symbol.toStringTag, { value: 'Module' }));
1785
+
1786
+ const $$metadata$7 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/index.astro", { modules: [{ module: $$module1$3, specifier: "../lib/views/index.astro", assert: {} }, { module: $$module2$2, specifier: "../lib/ssr-context", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1787
+ const $$Astro$7 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/index.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1788
+ const $$Index$1 = createComponent(async ($$result, $$props, $$slots) => {
1789
+ const Astro2 = $$result.createAstro($$Astro$7, $$props, $$slots);
1790
+ Astro2.self = $$Index$1;
1791
+ let pageContext;
1792
+ try {
1793
+ pageContext = await loadPageContext(Astro2);
1794
+ } catch (err) {
1795
+ return err.astroResponse;
1796
+ }
1797
+ return renderTemplate`${renderComponent($$result, "ViewHome", $$Index$2, { "pageContext": pageContext })}`;
1798
+ });
1799
+
1800
+ const $$file$7 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/index.astro";
1801
+ const $$url$7 = "";
1622
1802
 
1623
1803
  const _page0 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1624
1804
  __proto__: null,
1625
- $$metadata: $$metadata$3,
1805
+ $$metadata: $$metadata$7,
1626
1806
  default: $$Index$1,
1627
- file: $$file$3,
1628
- url: $$url$3
1807
+ file: $$file$7,
1808
+ url: $$url$7
1629
1809
  }, Symbol.toStringTag, { value: 'Module' }));
1630
1810
 
1631
- const $$metadata$2 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/404.astro", { modules: [{ module: $$module3, specifier: "../layouts/Layout.astro", assert: {} }, { module: $$module2, specifier: "../components/Card.astro", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1632
- const $$Astro$2 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/404.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1811
+ const $$metadata$6 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/404.astro", { modules: [{ module: $$module1$4, specifier: "../layouts/Layout.astro", assert: {} }, { module: $$module2, specifier: "../components/Card.astro", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1812
+ const $$Astro$6 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/404.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1813
+ const $$404$1 = createComponent(async ($$result, $$props, $$slots) => {
1814
+ const Astro2 = $$result.createAstro($$Astro$6, $$props, $$slots);
1815
+ Astro2.self = $$404$1;
1816
+ const STYLES = [];
1817
+ for (const STYLE of STYLES)
1818
+ $$result.styles.add(STYLE);
1819
+ return renderTemplate`${renderComponent($$result, "Layout", $$Layout, { "title": "Welcome to Astro.", "class": "astro-DJT3DWAO" }, { "default": () => renderTemplate`${maybeRenderHead($$result)}<main class="astro-DJT3DWAO">
1820
+ <h1 class="astro-DJT3DWAO">404</h1>
1821
+ <p class="instructions astro-DJT3DWAO">
1822
+ Check out the <code class="astro-DJT3DWAO">src/pages</code> directory to get started.<br class="astro-DJT3DWAO">
1823
+ <strong class="astro-DJT3DWAO">Code Challenge:</strong> Tweak the "Welcome to Astro" message above.
1824
+ </p>
1825
+ <ul role="list" class="link-card-grid astro-DJT3DWAO">
1826
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://docs.astro.build/", "title": "Documentation", "body": "Learn how Astro works and explore the official API docs.", "class": "astro-DJT3DWAO" })}
1827
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/integrations/", "title": "Integrations", "body": "Supercharge your project with new frameworks and libraries.", "class": "astro-DJT3DWAO" })}
1828
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/themes/", "title": "Themes", "body": "Explore a galaxy of community-built starter themes.", "class": "astro-DJT3DWAO" })}
1829
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/chat/", "title": "Chat", "body": "Come say hi to our amazing Discord community. \u2764\uFE0F", "class": "astro-DJT3DWAO" })}
1830
+ </ul>
1831
+ </main>` })}
1832
+
1833
+ `;
1834
+ });
1835
+
1836
+ const $$file$6 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/404.astro";
1837
+ const $$url$6 = undefined;
1838
+
1839
+ const $$module1$2 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1840
+ __proto__: null,
1841
+ $$metadata: $$metadata$6,
1842
+ default: $$404$1,
1843
+ file: $$file$6,
1844
+ url: $$url$6
1845
+ }, Symbol.toStringTag, { value: 'Module' }));
1846
+
1847
+ const $$metadata$5 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/404.astro", { modules: [{ module: $$module1$2, specifier: "../lib/views/404.astro", assert: {} }, { module: $$module2$2, specifier: "../lib/ssr-context", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1848
+ const $$Astro$5 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/404.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1633
1849
  const $$404 = createComponent(async ($$result, $$props, $$slots) => {
1634
- const Astro2 = $$result.createAstro($$Astro$2, $$props, $$slots);
1850
+ const Astro2 = $$result.createAstro($$Astro$5, $$props, $$slots);
1635
1851
  Astro2.self = $$404;
1852
+ let pageContext;
1853
+ try {
1854
+ pageContext = await loadPageContext(Astro2);
1855
+ } catch (err) {
1856
+ return err.astroResponse;
1857
+ }
1858
+ return renderTemplate`${renderComponent($$result, "View404", $$404$1, { "pageContext": pageContext })}`;
1859
+ });
1860
+
1861
+ const $$file$5 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/404.astro";
1862
+ const $$url$5 = "/404";
1863
+
1864
+ const _page1 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1865
+ __proto__: null,
1866
+ $$metadata: $$metadata$5,
1867
+ default: $$404,
1868
+ file: $$file$5,
1869
+ url: $$url$5
1870
+ }, Symbol.toStringTag, { value: 'Module' }));
1871
+
1872
+ const $$metadata$4 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/500.astro", { modules: [{ module: $$module1$4, specifier: "../layouts/Layout.astro", assert: {} }, { module: $$module2, specifier: "../components/Card.astro", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1873
+ const $$Astro$4 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/500.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1874
+ const $$500$1 = createComponent(async ($$result, $$props, $$slots) => {
1875
+ const Astro2 = $$result.createAstro($$Astro$4, $$props, $$slots);
1876
+ Astro2.self = $$500$1;
1636
1877
  const STYLES = [];
1637
1878
  for (const STYLE of STYLES)
1638
1879
  $$result.styles.add(STYLE);
1639
- return renderTemplate`${renderComponent($$result, "Layout", $$Layout, { "title": "Welcome to Astro.", "class": "astro-7FYMG5AV" }, { "default": () => renderTemplate`${maybeRenderHead($$result)}<main class="astro-7FYMG5AV">
1640
- <h1 class="astro-7FYMG5AV">404</h1>
1641
- <p class="instructions astro-7FYMG5AV">
1642
- Check out the <code class="astro-7FYMG5AV">src/pages</code> directory to get started.<br class="astro-7FYMG5AV">
1643
- <strong class="astro-7FYMG5AV">Code Challenge:</strong> Tweak the "Welcome to Astro" message above.
1880
+ return renderTemplate`${renderComponent($$result, "Layout", $$Layout, { "title": "Welcome to Astro.", "class": "astro-NR6LLUHL" }, { "default": () => renderTemplate`${maybeRenderHead($$result)}<main class="astro-NR6LLUHL">
1881
+ <h1 class="astro-NR6LLUHL">5xx</h1>
1882
+ <p class="instructions astro-NR6LLUHL">
1883
+ Check out the <code class="astro-NR6LLUHL">src/pages</code> directory to get started.<br class="astro-NR6LLUHL">
1884
+ <strong class="astro-NR6LLUHL">Code Challenge:</strong> Tweak the "Welcome to Astro" message above.
1644
1885
  </p>
1645
- <ul role="list" class="link-card-grid astro-7FYMG5AV">
1646
- ${renderComponent($$result, "Card", $$Card, { "href": "https://docs.astro.build/", "title": "Documentation", "body": "Learn how Astro works and explore the official API docs.", "class": "astro-7FYMG5AV" })}
1647
- ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/integrations/", "title": "Integrations", "body": "Supercharge your project with new frameworks and libraries.", "class": "astro-7FYMG5AV" })}
1648
- ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/themes/", "title": "Themes", "body": "Explore a galaxy of community-built starter themes.", "class": "astro-7FYMG5AV" })}
1649
- ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/chat/", "title": "Chat", "body": "Come say hi to our amazing Discord community. \u2764\uFE0F", "class": "astro-7FYMG5AV" })}
1886
+ <ul role="list" class="link-card-grid astro-NR6LLUHL">
1887
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://docs.astro.build/", "title": "Documentation", "body": "Learn how Astro works and explore the official API docs.", "class": "astro-NR6LLUHL" })}
1888
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/integrations/", "title": "Integrations", "body": "Supercharge your project with new frameworks and libraries.", "class": "astro-NR6LLUHL" })}
1889
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/themes/", "title": "Themes", "body": "Explore a galaxy of community-built starter themes.", "class": "astro-NR6LLUHL" })}
1890
+ ${renderComponent($$result, "Card", $$Card, { "href": "https://astro.build/chat/", "title": "Chat", "body": "Come say hi to our amazing Discord community. \u2764\uFE0F", "class": "astro-NR6LLUHL" })}
1650
1891
  </ul>
1651
1892
  </main>` })}
1652
1893
 
1653
1894
  `;
1654
1895
  });
1655
1896
 
1656
- const $$file$2 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/404.astro";
1657
- const $$url$2 = "/404";
1897
+ const $$file$4 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/500.astro";
1898
+ const $$url$4 = undefined;
1658
1899
 
1659
- const _page1 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1900
+ const $$module1$1 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1901
+ __proto__: null,
1902
+ $$metadata: $$metadata$4,
1903
+ default: $$500$1,
1904
+ file: $$file$4,
1905
+ url: $$url$4
1906
+ }, Symbol.toStringTag, { value: 'Module' }));
1907
+
1908
+ const $$metadata$3 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/500.astro", { modules: [{ module: $$module1$1, specifier: "../lib/views/500.astro", assert: {} }, { module: $$module2$2, specifier: "../lib/ssr-context", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1909
+ const $$Astro$3 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/500.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1910
+ const $$500 = createComponent(async ($$result, $$props, $$slots) => {
1911
+ const Astro2 = $$result.createAstro($$Astro$3, $$props, $$slots);
1912
+ Astro2.self = $$500;
1913
+ let pageContext;
1914
+ try {
1915
+ pageContext = await loadPageContext(Astro2);
1916
+ } catch (err) {
1917
+ return err.astroResponse;
1918
+ }
1919
+ return renderTemplate`${renderComponent($$result, "View500", $$500$1, { "pageContext": pageContext })}`;
1920
+ });
1921
+
1922
+ const $$file$3 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/500.astro";
1923
+ const $$url$3 = "/500";
1924
+
1925
+ const _page2 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1926
+ __proto__: null,
1927
+ $$metadata: $$metadata$3,
1928
+ default: $$500,
1929
+ file: $$file$3,
1930
+ url: $$url$3
1931
+ }, Symbol.toStringTag, { value: 'Module' }));
1932
+
1933
+ const $$metadata$2 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/app/index.astro", { modules: [], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1934
+ const $$Astro$2 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/app/index.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1935
+ const $$Index = createComponent(async ($$result, $$props, $$slots) => {
1936
+ const Astro2 = $$result.createAstro($$Astro$2, $$props, $$slots);
1937
+ Astro2.self = $$Index;
1938
+ return renderTemplate``;
1939
+ });
1940
+
1941
+ const $$file$2 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/app/index.astro";
1942
+ const $$url$2 = "/app";
1943
+
1944
+ const _page3 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1660
1945
  __proto__: null,
1661
1946
  $$metadata: $$metadata$2,
1662
- default: $$404,
1947
+ default: $$Index,
1663
1948
  file: $$file$2,
1664
1949
  url: $$url$2
1665
1950
  }, Symbol.toStringTag, { value: 'Module' }));
1666
1951
 
1667
- const $$metadata$1 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/app/index.astro", { modules: [], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1668
- const $$Astro$1 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/app/index.astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1669
- const $$Index = createComponent(async ($$result, $$props, $$slots) => {
1952
+ const $$metadata$1 = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/[...slug].astro", { modules: [{ module: $$module1$4, specifier: "../layouts/Layout.astro", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1953
+ const $$Astro$1 = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/[...slug].astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1954
+ const $$$1 = createComponent(async ($$result, $$props, $$slots) => {
1670
1955
  const Astro2 = $$result.createAstro($$Astro$1, $$props, $$slots);
1671
- Astro2.self = $$Index;
1672
- return renderTemplate``;
1956
+ Astro2.self = $$$1;
1957
+ const { pageContext } = Astro2.props;
1958
+ const { apiResource, apiDoc } = pageContext;
1959
+ const STYLES = [];
1960
+ for (const STYLE of STYLES)
1961
+ $$result.styles.add(STYLE);
1962
+ return renderTemplate`${renderComponent($$result, "Layout", $$Layout, { "title": apiDoc.name, "class": "astro-JWBYURAL" }, { "default": () => renderTemplate`${maybeRenderHead($$result)}<main class="astro-JWBYURAL">
1963
+ <h1 class="astro-JWBYURAL">Hello <span class="text-gradient astro-JWBYURAL">${apiDoc.name}</span></h1>
1964
+ <hr class="astro-JWBYURAL">
1965
+ <div class="mt-3 astro-JWBYURAL">
1966
+ <mark class="astro-JWBYURAL">${apiDoc._id}</mark> from <i class="astro-JWBYURAL">${apiResource}</i>
1967
+ <p class="astro-JWBYURAL">${Math.random()}</p>
1968
+ <em class="astro-JWBYURAL">Lorem ipsum dolor sit amet</em>
1969
+ </div>
1970
+ </main>` })}
1971
+
1972
+ `;
1673
1973
  });
1674
1974
 
1675
- const $$file$1 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/app/index.astro";
1676
- const $$url$1 = "/app";
1975
+ const $$file$1 = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/lib/views/[...slug].astro";
1976
+ const $$url$1 = undefined;
1677
1977
 
1678
- const _page2 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1978
+ const $$module1 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1679
1979
  __proto__: null,
1680
1980
  $$metadata: $$metadata$1,
1681
- default: $$Index,
1981
+ default: $$$1,
1682
1982
  file: $$file$1,
1683
1983
  url: $$url$1
1684
1984
  }, Symbol.toStringTag, { value: 'Module' }));
1685
1985
 
1686
- const $$metadata = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/[...slug].astro", { modules: [{ module: $$module1, specifier: "@cloudcommerce/api", assert: {} }, { module: $$module2$1, specifier: "../../storefront.config.mjs", assert: {} }, { module: $$module3, specifier: "../layouts/Layout.astro", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1986
+ const $$metadata = createMetadata("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/[...slug].astro", { modules: [{ module: $$module1, specifier: "../lib/views/[...slug].astro", assert: {} }, { module: $$module2$2, specifier: "../lib/ssr-context", assert: {} }], hydratedComponents: [], clientOnlyComponents: [], hydrationDirectives: /* @__PURE__ */ new Set([]), hoisted: [] });
1687
1987
  const $$Astro = createAstro("/@fs/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/[...slug].astro", "https://storefront-demo.e-com.plus/", "file:///home/leo/code/ecomplus/cloud-commerce/packages/storefront/");
1688
1988
  const $$ = createComponent(async ($$result, $$props, $$slots) => {
1689
1989
  const Astro2 = $$result.createAstro($$Astro, $$props, $$slots);
1690
1990
  Astro2.self = $$;
1691
- const { slug } = Astro2.params;
1692
- let resource;
1693
- let doc;
1991
+ let pageContext;
1694
1992
  try {
1695
- const { data } = await api.get(`slugs/${slug}`, { fetch });
1696
- resource = data.resource;
1697
- doc = data.doc;
1698
- } catch {
1699
- return Astro2.redirect(`/404?url=${encodeURIComponent(`/${slug}`)}`);
1993
+ pageContext = await loadPageContext(Astro2);
1994
+ } catch (err) {
1995
+ return err.astroResponse;
1700
1996
  }
1701
- const STYLES = [];
1702
- for (const STYLE of STYLES)
1703
- $$result.styles.add(STYLE);
1704
- return renderTemplate`${renderComponent($$result, "Layout", $$Layout, { "title": doc.name, "class": "astro-WWHJ5KDF" }, { "default": () => renderTemplate`${maybeRenderHead($$result)}<main class="astro-WWHJ5KDF">
1705
- <h1 class="astro-WWHJ5KDF">Hello <span class="text-gradient astro-WWHJ5KDF">${doc.name}</span></h1>
1706
- <hr class="astro-WWHJ5KDF">
1707
- <div class="mt-3 astro-WWHJ5KDF">
1708
- <mark class="astro-WWHJ5KDF">${doc._id}</mark> from <i class="astro-WWHJ5KDF">${resource}</i>
1709
- <p class="astro-WWHJ5KDF">${Math.random()}</p>
1710
- <em class="astro-WWHJ5KDF">Lorem ipsum dolor sit amet</em>
1711
- </div>
1712
- </main>` })}
1713
-
1714
- `;
1997
+ return renderTemplate`${renderComponent($$result, "ViewWildcard", $$$1, { "pageContext": pageContext })}`;
1715
1998
  });
1716
1999
 
1717
2000
  const $$file = "/home/leo/code/ecomplus/cloud-commerce/packages/storefront/src/pages/[...slug].astro";
1718
2001
  const $$url = "/[...slug]";
1719
2002
 
1720
- const _page3 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
2003
+ const _page4 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1721
2004
  __proto__: null,
1722
2005
  $$metadata,
1723
2006
  default: $$,
@@ -1725,7 +2008,7 @@ const _page3 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
1725
2008
  url: $$url
1726
2009
  }, Symbol.toStringTag, { value: 'Module' }));
1727
2010
 
1728
- const pageMap = new Map([['src/pages/index.astro', _page0],['src/pages/404.astro', _page1],['src/pages/app/index.astro', _page2],['src/pages/[...slug].astro', _page3],]);
2011
+ const pageMap = new Map([['src/pages/index.astro', _page0],['src/pages/404.astro', _page1],['src/pages/500.astro', _page2],['src/pages/app/index.astro', _page3],['src/pages/[...slug].astro', _page4],]);
1729
2012
  const renderers = [Object.assign({"name":"astro:jsx","serverEntrypoint":"astro/jsx/server.js","jsxImportSource":"astro"}, { ssr: server_default }),Object.assign({"name":"@astrojs/vue","clientEntrypoint":"@astrojs/vue/client.js","serverEntrypoint":"@astrojs/vue/server.js"}, { ssr: _renderer1 }),];
1730
2013
 
1731
2014
  if (typeof process !== "undefined") {
@@ -1797,7 +2080,7 @@ function deserializeManifest(serializedManifest) {
1797
2080
  };
1798
2081
  }
1799
2082
 
1800
- const _manifest = Object.assign(deserializeManifest({"adapterName":"@astrojs/node","routes":[{"file":"","links":["assets/404-_...d4aa8aff.css","assets/404-index.d9230d24.css","assets/index.53a3a3e0.css"],"scripts":[{"type":"external","value":"page.3aa82516.js"},{"stage":"head-inline","children":"!(function(w,p,f,c){c=w[p]=Object.assign(w[p]||{},{\"lib\":\"/~partytown/\",\"debug\":false});c[f]=(c[f]||[])})(window,'partytown','forward');/* Partytown 0.4.5 - MIT builder.io */\n!function(t,e,n,i,r,o,a,d,s,c,p,l){function u(){l||(l=1,\"/\"==(a=(o.lib||\"/~partytown/\")+(o.debug?\"debug/\":\"\"))[0]&&(s=e.querySelectorAll('script[type=\"text/partytown\"]'),i!=t?i.dispatchEvent(new CustomEvent(\"pt1\",{detail:t})):(d=setTimeout(w,1e4),e.addEventListener(\"pt0\",f),r?h(1):n.serviceWorker?n.serviceWorker.register(a+(o.swPath||\"partytown-sw.js\"),{scope:a}).then((function(t){t.active?h():t.installing&&t.installing.addEventListener(\"statechange\",(function(t){\"activated\"==t.target.state&&h()}))}),console.error):w())))}function h(t){c=e.createElement(t?\"script\":\"iframe\"),t||(c.setAttribute(\"style\",\"display:block;width:0;height:0;border:0;visibility:hidden\"),c.setAttribute(\"aria-hidden\",!0)),c.src=a+\"partytown-\"+(t?\"atomics.js?v=0.4.5\":\"sandbox-sw.html?\"+Date.now()),e.body.appendChild(c)}function w(t,n){for(f(),t=0;t<s.length;t++)(n=e.createElement(\"script\")).innerHTML=s[t].innerHTML,e.head.appendChild(n);c&&c.parentNode.removeChild(c)}function f(){clearTimeout(d)}o=t.partytown||{},i==t&&(o.forward||[]).map((function(e){p=t,e.split(\".\").map((function(e,n,i){p=p[i[n]]=n+1<i.length?\"push\"==i[n+1]?[]:p[i[n]]||{}:function(){(t._ptf=t._ptf||[]).push(i,arguments)}}))})),\"complete\"==e.readyState?u():(t.addEventListener(\"DOMContentLoaded\",u),t.addEventListener(\"load\",u))}(window,document,navigator,top,window.crossOriginIsolated);"}],"routeData":{"route":"/","type":"page","pattern":"^\\/$","segments":[],"params":[],"component":"src/pages/index.astro","pathname":"/","_meta":{"trailingSlash":"ignore"}}},{"file":"","links":["assets/404-_...d4aa8aff.css","assets/404-index.d9230d24.css","assets/404.530428e5.css"],"scripts":[{"type":"external","value":"page.3aa82516.js"},{"stage":"head-inline","children":"!(function(w,p,f,c){c=w[p]=Object.assign(w[p]||{},{\"lib\":\"/~partytown/\",\"debug\":false});c[f]=(c[f]||[])})(window,'partytown','forward');/* Partytown 0.4.5 - MIT builder.io */\n!function(t,e,n,i,r,o,a,d,s,c,p,l){function u(){l||(l=1,\"/\"==(a=(o.lib||\"/~partytown/\")+(o.debug?\"debug/\":\"\"))[0]&&(s=e.querySelectorAll('script[type=\"text/partytown\"]'),i!=t?i.dispatchEvent(new CustomEvent(\"pt1\",{detail:t})):(d=setTimeout(w,1e4),e.addEventListener(\"pt0\",f),r?h(1):n.serviceWorker?n.serviceWorker.register(a+(o.swPath||\"partytown-sw.js\"),{scope:a}).then((function(t){t.active?h():t.installing&&t.installing.addEventListener(\"statechange\",(function(t){\"activated\"==t.target.state&&h()}))}),console.error):w())))}function h(t){c=e.createElement(t?\"script\":\"iframe\"),t||(c.setAttribute(\"style\",\"display:block;width:0;height:0;border:0;visibility:hidden\"),c.setAttribute(\"aria-hidden\",!0)),c.src=a+\"partytown-\"+(t?\"atomics.js?v=0.4.5\":\"sandbox-sw.html?\"+Date.now()),e.body.appendChild(c)}function w(t,n){for(f(),t=0;t<s.length;t++)(n=e.createElement(\"script\")).innerHTML=s[t].innerHTML,e.head.appendChild(n);c&&c.parentNode.removeChild(c)}function f(){clearTimeout(d)}o=t.partytown||{},i==t&&(o.forward||[]).map((function(e){p=t,e.split(\".\").map((function(e,n,i){p=p[i[n]]=n+1<i.length?\"push\"==i[n+1]?[]:p[i[n]]||{}:function(){(t._ptf=t._ptf||[]).push(i,arguments)}}))})),\"complete\"==e.readyState?u():(t.addEventListener(\"DOMContentLoaded\",u),t.addEventListener(\"load\",u))}(window,document,navigator,top,window.crossOriginIsolated);"}],"routeData":{"route":"/404","type":"page","pattern":"^\\/404\\/?$","segments":[[{"content":"404","dynamic":false,"spread":false}]],"params":[],"component":"src/pages/404.astro","pathname":"/404","_meta":{"trailingSlash":"ignore"}}},{"file":"","links":[],"scripts":[{"type":"external","value":"page.3aa82516.js"},{"stage":"head-inline","children":"!(function(w,p,f,c){c=w[p]=Object.assign(w[p]||{},{\"lib\":\"/~partytown/\",\"debug\":false});c[f]=(c[f]||[])})(window,'partytown','forward');/* Partytown 0.4.5 - MIT builder.io */\n!function(t,e,n,i,r,o,a,d,s,c,p,l){function u(){l||(l=1,\"/\"==(a=(o.lib||\"/~partytown/\")+(o.debug?\"debug/\":\"\"))[0]&&(s=e.querySelectorAll('script[type=\"text/partytown\"]'),i!=t?i.dispatchEvent(new CustomEvent(\"pt1\",{detail:t})):(d=setTimeout(w,1e4),e.addEventListener(\"pt0\",f),r?h(1):n.serviceWorker?n.serviceWorker.register(a+(o.swPath||\"partytown-sw.js\"),{scope:a}).then((function(t){t.active?h():t.installing&&t.installing.addEventListener(\"statechange\",(function(t){\"activated\"==t.target.state&&h()}))}),console.error):w())))}function h(t){c=e.createElement(t?\"script\":\"iframe\"),t||(c.setAttribute(\"style\",\"display:block;width:0;height:0;border:0;visibility:hidden\"),c.setAttribute(\"aria-hidden\",!0)),c.src=a+\"partytown-\"+(t?\"atomics.js?v=0.4.5\":\"sandbox-sw.html?\"+Date.now()),e.body.appendChild(c)}function w(t,n){for(f(),t=0;t<s.length;t++)(n=e.createElement(\"script\")).innerHTML=s[t].innerHTML,e.head.appendChild(n);c&&c.parentNode.removeChild(c)}function f(){clearTimeout(d)}o=t.partytown||{},i==t&&(o.forward||[]).map((function(e){p=t,e.split(\".\").map((function(e,n,i){p=p[i[n]]=n+1<i.length?\"push\"==i[n+1]?[]:p[i[n]]||{}:function(){(t._ptf=t._ptf||[]).push(i,arguments)}}))})),\"complete\"==e.readyState?u():(t.addEventListener(\"DOMContentLoaded\",u),t.addEventListener(\"load\",u))}(window,document,navigator,top,window.crossOriginIsolated);"}],"routeData":{"route":"/app","type":"page","pattern":"^\\/app\\/?$","segments":[[{"content":"app","dynamic":false,"spread":false}]],"params":[],"component":"src/pages/app/index.astro","pathname":"/app","_meta":{"trailingSlash":"ignore"}}},{"file":"","links":["assets/404-_...d4aa8aff.css","assets/_...98510c96.css"],"scripts":[{"type":"external","value":"page.3aa82516.js"},{"stage":"head-inline","children":"!(function(w,p,f,c){c=w[p]=Object.assign(w[p]||{},{\"lib\":\"/~partytown/\",\"debug\":false});c[f]=(c[f]||[])})(window,'partytown','forward');/* Partytown 0.4.5 - MIT builder.io */\n!function(t,e,n,i,r,o,a,d,s,c,p,l){function u(){l||(l=1,\"/\"==(a=(o.lib||\"/~partytown/\")+(o.debug?\"debug/\":\"\"))[0]&&(s=e.querySelectorAll('script[type=\"text/partytown\"]'),i!=t?i.dispatchEvent(new CustomEvent(\"pt1\",{detail:t})):(d=setTimeout(w,1e4),e.addEventListener(\"pt0\",f),r?h(1):n.serviceWorker?n.serviceWorker.register(a+(o.swPath||\"partytown-sw.js\"),{scope:a}).then((function(t){t.active?h():t.installing&&t.installing.addEventListener(\"statechange\",(function(t){\"activated\"==t.target.state&&h()}))}),console.error):w())))}function h(t){c=e.createElement(t?\"script\":\"iframe\"),t||(c.setAttribute(\"style\",\"display:block;width:0;height:0;border:0;visibility:hidden\"),c.setAttribute(\"aria-hidden\",!0)),c.src=a+\"partytown-\"+(t?\"atomics.js?v=0.4.5\":\"sandbox-sw.html?\"+Date.now()),e.body.appendChild(c)}function w(t,n){for(f(),t=0;t<s.length;t++)(n=e.createElement(\"script\")).innerHTML=s[t].innerHTML,e.head.appendChild(n);c&&c.parentNode.removeChild(c)}function f(){clearTimeout(d)}o=t.partytown||{},i==t&&(o.forward||[]).map((function(e){p=t,e.split(\".\").map((function(e,n,i){p=p[i[n]]=n+1<i.length?\"push\"==i[n+1]?[]:p[i[n]]||{}:function(){(t._ptf=t._ptf||[]).push(i,arguments)}}))})),\"complete\"==e.readyState?u():(t.addEventListener(\"DOMContentLoaded\",u),t.addEventListener(\"load\",u))}(window,document,navigator,top,window.crossOriginIsolated);"}],"routeData":{"route":"/[...slug]","type":"page","pattern":"^(?:\\/(.*?))?\\/?$","segments":[[{"content":"...slug","dynamic":true,"spread":true}]],"params":["...slug"],"component":"src/pages/[...slug].astro","_meta":{"trailingSlash":"ignore"}}}],"site":"https://storefront-demo.e-com.plus/","base":"/","markdown":{"drafts":false,"syntaxHighlight":"shiki","shikiConfig":{"langs":[],"theme":"github-dark","wrap":false},"remarkPlugins":[],"rehypePlugins":[],"remarkRehype":{},"extendDefaultPlugins":false,"isAstroFlavoredMd":false},"pageMap":null,"renderers":[],"entryModules":{"\u0000@astrojs-ssr-virtual-entry":"entry.mjs","@astrojs/vue/client.js":"client.6d48c590.js","astro:scripts/page.js":"page.3aa82516.js","astro:scripts/before-hydration.js":"data:text/javascript;charset=utf-8,//[no before-hydration script]"},"assets":["/assets/404.530428e5.css","/assets/404-_...d4aa8aff.css","/assets/404-index.d9230d24.css","/assets/_...98510c96.css","/assets/index.53a3a3e0.css","/client.6d48c590.js","/favicon.ico","/page.3aa82516.js","/page.3aa82516.js","/~partytown/partytown-atomics.js","/~partytown/partytown-media.js","/~partytown/partytown-sw.js","/~partytown/partytown.js"]}), {
2083
+ const _manifest = Object.assign(deserializeManifest({"adapterName":"@astrojs/node","routes":[{"file":"","links":["assets/404-500-_...d4aa8aff.css","assets/404-500-index.d9230d24.css","assets/index.9745690c.css"],"scripts":[{"type":"external","value":"page.3aa82516.js"},{"stage":"head-inline","children":"!(function(w,p,f,c){c=w[p]=Object.assign(w[p]||{},{\"lib\":\"/~partytown/\",\"debug\":false});c[f]=(c[f]||[])})(window,'partytown','forward');/* Partytown 0.4.5 - MIT builder.io */\n!function(t,e,n,i,r,o,a,d,s,c,p,l){function u(){l||(l=1,\"/\"==(a=(o.lib||\"/~partytown/\")+(o.debug?\"debug/\":\"\"))[0]&&(s=e.querySelectorAll('script[type=\"text/partytown\"]'),i!=t?i.dispatchEvent(new CustomEvent(\"pt1\",{detail:t})):(d=setTimeout(w,1e4),e.addEventListener(\"pt0\",f),r?h(1):n.serviceWorker?n.serviceWorker.register(a+(o.swPath||\"partytown-sw.js\"),{scope:a}).then((function(t){t.active?h():t.installing&&t.installing.addEventListener(\"statechange\",(function(t){\"activated\"==t.target.state&&h()}))}),console.error):w())))}function h(t){c=e.createElement(t?\"script\":\"iframe\"),t||(c.setAttribute(\"style\",\"display:block;width:0;height:0;border:0;visibility:hidden\"),c.setAttribute(\"aria-hidden\",!0)),c.src=a+\"partytown-\"+(t?\"atomics.js?v=0.4.5\":\"sandbox-sw.html?\"+Date.now()),e.body.appendChild(c)}function w(t,n){for(f(),t=0;t<s.length;t++)(n=e.createElement(\"script\")).innerHTML=s[t].innerHTML,e.head.appendChild(n);c&&c.parentNode.removeChild(c)}function f(){clearTimeout(d)}o=t.partytown||{},i==t&&(o.forward||[]).map((function(e){p=t,e.split(\".\").map((function(e,n,i){p=p[i[n]]=n+1<i.length?\"push\"==i[n+1]?[]:p[i[n]]||{}:function(){(t._ptf=t._ptf||[]).push(i,arguments)}}))})),\"complete\"==e.readyState?u():(t.addEventListener(\"DOMContentLoaded\",u),t.addEventListener(\"load\",u))}(window,document,navigator,top,window.crossOriginIsolated);"}],"routeData":{"route":"/","type":"page","pattern":"^\\/$","segments":[],"params":[],"component":"src/pages/index.astro","pathname":"/","_meta":{"trailingSlash":"ignore"}}},{"file":"","links":["assets/404-500-_...d4aa8aff.css","assets/404-500-index.d9230d24.css","assets/404.b3ead908.css"],"scripts":[{"type":"external","value":"page.3aa82516.js"},{"stage":"head-inline","children":"!(function(w,p,f,c){c=w[p]=Object.assign(w[p]||{},{\"lib\":\"/~partytown/\",\"debug\":false});c[f]=(c[f]||[])})(window,'partytown','forward');/* Partytown 0.4.5 - MIT builder.io */\n!function(t,e,n,i,r,o,a,d,s,c,p,l){function u(){l||(l=1,\"/\"==(a=(o.lib||\"/~partytown/\")+(o.debug?\"debug/\":\"\"))[0]&&(s=e.querySelectorAll('script[type=\"text/partytown\"]'),i!=t?i.dispatchEvent(new CustomEvent(\"pt1\",{detail:t})):(d=setTimeout(w,1e4),e.addEventListener(\"pt0\",f),r?h(1):n.serviceWorker?n.serviceWorker.register(a+(o.swPath||\"partytown-sw.js\"),{scope:a}).then((function(t){t.active?h():t.installing&&t.installing.addEventListener(\"statechange\",(function(t){\"activated\"==t.target.state&&h()}))}),console.error):w())))}function h(t){c=e.createElement(t?\"script\":\"iframe\"),t||(c.setAttribute(\"style\",\"display:block;width:0;height:0;border:0;visibility:hidden\"),c.setAttribute(\"aria-hidden\",!0)),c.src=a+\"partytown-\"+(t?\"atomics.js?v=0.4.5\":\"sandbox-sw.html?\"+Date.now()),e.body.appendChild(c)}function w(t,n){for(f(),t=0;t<s.length;t++)(n=e.createElement(\"script\")).innerHTML=s[t].innerHTML,e.head.appendChild(n);c&&c.parentNode.removeChild(c)}function f(){clearTimeout(d)}o=t.partytown||{},i==t&&(o.forward||[]).map((function(e){p=t,e.split(\".\").map((function(e,n,i){p=p[i[n]]=n+1<i.length?\"push\"==i[n+1]?[]:p[i[n]]||{}:function(){(t._ptf=t._ptf||[]).push(i,arguments)}}))})),\"complete\"==e.readyState?u():(t.addEventListener(\"DOMContentLoaded\",u),t.addEventListener(\"load\",u))}(window,document,navigator,top,window.crossOriginIsolated);"}],"routeData":{"route":"/404","type":"page","pattern":"^\\/404\\/?$","segments":[[{"content":"404","dynamic":false,"spread":false}]],"params":[],"component":"src/pages/404.astro","pathname":"/404","_meta":{"trailingSlash":"ignore"}}},{"file":"","links":["assets/404-500-_...d4aa8aff.css","assets/404-500-index.d9230d24.css","assets/500.d5d7700b.css"],"scripts":[{"type":"external","value":"page.3aa82516.js"},{"stage":"head-inline","children":"!(function(w,p,f,c){c=w[p]=Object.assign(w[p]||{},{\"lib\":\"/~partytown/\",\"debug\":false});c[f]=(c[f]||[])})(window,'partytown','forward');/* Partytown 0.4.5 - MIT builder.io */\n!function(t,e,n,i,r,o,a,d,s,c,p,l){function u(){l||(l=1,\"/\"==(a=(o.lib||\"/~partytown/\")+(o.debug?\"debug/\":\"\"))[0]&&(s=e.querySelectorAll('script[type=\"text/partytown\"]'),i!=t?i.dispatchEvent(new CustomEvent(\"pt1\",{detail:t})):(d=setTimeout(w,1e4),e.addEventListener(\"pt0\",f),r?h(1):n.serviceWorker?n.serviceWorker.register(a+(o.swPath||\"partytown-sw.js\"),{scope:a}).then((function(t){t.active?h():t.installing&&t.installing.addEventListener(\"statechange\",(function(t){\"activated\"==t.target.state&&h()}))}),console.error):w())))}function h(t){c=e.createElement(t?\"script\":\"iframe\"),t||(c.setAttribute(\"style\",\"display:block;width:0;height:0;border:0;visibility:hidden\"),c.setAttribute(\"aria-hidden\",!0)),c.src=a+\"partytown-\"+(t?\"atomics.js?v=0.4.5\":\"sandbox-sw.html?\"+Date.now()),e.body.appendChild(c)}function w(t,n){for(f(),t=0;t<s.length;t++)(n=e.createElement(\"script\")).innerHTML=s[t].innerHTML,e.head.appendChild(n);c&&c.parentNode.removeChild(c)}function f(){clearTimeout(d)}o=t.partytown||{},i==t&&(o.forward||[]).map((function(e){p=t,e.split(\".\").map((function(e,n,i){p=p[i[n]]=n+1<i.length?\"push\"==i[n+1]?[]:p[i[n]]||{}:function(){(t._ptf=t._ptf||[]).push(i,arguments)}}))})),\"complete\"==e.readyState?u():(t.addEventListener(\"DOMContentLoaded\",u),t.addEventListener(\"load\",u))}(window,document,navigator,top,window.crossOriginIsolated);"}],"routeData":{"route":"/500","type":"page","pattern":"^\\/500\\/?$","segments":[[{"content":"500","dynamic":false,"spread":false}]],"params":[],"component":"src/pages/500.astro","pathname":"/500","_meta":{"trailingSlash":"ignore"}}},{"file":"","links":[],"scripts":[{"type":"external","value":"page.3aa82516.js"},{"stage":"head-inline","children":"!(function(w,p,f,c){c=w[p]=Object.assign(w[p]||{},{\"lib\":\"/~partytown/\",\"debug\":false});c[f]=(c[f]||[])})(window,'partytown','forward');/* Partytown 0.4.5 - MIT builder.io */\n!function(t,e,n,i,r,o,a,d,s,c,p,l){function u(){l||(l=1,\"/\"==(a=(o.lib||\"/~partytown/\")+(o.debug?\"debug/\":\"\"))[0]&&(s=e.querySelectorAll('script[type=\"text/partytown\"]'),i!=t?i.dispatchEvent(new CustomEvent(\"pt1\",{detail:t})):(d=setTimeout(w,1e4),e.addEventListener(\"pt0\",f),r?h(1):n.serviceWorker?n.serviceWorker.register(a+(o.swPath||\"partytown-sw.js\"),{scope:a}).then((function(t){t.active?h():t.installing&&t.installing.addEventListener(\"statechange\",(function(t){\"activated\"==t.target.state&&h()}))}),console.error):w())))}function h(t){c=e.createElement(t?\"script\":\"iframe\"),t||(c.setAttribute(\"style\",\"display:block;width:0;height:0;border:0;visibility:hidden\"),c.setAttribute(\"aria-hidden\",!0)),c.src=a+\"partytown-\"+(t?\"atomics.js?v=0.4.5\":\"sandbox-sw.html?\"+Date.now()),e.body.appendChild(c)}function w(t,n){for(f(),t=0;t<s.length;t++)(n=e.createElement(\"script\")).innerHTML=s[t].innerHTML,e.head.appendChild(n);c&&c.parentNode.removeChild(c)}function f(){clearTimeout(d)}o=t.partytown||{},i==t&&(o.forward||[]).map((function(e){p=t,e.split(\".\").map((function(e,n,i){p=p[i[n]]=n+1<i.length?\"push\"==i[n+1]?[]:p[i[n]]||{}:function(){(t._ptf=t._ptf||[]).push(i,arguments)}}))})),\"complete\"==e.readyState?u():(t.addEventListener(\"DOMContentLoaded\",u),t.addEventListener(\"load\",u))}(window,document,navigator,top,window.crossOriginIsolated);"}],"routeData":{"route":"/app","type":"page","pattern":"^\\/app\\/?$","segments":[[{"content":"app","dynamic":false,"spread":false}]],"params":[],"component":"src/pages/app/index.astro","pathname":"/app","_meta":{"trailingSlash":"ignore"}}},{"file":"","links":["assets/404-500-_...d4aa8aff.css","assets/_...c08e0a75.css"],"scripts":[{"type":"external","value":"page.3aa82516.js"},{"stage":"head-inline","children":"!(function(w,p,f,c){c=w[p]=Object.assign(w[p]||{},{\"lib\":\"/~partytown/\",\"debug\":false});c[f]=(c[f]||[])})(window,'partytown','forward');/* Partytown 0.4.5 - MIT builder.io */\n!function(t,e,n,i,r,o,a,d,s,c,p,l){function u(){l||(l=1,\"/\"==(a=(o.lib||\"/~partytown/\")+(o.debug?\"debug/\":\"\"))[0]&&(s=e.querySelectorAll('script[type=\"text/partytown\"]'),i!=t?i.dispatchEvent(new CustomEvent(\"pt1\",{detail:t})):(d=setTimeout(w,1e4),e.addEventListener(\"pt0\",f),r?h(1):n.serviceWorker?n.serviceWorker.register(a+(o.swPath||\"partytown-sw.js\"),{scope:a}).then((function(t){t.active?h():t.installing&&t.installing.addEventListener(\"statechange\",(function(t){\"activated\"==t.target.state&&h()}))}),console.error):w())))}function h(t){c=e.createElement(t?\"script\":\"iframe\"),t||(c.setAttribute(\"style\",\"display:block;width:0;height:0;border:0;visibility:hidden\"),c.setAttribute(\"aria-hidden\",!0)),c.src=a+\"partytown-\"+(t?\"atomics.js?v=0.4.5\":\"sandbox-sw.html?\"+Date.now()),e.body.appendChild(c)}function w(t,n){for(f(),t=0;t<s.length;t++)(n=e.createElement(\"script\")).innerHTML=s[t].innerHTML,e.head.appendChild(n);c&&c.parentNode.removeChild(c)}function f(){clearTimeout(d)}o=t.partytown||{},i==t&&(o.forward||[]).map((function(e){p=t,e.split(\".\").map((function(e,n,i){p=p[i[n]]=n+1<i.length?\"push\"==i[n+1]?[]:p[i[n]]||{}:function(){(t._ptf=t._ptf||[]).push(i,arguments)}}))})),\"complete\"==e.readyState?u():(t.addEventListener(\"DOMContentLoaded\",u),t.addEventListener(\"load\",u))}(window,document,navigator,top,window.crossOriginIsolated);"}],"routeData":{"route":"/[...slug]","type":"page","pattern":"^(?:\\/(.*?))?\\/?$","segments":[[{"content":"...slug","dynamic":true,"spread":true}]],"params":["...slug"],"component":"src/pages/[...slug].astro","_meta":{"trailingSlash":"ignore"}}}],"site":"https://storefront-demo.e-com.plus/","base":"/","markdown":{"drafts":false,"syntaxHighlight":"shiki","shikiConfig":{"langs":[],"theme":"github-dark","wrap":false},"remarkPlugins":[],"rehypePlugins":[],"remarkRehype":{},"extendDefaultPlugins":false,"isAstroFlavoredMd":false},"pageMap":null,"renderers":[],"entryModules":{"\u0000@astrojs-ssr-virtual-entry":"entry.mjs","@astrojs/vue/client.js":"client.6d48c590.js","astro:scripts/page.js":"page.3aa82516.js","astro:scripts/before-hydration.js":"data:text/javascript;charset=utf-8,//[no before-hydration script]"},"assets":["/assets/404.b3ead908.css","/assets/500.d5d7700b.css","/assets/404-500-_...d4aa8aff.css","/assets/404-500-index.d9230d24.css","/assets/_...c08e0a75.css","/assets/index.9745690c.css","/client.6d48c590.js","/favicon.ico","/page.3aa82516.js","/page.3aa82516.js","/~partytown/partytown-atomics.js","/~partytown/partytown-media.js","/~partytown/partytown-sw.js","/~partytown/partytown.js"]}), {
1801
2084
  pageMap: pageMap,
1802
2085
  renderers: renderers
1803
2086
  });