cloudcommerce 0.26.7 → 0.28.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (248) hide show
  1. package/.github/workflows/test-apps.yml +2 -2
  2. package/.gitmodules +0 -3
  3. package/.vscode/settings.json +3 -1
  4. package/CHANGELOG.md +51 -0
  5. package/action.yml +2 -2
  6. package/ecomplus-stores/barra-doce/functions/many/package.json +3 -3
  7. package/ecomplus-stores/barra-doce/functions/ssr/content/layout.json +13 -13
  8. package/ecomplus-stores/barra-doce/functions/ssr/content/pages/home.json +10 -10
  9. package/ecomplus-stores/barra-doce/functions/ssr/content/pages/products.json +17 -0
  10. package/ecomplus-stores/barra-doce/functions/ssr/content/settings.json +8 -8
  11. package/ecomplus-stores/barra-doce/functions/ssr/package.json +6 -6
  12. package/ecomplus-stores/barra-doce/functions/ssr/src/components/AccountMenu.vue +11 -11
  13. package/ecomplus-stores/barra-doce/functions/ssr/src/components/ShopFooter.vue +24 -24
  14. package/ecomplus-stores/barra-doce/functions/ssr/src/layouts/PageFooter.astro +4 -4
  15. package/ecomplus-stores/barra-doce/functions/with-apps/package.json +3 -3
  16. package/ecomplus-stores/barra-doce/package.json +2 -2
  17. package/ecomplus-stores/monocard/functions/many/package.json +3 -3
  18. package/ecomplus-stores/monocard/functions/ssr/content/layout.json +11 -11
  19. package/ecomplus-stores/monocard/functions/ssr/content/pages/home.json +16 -16
  20. package/ecomplus-stores/monocard/functions/ssr/content/pages/products.json +2 -4
  21. package/ecomplus-stores/monocard/functions/ssr/content/settings.json +11 -11
  22. package/ecomplus-stores/monocard/functions/ssr/package.json +6 -6
  23. package/ecomplus-stores/monocard/functions/ssr/src/components/AccountMenu.vue +1 -1
  24. package/ecomplus-stores/monocard/functions/ssr/src/components/DocDescription.vue +33 -0
  25. package/ecomplus-stores/monocard/functions/ssr/src/components/FeatureTabs.vue +3 -3
  26. package/ecomplus-stores/monocard/functions/ssr/src/components/ShopFooter.vue +3 -3
  27. package/ecomplus-stores/monocard/functions/ssr/src/components/ShopHeader.vue +5 -13
  28. package/ecomplus-stores/monocard/functions/ssr/src/layouts/PageFooter.astro +2 -2
  29. package/ecomplus-stores/monocard/functions/ssr/src/main/Home.astro +1 -1
  30. package/ecomplus-stores/monocard/functions/ssr/src/main/Sections.astro +1 -1
  31. package/ecomplus-stores/monocard/functions/with-apps/package.json +3 -3
  32. package/ecomplus-stores/monocard/package.json +2 -2
  33. package/package.json +6 -6
  34. package/packages/api/package.json +1 -1
  35. package/packages/apps/affilate-program/package.json +2 -2
  36. package/packages/apps/correios/package.json +3 -4
  37. package/packages/apps/custom-payment/package.json +1 -1
  38. package/packages/apps/custom-shipping/package.json +1 -1
  39. package/packages/apps/datafrete/package.json +3 -3
  40. package/packages/apps/discounts/package.json +1 -1
  41. package/packages/apps/emails/lib/functios-lib/utils.js +1 -1
  42. package/packages/apps/emails/lib/functios-lib/utils.js.map +1 -1
  43. package/packages/apps/emails/package.json +2 -2
  44. package/packages/apps/emails/src/functios-lib/utils.ts +1 -1
  45. package/packages/apps/fb-conversions/package.json +3 -3
  46. package/packages/apps/flash-courier/package.json +2 -2
  47. package/packages/apps/frenet/package.json +3 -3
  48. package/packages/apps/galaxpay/package.json +3 -3
  49. package/packages/apps/google-analytics/package.json +3 -3
  50. package/packages/apps/jadlog/package.json +2 -2
  51. package/packages/apps/loyalty-points/lib/functions-lib/cron-add-points.d.ts +2 -0
  52. package/packages/apps/loyalty-points/lib/functions-lib/cron-add-points.js +98 -0
  53. package/packages/apps/loyalty-points/lib/functions-lib/cron-add-points.js.map +1 -0
  54. package/packages/apps/loyalty-points/lib/functions-lib/handle-loyalty-points-event.js +59 -23
  55. package/packages/apps/loyalty-points/lib/functions-lib/handle-loyalty-points-event.js.map +1 -1
  56. package/packages/apps/loyalty-points/lib/loyalty-create-transaction.js +9 -4
  57. package/packages/apps/loyalty-points/lib/loyalty-create-transaction.js.map +1 -1
  58. package/packages/apps/loyalty-points/lib/loyalty-list-payments.js +7 -2
  59. package/packages/apps/loyalty-points/lib/loyalty-list-payments.js.map +1 -1
  60. package/packages/apps/loyalty-points/lib/loyalty-points-events.d.ts +3 -1
  61. package/packages/apps/loyalty-points/lib/loyalty-points-events.js +9 -0
  62. package/packages/apps/loyalty-points/lib/loyalty-points-events.js.map +1 -1
  63. package/packages/apps/loyalty-points/package.json +3 -2
  64. package/packages/apps/loyalty-points/src/functions-lib/cron-add-points.ts +104 -0
  65. package/packages/apps/loyalty-points/src/functions-lib/handle-loyalty-points-event.ts +67 -25
  66. package/packages/apps/loyalty-points/src/loyalty-create-transaction.ts +11 -4
  67. package/packages/apps/loyalty-points/src/loyalty-list-payments.ts +9 -2
  68. package/packages/apps/loyalty-points/src/loyalty-points-events.ts +12 -1
  69. package/packages/apps/melhor-envio/package.json +3 -3
  70. package/packages/apps/mercadopago/assets/onload-expression.js +5 -1
  71. package/packages/apps/mercadopago/assets/onload-expression.min.js +1 -1
  72. package/packages/apps/mercadopago/lib/mp-create-transaction.js +16 -6
  73. package/packages/apps/mercadopago/lib/mp-create-transaction.js.map +1 -1
  74. package/packages/apps/mercadopago/package.json +3 -3
  75. package/packages/apps/mercadopago/src/mp-create-transaction.ts +19 -7
  76. package/packages/apps/pagarme/package.json +3 -3
  77. package/packages/apps/paghiper/package.json +3 -3
  78. package/packages/apps/pix/package.json +3 -3
  79. package/packages/apps/tiny-erp/lib/integration/export-order-to-tiny.js +22 -0
  80. package/packages/apps/tiny-erp/lib/integration/export-order-to-tiny.js.map +1 -1
  81. package/packages/apps/tiny-erp/lib/integration/helpers/format-tiny-date.js +2 -2
  82. package/packages/apps/tiny-erp/lib/integration/helpers/format-tiny-date.js.map +1 -1
  83. package/packages/apps/tiny-erp/lib/integration/import-order-from-tiny.js +7 -1
  84. package/packages/apps/tiny-erp/lib/integration/import-order-from-tiny.js.map +1 -1
  85. package/packages/apps/tiny-erp/lib/integration/import-product-from-tiny.js +14 -5
  86. package/packages/apps/tiny-erp/lib/integration/import-product-from-tiny.js.map +1 -1
  87. package/packages/apps/tiny-erp/lib/integration/parsers/order-from-tiny.js +9 -1
  88. package/packages/apps/tiny-erp/lib/integration/parsers/order-from-tiny.js.map +1 -1
  89. package/packages/apps/tiny-erp/lib/integration/parsers/order-to-tiny.js +8 -6
  90. package/packages/apps/tiny-erp/lib/integration/parsers/order-to-tiny.js.map +1 -1
  91. package/packages/apps/tiny-erp/lib/integration/parsers/product-from-tiny.js +118 -38
  92. package/packages/apps/tiny-erp/lib/integration/parsers/product-from-tiny.js.map +1 -1
  93. package/packages/apps/tiny-erp/lib/integration/parsers/product-to-tiny.js +8 -0
  94. package/packages/apps/tiny-erp/lib/integration/parsers/product-to-tiny.js.map +1 -1
  95. package/packages/apps/tiny-erp/package.json +3 -3
  96. package/packages/apps/tiny-erp/src/integration/export-order-to-tiny.ts +24 -0
  97. package/packages/apps/tiny-erp/src/integration/helpers/format-tiny-date.ts +2 -2
  98. package/packages/apps/tiny-erp/src/integration/import-order-from-tiny.ts +8 -1
  99. package/packages/apps/tiny-erp/src/integration/import-product-from-tiny.ts +17 -5
  100. package/packages/apps/tiny-erp/src/integration/parsers/order-from-tiny.ts +13 -1
  101. package/packages/apps/tiny-erp/src/integration/parsers/order-to-tiny.ts +11 -6
  102. package/packages/apps/tiny-erp/src/integration/parsers/product-from-tiny.ts +144 -41
  103. package/packages/apps/tiny-erp/src/integration/parsers/product-to-tiny.ts +10 -0
  104. package/packages/apps/webhooks/package.json +3 -3
  105. package/packages/cli/package.json +1 -1
  106. package/packages/config/lib/config.js +2 -2
  107. package/packages/config/lib/config.js.map +1 -1
  108. package/packages/config/package.json +1 -1
  109. package/packages/config/src/config.ts +2 -2
  110. package/packages/emails/package.json +4 -4
  111. package/packages/eslint/base.eslintrc.cjs +3 -0
  112. package/packages/eslint/package.json +5 -4
  113. package/packages/eslint/storefront.eslintrc.cjs +8 -1
  114. package/packages/events/package.json +2 -2
  115. package/packages/feeds/package.json +1 -1
  116. package/packages/firebase/package.json +2 -2
  117. package/packages/i18n/package.json +1 -1
  118. package/packages/modules/package.json +3 -3
  119. package/packages/passport/package.json +2 -2
  120. package/packages/ssr/package.json +3 -3
  121. package/packages/storefront/.auto-imports.d.ts +65 -0
  122. package/packages/storefront/astro.config.mjs +24 -1
  123. package/packages/storefront/client.d.ts +1 -0
  124. package/packages/storefront/config/astro/context-directive.mjs +21 -0
  125. package/packages/storefront/config/astro/index.d.ts +8 -0
  126. package/packages/storefront/config/storefront.cms.js +2 -2
  127. package/packages/storefront/config/storefront.tailwind.cjs +0 -1
  128. package/packages/storefront/package.json +4 -3
  129. package/packages/storefront/server.d.ts +1 -1
  130. package/packages/storefront/src/lib/$storefront.d.ts +8 -8
  131. package/packages/storefront/src/lib/assets/base.css +5 -0
  132. package/packages/storefront/src/lib/components/Carousel.vue +93 -72
  133. package/packages/storefront/src/lib/components/CarouselControl.vue +13 -7
  134. package/packages/storefront/src/lib/components/ContentClearfix.vue +17 -0
  135. package/packages/storefront/src/lib/components/Drawer.vue +2 -2
  136. package/packages/storefront/src/lib/components/PaymentMethodFlag.vue +2 -2
  137. package/packages/storefront/src/lib/components/QuantitySelector.vue +4 -4
  138. package/packages/storefront/src/lib/components/QuantitySelectorControl.vue +2 -2
  139. package/packages/storefront/src/lib/components/ViewTransitions.astro +409 -0
  140. package/packages/storefront/src/lib/components/globals/AImg.vue +2 -1
  141. package/packages/storefront/src/lib/composables/use-pitch-bar.ts +2 -2
  142. package/packages/storefront/src/lib/content.d.ts +5 -5
  143. package/packages/storefront/src/lib/layouts/Base.astro +4 -4
  144. package/packages/storefront/src/lib/layouts/BaseBody.astro +0 -2
  145. package/packages/storefront/src/lib/layouts/BaseHead.astro +32 -14
  146. package/packages/storefront/src/lib/layouts/use-page-header.ts +9 -4
  147. package/packages/storefront/src/lib/layouts/use-page-main.ts +13 -33
  148. package/packages/test-base/package.json +1 -1
  149. package/packages/types/index.ts +14 -14
  150. package/packages/types/package.json +1 -1
  151. package/ecomplus-stores/iluminim/.devcontainer/devcontainer.json +0 -30
  152. package/ecomplus-stores/iluminim/.editorconfig +0 -13
  153. package/ecomplus-stores/iluminim/.eslintrc.cjs +0 -3
  154. package/ecomplus-stores/iluminim/.firebaserc +0 -5
  155. package/ecomplus-stores/iluminim/.github/renovate.json +0 -5
  156. package/ecomplus-stores/iluminim/.github/workflows/build-and-deploy.yml +0 -36
  157. package/ecomplus-stores/iluminim/.github/workflows/calibreapp-image-actions.yml +0 -23
  158. package/ecomplus-stores/iluminim/.gitpod.yml +0 -12
  159. package/ecomplus-stores/iluminim/.idx/dev.nix +0 -24
  160. package/ecomplus-stores/iluminim/.nvmrc +0 -1
  161. package/ecomplus-stores/iluminim/.vscode/extensions.json +0 -8
  162. package/ecomplus-stores/iluminim/.vscode/launch.json +0 -11
  163. package/ecomplus-stores/iluminim/.vscode/settings.json +0 -10
  164. package/ecomplus-stores/iluminim/README.md +0 -31
  165. package/ecomplus-stores/iluminim/SETUP.md +0 -117
  166. package/ecomplus-stores/iluminim/SETUP.pt-BR.md +0 -117
  167. package/ecomplus-stores/iluminim/functions/config.json +0 -3
  168. package/ecomplus-stores/iluminim/functions/example.env +0 -10
  169. package/ecomplus-stores/iluminim/functions/many/index.js +0 -14
  170. package/ecomplus-stores/iluminim/functions/many/package.json +0 -22
  171. package/ecomplus-stores/iluminim/functions/ssr/.eslintrc.cjs +0 -6
  172. package/ecomplus-stores/iluminim/functions/ssr/astro.config.mjs +0 -4
  173. package/ecomplus-stores/iluminim/functions/ssr/content/blog/.gitkeep +0 -0
  174. package/ecomplus-stores/iluminim/functions/ssr/content/extra-pages/contato.json +0 -11
  175. package/ecomplus-stores/iluminim/functions/ssr/content/extra-pages/terms.json +0 -11
  176. package/ecomplus-stores/iluminim/functions/ssr/content/extra-pages/trocas.json +0 -11
  177. package/ecomplus-stores/iluminim/functions/ssr/content/layout.json +0 -57
  178. package/ecomplus-stores/iluminim/functions/ssr/content/pages/home.json +0 -70
  179. package/ecomplus-stores/iluminim/functions/ssr/content/settings.json +0 -65
  180. package/ecomplus-stores/iluminim/functions/ssr/index.js +0 -18
  181. package/ecomplus-stores/iluminim/functions/ssr/package.json +0 -31
  182. package/ecomplus-stores/iluminim/functions/ssr/public/admin/.gitkeep +0 -2
  183. package/ecomplus-stores/iluminim/functions/ssr/public/assets/cms-preview.css +0 -274
  184. package/ecomplus-stores/iluminim/functions/ssr/public/assets/cms.css +0 -114
  185. package/ecomplus-stores/iluminim/functions/ssr/public/assets/cvv.png +0 -0
  186. package/ecomplus-stores/iluminim/functions/ssr/public/assets/img-placeholder.png +0 -0
  187. package/ecomplus-stores/iluminim/functions/ssr/public/assets/payments.png +0 -0
  188. package/ecomplus-stores/iluminim/functions/ssr/public/assets/ssl-safe.png +0 -0
  189. package/ecomplus-stores/iluminim/functions/ssr/public/img/icon.png +0 -0
  190. package/ecomplus-stores/iluminim/functions/ssr/public/img/large-icon.png +0 -0
  191. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/banner-chamada-desktop-9x81zmd91q.webp +0 -0
  192. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/banner2.webp +0 -0
  193. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/chamada-mobile-q1c6om6jx4.webp +0 -0
  194. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/ecom-icon.png +0 -0
  195. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/headphone.webp +0 -0
  196. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/logo.webp +0 -0
  197. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/og-image.png +0 -0
  198. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/passion.webp +0 -0
  199. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/rect8589.png +0 -0
  200. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/rect859.png +0 -0
  201. package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/rect89.webp +0 -0
  202. package/ecomplus-stores/iluminim/functions/ssr/public/robots.txt +0 -6
  203. package/ecomplus-stores/iluminim/functions/ssr/scripts/build.sh +0 -14
  204. package/ecomplus-stores/iluminim/functions/ssr/src/assets/style.css +0 -65
  205. package/ecomplus-stores/iluminim/functions/ssr/src/components/AccountMenu.vue +0 -95
  206. package/ecomplus-stores/iluminim/functions/ssr/src/components/Banner.vue +0 -57
  207. package/ecomplus-stores/iluminim/functions/ssr/src/components/BannersGrid.astro +0 -25
  208. package/ecomplus-stores/iluminim/functions/ssr/src/components/CartItem.vue +0 -64
  209. package/ecomplus-stores/iluminim/functions/ssr/src/components/CartSidebar.vue +0 -66
  210. package/ecomplus-stores/iluminim/functions/ssr/src/components/Countdown.vue +0 -79
  211. package/ecomplus-stores/iluminim/functions/ssr/src/components/HeroSlider.vue +0 -52
  212. package/ecomplus-stores/iluminim/functions/ssr/src/components/PitchBar.vue +0 -56
  213. package/ecomplus-stores/iluminim/functions/ssr/src/components/Prices.vue +0 -95
  214. package/ecomplus-stores/iluminim/functions/ssr/src/components/ProductCard.vue +0 -117
  215. package/ecomplus-stores/iluminim/functions/ssr/src/components/ProductShelf.vue +0 -57
  216. package/ecomplus-stores/iluminim/functions/ssr/src/components/ProductsCountdown.vue +0 -20
  217. package/ecomplus-stores/iluminim/functions/ssr/src/components/SearchModal.vue +0 -6
  218. package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopFooter.vue +0 -149
  219. package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopHeader.vue +0 -158
  220. package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopHeaderMenu.vue +0 -58
  221. package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopHeaderSubmenu.vue +0 -88
  222. package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopSidenav.vue +0 -61
  223. package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopSidenavCategory.vue +0 -80
  224. package/ecomplus-stores/iluminim/functions/ssr/src/env.d.ts +0 -13
  225. package/ecomplus-stores/iluminim/functions/ssr/src/layouts/Base.astro +0 -16
  226. package/ecomplus-stores/iluminim/functions/ssr/src/layouts/Checkout.astro +0 -0
  227. package/ecomplus-stores/iluminim/functions/ssr/src/layouts/PageFooter.astro +0 -68
  228. package/ecomplus-stores/iluminim/functions/ssr/src/layouts/PageHeader.astro +0 -42
  229. package/ecomplus-stores/iluminim/functions/ssr/src/main/Fallback.astro +0 -10
  230. package/ecomplus-stores/iluminim/functions/ssr/src/main/Home.astro +0 -49
  231. package/ecomplus-stores/iluminim/functions/ssr/src/main/Sections.astro +0 -42
  232. package/ecomplus-stores/iluminim/functions/ssr/src/main/Wildcard.astro +0 -18
  233. package/ecomplus-stores/iluminim/functions/ssr/src/pages/[...slug].astro +0 -40
  234. package/ecomplus-stores/iluminim/functions/ssr/src/pages/_vue.ts +0 -3
  235. package/ecomplus-stores/iluminim/functions/ssr/src/pages/app/account.astro +0 -0
  236. package/ecomplus-stores/iluminim/functions/ssr/src/pages/app/index.astro +0 -0
  237. package/ecomplus-stores/iluminim/functions/ssr/src/pages/index.astro +0 -37
  238. package/ecomplus-stores/iluminim/functions/ssr/src/pages/~fallback.astro +0 -25
  239. package/ecomplus-stores/iluminim/functions/ssr/src/scripts/InlineScripts.astro +0 -10
  240. package/ecomplus-stores/iluminim/functions/ssr/tailwind.config.cjs +0 -13
  241. package/ecomplus-stores/iluminim/functions/ssr/tsconfig.json +0 -12
  242. package/ecomplus-stores/iluminim/functions/ssr/uno.config.cjs +0 -5
  243. package/ecomplus-stores/iluminim/functions/with-apps/index.js +0 -12
  244. package/ecomplus-stores/iluminim/functions/with-apps/package.json +0 -22
  245. package/ecomplus-stores/iluminim/package.json +0 -31
  246. package/ecomplus-stores/iluminim/scripts/install.sh +0 -24
  247. package/ecomplus-stores/monocard/functions/ssr/src/components/DocDescription.astro +0 -30
  248. package/packages/storefront/src/lib/components/ContentClearfix.astro +0 -15
@@ -1,42 +0,0 @@
1
- ---
2
- import api from '@cloudcommerce/api';
3
- import { usePageSections } from '@@sf/layouts/use-page-main';
4
- import BannersGrid from '~/components/BannersGrid.astro';
5
- import ProductShelf from '~/components/ProductShelf.vue';
6
- import ProductsCountdown, { type Props as ProductsCountdownProps }
7
- from '~/components/ProductsCountdown.vue';
8
-
9
- const { routeContext } = Astro.locals;
10
- const { sections } = await usePageSections({
11
- routeContext,
12
- handleCustomSection: async (type, content) => {
13
- if (type === 'c:products-countdown') {
14
- const {
15
- data: {
16
- result: products,
17
- },
18
- } = await api.get('search/v1', {
19
- params: { sku: content.skus },
20
- });
21
- const props: ProductsCountdownProps = { products };
22
- return { props };
23
- }
24
- return { props: content };
25
- },
26
- });
27
- ---
28
-
29
- <article class="my-9 md:my-12">
30
- {sections.map(({ type, props }) => {
31
- switch (type) {
32
- case 'product-shelf':
33
- return <ProductShelf {...props} client:visible />
34
- case 'banners-grid':
35
- return <BannersGrid {...props} />
36
- case 'c:products-countdown':
37
- return <ProductsCountdown {...props} />
38
- default:
39
- return <div data-section={type}></div>
40
- }
41
- })}
42
- </article>
@@ -1,18 +0,0 @@
1
- ---
2
- const { fetchingApiContext, apiContext } = Astro.locals.routeContext;
3
-
4
- await fetchingApiContext;
5
- const apiDoc = apiContext.doc;
6
- ---
7
-
8
- <main>
9
- {apiDoc &&
10
- <h1>Hello <span class="text-gradient">{apiDoc.name}</span></h1>
11
- <hr>
12
- <div class="mt-3">
13
- <mark>{apiDoc._id}</mark> from <i>{apiContext.resource}</i>
14
- <p>{Math.random()}</p>
15
- <em>Lorem ipsum dolor sit amet</em>
16
- </div>
17
- }
18
- </main>
@@ -1,40 +0,0 @@
1
- ---
2
- import api from '@cloudcommerce/api';
3
- import loadRouteContext, { RouteContext } from '@@sf/ssr-context';
4
- import BaseHead from '@@sf/layouts/BaseHead.astro';
5
- import Base from '~/layouts/Base.astro';
6
- import PageHeader from '~/layouts/PageHeader.astro';
7
- import WildcardMain from '~/main/Wildcard.astro';
8
-
9
- if (String(Astro.params.slug).endsWith('.css.map')) {
10
- return new Response(null, { status: 404 });
11
- }
12
-
13
- let routeContext: RouteContext | undefined;
14
- let loadError: any;
15
- try {
16
- routeContext = await loadRouteContext(Astro);
17
- } catch (err: any) {
18
- if (err.astroResponse) {
19
- return err.astroResponse;
20
- }
21
- loadError = err;
22
- }
23
-
24
- export async function getStaticPaths() {
25
- return (await api.get('products?sort=-sales&limit=4&fields=slug'))
26
- .data.result.map(({ slug }) => ({ params: { slug } }));
27
- }
28
- ---
29
-
30
- <!DOCTYPE html>
31
- <html lang={routeContext?.lang.replace('_', '-')}>
32
- {routeContext &&
33
- <Base>
34
- <BaseHead slot="base-head" />
35
- <PageHeader />
36
- <WildcardMain />
37
- </Base>
38
- }
39
- {loadError && <Fragment set:html={loadError.responseHTML} />}
40
- </html>
@@ -1,3 +0,0 @@
1
- import createApp from '@@sf/pages/_vue';
2
-
3
- export default createApp;
@@ -1,37 +0,0 @@
1
- ---
2
- import loadRouteContext, { RouteContext } from '@@sf/ssr-context';
3
- import BaseHead from '@@sf/layouts/BaseHead.astro';
4
- import Base from '~/layouts/Base.astro';
5
- import PageHeader from '~/layouts/PageHeader.astro';
6
- import PageFooter from '~/layouts/PageFooter.astro';
7
- import HomeMain from '~/main/Home.astro';
8
-
9
- let routeContext: RouteContext | undefined;
10
- let loadError: any;
11
- try {
12
- routeContext = await loadRouteContext(Astro);
13
- /* Faster SSR without store categories (default) prefetch:
14
- routeContext = await loadRouteContext(Astro, {
15
- apiPrefetchEndpoints: [],
16
- });
17
- */
18
- } catch (err: any) {
19
- if (err.astroResponse) {
20
- return err.astroResponse;
21
- }
22
- loadError = err;
23
- }
24
- ---
25
-
26
- <!DOCTYPE html>
27
- <html lang={routeContext?.lang.replace('_', '-')}>
28
- {routeContext &&
29
- <Base>
30
- <BaseHead slot="base-head" />
31
- <PageHeader />
32
- <HomeMain />
33
- <PageFooter />
34
- </Base>
35
- }
36
- {loadError && <Fragment set:html={loadError.responseHTML} />}
37
- </html>
@@ -1,25 +0,0 @@
1
- ---
2
- import loadRouteContext, { RouteContext } from '@@sf/ssr-context';
3
- import BaseHead from '@@sf/layouts/BaseHead.astro';
4
- import Base from '~/layouts/Base.astro';
5
- import PageHeader from '~/layouts/PageHeader.astro';
6
- import FallbackMain from '~/main/Fallback.astro';
7
-
8
- let routeContext: RouteContext;
9
- try {
10
- routeContext = await loadRouteContext(Astro);
11
- } catch (err: any) {
12
- return err.astroResponse;
13
- }
14
-
15
- // export const prerender = true;
16
- ---
17
-
18
- <!DOCTYPE html>
19
- <html lang={routeContext?.lang.replace('_', '-')}>
20
- <Base>
21
- <BaseHead slot="base-head" />
22
- <PageHeader />
23
- <FallbackMain />
24
- </Base>
25
- </html>
@@ -1,10 +0,0 @@
1
- <script is:inline>
2
- window.$firebaseConfig = {
3
- apiKey: "AIzaSyDY08utue456KIi4tjXomMxX5PC3y1u6cE",
4
- authDomain: "ecom2iluminim.firebaseapp.com",
5
- projectId: "ecom2iluminim",
6
- storageBucket: "ecom2iluminim.appspot.com",
7
- messagingSenderId: "725654553320",
8
- appId: "1:725654553320:web:2f0607a479b52ddb783f5d"
9
- };
10
- </script>
@@ -1,13 +0,0 @@
1
- process.env.STOREFRONT_BASE_DIR = __dirname;
2
-
3
- // eslint-disable-next-line import/no-extraneous-dependencies
4
- const { genTailwindConfig } = require('@cloudcommerce/storefront/config/storefront.tailwind.cjs');
5
-
6
- const themeOptions = {
7
- // generalIconSets: ['tabler'],
8
- };
9
-
10
- module.exports = {
11
- ...genTailwindConfig(themeOptions),
12
- themeOptions,
13
- };
@@ -1,12 +0,0 @@
1
- {
2
- "extends": "@cloudcommerce/storefront/tsconfig.json",
3
- "compilerOptions": {
4
- "baseUrl": ".",
5
- "paths": {
6
- "@@i18n": ["./node_modules/@cloudcommerce/i18n/src/pt_br.ts"],
7
- "@@sf/*": ["./node_modules/@cloudcommerce/storefront/src/lib/*"],
8
- "~/*": ["./src/*"],
9
- "content/*": ["./content/*"],
10
- }
11
- }
12
- }
@@ -1,5 +0,0 @@
1
- // eslint-disable-next-line import/no-extraneous-dependencies
2
- const { genUnoCSSConfig } = require('@cloudcommerce/storefront/config/storefront.unocss.cjs');
3
- const tailwindConfig = require('./tailwind.config.cjs');
4
-
5
- export default genUnoCSSConfig(tailwindConfig);
@@ -1,12 +0,0 @@
1
- import '@cloudcommerce/firebase/lib/init';
2
- import config from '@cloudcommerce/firebase/config';
3
- import mergeConfig from './config.json' assert { type: 'json' };
4
-
5
- config.set({
6
- ...mergeConfig,
7
- hello: 'from store',
8
- });
9
-
10
- export * from '@cloudcommerce/modules/firebase';
11
-
12
- export * from '@cloudcommerce/events/firebase';
@@ -1,22 +0,0 @@
1
- {
2
- "name": "iluminim-with-apps",
3
- "private": true,
4
- "type": "module",
5
- "scripts": {
6
- "build": "echo '>> Run build from repository root'",
7
- "serve": "firebase emulators:start --only functions",
8
- "shell": "firebase functions:shell",
9
- "start": "npm run shell",
10
- "deploy": "firebase deploy --only functions",
11
- "logs": "firebase functions:log"
12
- },
13
- "engines": {
14
- "node": "18"
15
- },
16
- "main": "index.js",
17
- "dependencies": {
18
- "@cloudcommerce/events": "^0.26.3",
19
- "@cloudcommerce/firebase": "^0.26.3",
20
- "@cloudcommerce/modules": "^0.26.3"
21
- }
22
- }
@@ -1,31 +0,0 @@
1
- {
2
- "name": "@ecomplus-stores/iluminim",
3
- "private": true,
4
- "type": "module",
5
- "description": "E-Com Plus Cloud Commerce starter store",
6
- "scripts": {
7
- "dev": "cloudcommerce",
8
- "logs": "cloudcommerce logs",
9
- "serve": "cloudcommerce serve",
10
- "shell": "cloudcommerce shell",
11
- "start": "cloudcommerce start",
12
- "build": "cloudcommerce build",
13
- "predeploy": "cloudcommerce predeploy",
14
- "deploy": "cloudcommerce deploy",
15
- "login": "cloudcommerce login",
16
- "setup": "bash scripts/install.sh && cloudcommerce setup",
17
- "setup:quiet": "cloudcommerce setup --no-deploy --no-commit"
18
- },
19
- "main": "functions/index.js",
20
- "author": "E-Com Club Softwares para E-commerce <ti@e-com.club>",
21
- "license": "Apache 2.0 with Commons Clause",
22
- "bugs": {
23
- "url": "https://github.com/ecomplus/cloud-commerce/issues"
24
- },
25
- "dependencies": {
26
- "@cloudcommerce/cli": "^0.26.3"
27
- },
28
- "devDependencies": {
29
- "@cloudcommerce/eslint": "^0.26.3"
30
- }
31
- }
@@ -1,24 +0,0 @@
1
- #!/bin/bash
2
-
3
- if [ ! -d "./node_modules" ]; then
4
- echo '>> Install root dev dependencies:'
5
- if [ -f "./package-lock.json" ]; then
6
- npm ci
7
- else
8
- npm i
9
- fi
10
- fi
11
- echo '>> Install each function dependencies:'
12
- cd functions
13
- for d in */ ; do
14
- cd $d
15
- if [ ! -d "./node_modules" ]; then
16
- if [ -f "./package-lock.json" ]; then
17
- npm ci
18
- else
19
- npm i
20
- fi
21
- fi
22
- cd ..
23
- done
24
- cd ..
@@ -1,30 +0,0 @@
1
- ---
2
- import type {
3
- Products,
4
- Categories,
5
- Brands,
6
- Collections,
7
- } from '@cloudcommerce/api/types';
8
- import { i19description } from '@@i18n';
9
- import ContentClearfix from '@@sf/components/ContentClearfix.astro';
10
-
11
- export interface Props {
12
- apiDoc: Partial<Products | Categories | Brands | Collections>;
13
- title?: string;
14
- }
15
-
16
- const { apiDoc, title } = Astro.props;
17
- const html = apiDoc.body_html || apiDoc.body_text;
18
- ---
19
-
20
- {html &&
21
- <section class="ui-section">
22
- <p class="text-2xl font-medium lowercase text-base-700">
23
- <a href="#description" id="description">
24
- <i class="i-link text-base-400 mr-1"></i>
25
- {title || i19description}
26
- </a>
27
- </p>
28
- <ContentClearfix html={html} />
29
- </section>
30
- }
@@ -1,15 +0,0 @@
1
- ---
2
- export interface Props {
3
- html: string;
4
- }
5
-
6
- const { html } = Astro.props;
7
- const parsedHTML = html.replace(/<(img|iframe) /g, '<$1 loading="lazy" ');
8
- ---
9
-
10
- <article class="overflow-x-auto lg:overflow-x-hidden prose !max-w-full">
11
- <div
12
- class="[&_table]:max-w-full [&_img]:max-w-full [&_iframe]:max-w-full"
13
- set:html={parsedHTML}
14
- ></div>
15
- </article>