cloudcommerce 0.1.2 → 0.1.4

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 (140) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/ecomplus-stores/monocard/functions/core/package.json +1 -1
  3. package/ecomplus-stores/monocard/functions/events/package.json +2 -2
  4. package/ecomplus-stores/monocard/functions/modules/package.json +2 -2
  5. package/ecomplus-stores/monocard/functions/passport/package.json +2 -2
  6. package/ecomplus-stores/monocard/functions/ssr/package.json +6 -6
  7. package/ecomplus-stores/monocard/package.json +1 -1
  8. package/ecomplus-stores/tia-sonia/functions/core/package.json +1 -1
  9. package/ecomplus-stores/tia-sonia/functions/events/package.json +2 -2
  10. package/ecomplus-stores/tia-sonia/functions/modules/package.json +2 -2
  11. package/ecomplus-stores/tia-sonia/functions/passport/package.json +2 -2
  12. package/ecomplus-stores/tia-sonia/functions/ssr/content/settings.json +3 -2
  13. package/ecomplus-stores/tia-sonia/functions/ssr/package.json +9 -6
  14. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/fimdeano1920x736.jpg +0 -0
  15. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/granolas-em-pote.png +0 -0
  16. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/granolas-espalhadas.png +0 -0
  17. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/tiasonia-logo-mono.png +0 -0
  18. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/tiasonia-logo-var.png +0 -0
  19. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/tiasonia-logo.png +0 -0
  20. package/ecomplus-stores/tia-sonia/functions/ssr/src/components/TheHeader.vue +146 -7
  21. package/ecomplus-stores/tia-sonia/functions/ssr/src/components/header/HeaderBarLink.vue +5 -0
  22. package/ecomplus-stores/tia-sonia/functions/ssr/src/components/header/HeaderButtonLink.vue +1 -1
  23. package/ecomplus-stores/tia-sonia/functions/ssr/src/components/header/HeaderNav.vue +7 -6
  24. package/ecomplus-stores/tia-sonia/functions/ssr/src/layouts/Base.astro +19 -7
  25. package/ecomplus-stores/tia-sonia/functions/ssr/src/layouts/Pages.astro +17 -1
  26. package/ecomplus-stores/tia-sonia/functions/ssr/src/layouts/PagesHeader.astro +1 -9
  27. package/ecomplus-stores/tia-sonia/functions/ssr/src/main/Home.astro +15 -8
  28. package/ecomplus-stores/tia-sonia/functions/ssr/tailwind.config.cjs +9 -1
  29. package/ecomplus-stores/tia-sonia/functions/ssr/uno.config.cjs +3 -1
  30. package/ecomplus-stores/tia-sonia/package.json +1 -1
  31. package/package.json +6 -5
  32. package/packages/api/package.json +1 -1
  33. package/packages/apps/correios/package.json +1 -1
  34. package/packages/apps/custom-payment/package.json +1 -1
  35. package/packages/apps/custom-shipping/package.json +1 -1
  36. package/packages/apps/discounts/package.json +1 -1
  37. package/packages/apps/emails/package.json +2 -2
  38. package/packages/apps/frenet/events.js +1 -0
  39. package/packages/apps/frenet/lib/frenet-events.d.ts +6 -0
  40. package/packages/apps/frenet/lib/frenet-events.js +19 -0
  41. package/packages/apps/frenet/lib/frenet-events.js.map +1 -0
  42. package/packages/apps/frenet/lib/functions-lib/database.d.ts +18 -0
  43. package/packages/apps/frenet/lib/functions-lib/database.js +128 -0
  44. package/packages/apps/frenet/lib/functions-lib/database.js.map +1 -0
  45. package/packages/apps/frenet/lib/functions-lib/events-to-frenet.d.ts +3 -0
  46. package/packages/apps/frenet/lib/functions-lib/events-to-frenet.js +48 -0
  47. package/packages/apps/frenet/lib/functions-lib/events-to-frenet.js.map +1 -0
  48. package/packages/apps/frenet/lib/functions-lib/fetch-tracking-code.d.ts +2 -0
  49. package/packages/apps/frenet/lib/functions-lib/fetch-tracking-code.js +19 -0
  50. package/packages/apps/frenet/lib/functions-lib/fetch-tracking-code.js.map +1 -0
  51. package/packages/apps/frenet/lib/functions-lib/remove-delivered.d.ts +2 -0
  52. package/packages/apps/frenet/lib/functions-lib/remove-delivered.js +30 -0
  53. package/packages/apps/frenet/lib/functions-lib/remove-delivered.js.map +1 -0
  54. package/packages/apps/frenet/lib/functions-lib/tracking-codes.d.ts +2 -0
  55. package/packages/apps/frenet/lib/functions-lib/tracking-codes.js +138 -0
  56. package/packages/apps/frenet/lib/functions-lib/tracking-codes.js.map +1 -0
  57. package/packages/apps/frenet/lib/functions-lib/update-fulfillments.d.ts +5 -0
  58. package/packages/apps/frenet/lib/functions-lib/update-fulfillments.js +49 -0
  59. package/packages/apps/frenet/lib/functions-lib/update-fulfillments.js.map +1 -0
  60. package/packages/apps/frenet/package.json +11 -3
  61. package/packages/apps/frenet/src/frenet-events.ts +25 -0
  62. package/packages/apps/frenet/src/functions-lib/database.ts +159 -0
  63. package/packages/apps/frenet/src/functions-lib/events-to-frenet.ts +62 -0
  64. package/packages/apps/frenet/src/functions-lib/fetch-tracking-code.ts +22 -0
  65. package/packages/apps/frenet/src/functions-lib/remove-delivered.ts +31 -0
  66. package/packages/apps/frenet/src/functions-lib/tracking-codes.ts +170 -0
  67. package/packages/apps/frenet/src/functions-lib/update-fulfillments.ts +56 -0
  68. package/packages/apps/galaxpay/package.json +3 -3
  69. package/packages/apps/infinitepay/package.json +2 -2
  70. package/packages/apps/jadlog/package.json +1 -1
  71. package/packages/apps/loyalty-points/package.json +1 -1
  72. package/packages/apps/mercadopago/package.json +2 -2
  73. package/packages/apps/pagarme/package.json +3 -3
  74. package/packages/apps/pix/package.json +2 -2
  75. package/packages/apps/tiny-erp/package.json +2 -2
  76. package/packages/cli/package.json +1 -1
  77. package/packages/config/package.json +1 -1
  78. package/packages/emails/package.json +1 -1
  79. package/packages/events/lib/firebase.js +2 -0
  80. package/packages/events/lib/firebase.js.map +1 -1
  81. package/packages/events/package.json +3 -2
  82. package/packages/events/src/firebase.ts +2 -0
  83. package/packages/firebase/lib/config.d.ts +1 -0
  84. package/packages/firebase/lib/config.js +4 -0
  85. package/packages/firebase/lib/config.js.map +1 -1
  86. package/packages/firebase/package.json +2 -2
  87. package/packages/firebase/src/config.ts +5 -0
  88. package/packages/i18n/package.json +1 -1
  89. package/packages/modules/package.json +2 -2
  90. package/packages/passport/package.json +2 -2
  91. package/packages/ssr/package.json +5 -4
  92. package/packages/storefront/dist/client/HeaderButtons.300c19e5.js +1 -0
  93. package/packages/storefront/dist/client/Prices.d79bd862.js +1 -0
  94. package/packages/storefront/dist/client/{ProductCard.7b68cc35.js → ProductCard.6b27d9fa.js} +1 -1
  95. package/packages/storefront/dist/client/assets/_...slug_.4dbd1d47.css +1 -0
  96. package/packages/storefront/dist/client/assets/server.4d9646d8.css +1 -0
  97. package/packages/storefront/dist/client/chunks/{HeaderButtons.cbbb059d.js → HeaderButtons.1abd5bf4.js} +1 -1
  98. package/packages/storefront/dist/client/chunks/{LoginForm.ac2f1b1f.js → LoginForm.7e7d6137.js} +1 -1
  99. package/packages/storefront/dist/client/chunks/Prices.vue_vue_type_script_setup_true_lang.b29421b3.js +1 -0
  100. package/packages/storefront/dist/client/chunks/_plugin-vue_export-helper.fc452b02.js +1 -0
  101. package/packages/storefront/dist/client/chunks/runtime-core.esm-bundler.b4556b35.js +1 -0
  102. package/packages/storefront/dist/client/client.2a3e5a58.js +1 -0
  103. package/packages/storefront/dist/client/sw.js +1 -1
  104. package/packages/storefront/dist/client/~partytown/partytown-atomics.js +2 -2
  105. package/packages/storefront/dist/client/~partytown/partytown-media.js +1 -1
  106. package/packages/storefront/dist/client/~partytown/partytown-sw.js +2 -2
  107. package/packages/storefront/dist/client/~partytown/partytown.js +2 -2
  108. package/packages/storefront/dist/server/entry.mjs +35 -1560
  109. package/packages/storefront/package.json +7 -8
  110. package/packages/storefront/src/lib/assets/tooltip.css +43 -0
  111. package/packages/storefront/src/lib/components/Prices.vue +1 -1
  112. package/packages/storefront/src/lib/layouts/BaseBody.astro +1 -1
  113. package/packages/storefront/src/lib/pages/_vue.ts +0 -2
  114. package/packages/storefront/tailwind.config.cjs +30 -19
  115. package/packages/storefront/uno.config.cjs +20 -19
  116. package/packages/types/package.json +1 -1
  117. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/banner1.png +0 -0
  118. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/banner2.png +0 -0
  119. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/banner2.webp +0 -0
  120. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/headless.png +0 -0
  121. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/headphone.png +0 -0
  122. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/headphone.webp +0 -0
  123. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/logo.png +0 -0
  124. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/logo.webp +0 -0
  125. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/passion.png +0 -0
  126. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/passion.webp +0 -0
  127. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/pwa-reliable.png +0 -0
  128. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/rect8589.png +0 -0
  129. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/rect859.png +0 -0
  130. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/rect89.png +0 -0
  131. package/ecomplus-stores/tia-sonia/functions/ssr/public/img/uploads/rect89.webp +0 -0
  132. package/ecomplus-stores/tia-sonia/functions/ssr/src/components/header/HeaderNavLink.vue +0 -5
  133. package/packages/storefront/dist/client/HeaderButtons.8acf8a3b.js +0 -1
  134. package/packages/storefront/dist/client/Prices.9099fe99.js +0 -1
  135. package/packages/storefront/dist/client/assets/_...slug_.f19a16ca.css +0 -1
  136. package/packages/storefront/dist/client/assets/server.55b8d73d.css +0 -1
  137. package/packages/storefront/dist/client/chunks/Prices.vue_vue_type_script_setup_true_lang.c37148c1.js +0 -1
  138. package/packages/storefront/dist/client/chunks/_plugin-vue_export-helper.5ccc5d75.js +0 -1
  139. package/packages/storefront/dist/client/chunks/runtime-core.esm-bundler.d5646b29.js +0 -1
  140. package/packages/storefront/dist/client/client.9783ef49.js +0 -1
package/CHANGELOG.md CHANGED
@@ -2,6 +2,28 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.1.4](https://github.com/ecomplus/cloud-commerce/compare/v0.1.3...v0.1.4) (2022-12-27)
6
+
7
+
8
+ ### Features
9
+
10
+ * **frenet:** Create Frenet app events for shipping status auto-update ([#97](https://github.com/ecomplus/cloud-commerce/issues/97)) ([d71b46b](https://github.com/ecomplus/cloud-commerce/commit/d71b46b617120f143647fa7d4ca4853ebd45568e))
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * **deps:** Update dependency unocss to ^0.48.0 ([#98](https://github.com/ecomplus/cloud-commerce/issues/98)) ([d25cc84](https://github.com/ecomplus/cloud-commerce/commit/d25cc84b88a3b9009333cd00e8a03a2b432d1cca))
16
+ * **storefront:** Update default bold/subtle diffs ([7380a8e](https://github.com/ecomplus/cloud-commerce/commit/7380a8e7bb7a26048fe97eebffda7a177ba90db5))
17
+ * **storefront:** Use RGB values on CSS vars to support color utils with opacity ([5c37128](https://github.com/ecomplus/cloud-commerce/commit/5c371288e101b111bdfb7f88da9755ebf03b12b0)), closes [#discussioncomment-4491119](https://github.com/ecomplus/cloud-commerce/issues/discussioncomment-4491119)
18
+
19
+ ### [0.1.3](https://github.com/ecomplus/cloud-commerce/compare/v0.1.2...v0.1.3) (2022-12-24)
20
+
21
+
22
+ ### Bug Fixes
23
+
24
+ * **deps:** Update all non-major dependencies ([dae94d3](https://github.com/ecomplus/cloud-commerce/commit/dae94d37862f3b01c1799cc7be4906893b111a46))
25
+ * **ssr:** Add `@vueuse/core` and `@headlessui/vue` to SSR deps ([6c7204e](https://github.com/ecomplus/cloud-commerce/commit/6c7204ee3569a81075e36407fd962f36fac1c669))
26
+
5
27
  ### [0.1.2](https://github.com/ecomplus/cloud-commerce/compare/v0.1.1...v0.1.2) (2022-12-22)
6
28
 
7
29
 
@@ -15,6 +15,6 @@
15
15
  },
16
16
  "main": "index.js",
17
17
  "dependencies": {
18
- "@cloudcommerce/firebase": "^0.1.1"
18
+ "@cloudcommerce/firebase": "^0.1.3"
19
19
  }
20
20
  }
@@ -15,7 +15,7 @@
15
15
  },
16
16
  "main": "index.js",
17
17
  "dependencies": {
18
- "@cloudcommerce/events": "^0.1.1",
19
- "@cloudcommerce/firebase": "^0.1.1"
18
+ "@cloudcommerce/events": "^0.1.3",
19
+ "@cloudcommerce/firebase": "^0.1.3"
20
20
  }
21
21
  }
@@ -15,7 +15,7 @@
15
15
  },
16
16
  "main": "index.js",
17
17
  "dependencies": {
18
- "@cloudcommerce/firebase": "^0.1.1",
19
- "@cloudcommerce/modules": "^0.1.1"
18
+ "@cloudcommerce/firebase": "^0.1.3",
19
+ "@cloudcommerce/modules": "^0.1.3"
20
20
  }
21
21
  }
@@ -15,7 +15,7 @@
15
15
  },
16
16
  "main": "index.js",
17
17
  "dependencies": {
18
- "@cloudcommerce/firebase": "^0.1.1",
19
- "@cloudcommerce/passport": "^0.1.1"
18
+ "@cloudcommerce/firebase": "^0.1.3",
19
+ "@cloudcommerce/passport": "^0.1.3"
20
20
  }
21
21
  }
@@ -19,14 +19,14 @@
19
19
  "dependencies": {
20
20
  "@astrojs/image": "^0.12.1",
21
21
  "@astrojs/node": "^4.0.0",
22
- "@cloudcommerce/api": "^0.1.1",
23
- "@cloudcommerce/firebase": "^0.1.1",
24
- "@cloudcommerce/ssr": "^0.1.1"
22
+ "@cloudcommerce/api": "^0.1.3",
23
+ "@cloudcommerce/firebase": "^0.1.3",
24
+ "@cloudcommerce/ssr": "^0.1.3"
25
25
  },
26
26
  "devDependencies": {
27
- "@cloudcommerce/i18n": "^0.1.1",
28
- "@cloudcommerce/storefront": "^0.1.1",
29
- "@cloudcommerce/types": "^0.1.1",
27
+ "@cloudcommerce/i18n": "^0.1.3",
28
+ "@cloudcommerce/storefront": "^0.1.3",
29
+ "@cloudcommerce/types": "^0.1.3",
30
30
  "@iconify-json/arcticons": "^1.1.34",
31
31
  "@iconify-json/wpf": "^1.1.3",
32
32
  "lottie-web": "^5.10.0",
@@ -23,6 +23,6 @@
23
23
  "url": "https://github.com/ecomplus/cloud-commerce/issues"
24
24
  },
25
25
  "dependencies": {
26
- "@cloudcommerce/cli": "^0.1.1"
26
+ "@cloudcommerce/cli": "^0.1.3"
27
27
  }
28
28
  }
@@ -15,6 +15,6 @@
15
15
  },
16
16
  "main": "index.js",
17
17
  "dependencies": {
18
- "@cloudcommerce/firebase": "^0.1.1"
18
+ "@cloudcommerce/firebase": "^0.1.3"
19
19
  }
20
20
  }
@@ -15,7 +15,7 @@
15
15
  },
16
16
  "main": "index.js",
17
17
  "dependencies": {
18
- "@cloudcommerce/events": "^0.1.1",
19
- "@cloudcommerce/firebase": "^0.1.1"
18
+ "@cloudcommerce/events": "^0.1.3",
19
+ "@cloudcommerce/firebase": "^0.1.3"
20
20
  }
21
21
  }
@@ -15,7 +15,7 @@
15
15
  },
16
16
  "main": "index.js",
17
17
  "dependencies": {
18
- "@cloudcommerce/firebase": "^0.1.1",
19
- "@cloudcommerce/modules": "^0.1.1"
18
+ "@cloudcommerce/firebase": "^0.1.3",
19
+ "@cloudcommerce/modules": "^0.1.3"
20
20
  }
21
21
  }
@@ -15,7 +15,7 @@
15
15
  },
16
16
  "main": "index.js",
17
17
  "dependencies": {
18
- "@cloudcommerce/firebase": "^0.1.1",
19
- "@cloudcommerce/passport": "^0.1.1"
18
+ "@cloudcommerce/firebase": "^0.1.3",
19
+ "@cloudcommerce/passport": "^0.1.3"
20
20
  }
21
21
  }
@@ -2,9 +2,10 @@
2
2
  "domain": "ecom2-tiasonia.web.app",
3
3
  "name": "Tia Sônia",
4
4
  "description": "My PWA Shop",
5
- "logo": "/img/uploads/logo.webp",
5
+ "logo": "/img/uploads/tiasonia-logo.png",
6
6
  "icon": "/img/uploads/large-icon.png",
7
- "primary_color": "#137c5c",
7
+ "primary_color": "#fdda25",
8
+ "secondary_color": "#1b365d",
8
9
  "email": "",
9
10
  "phone": "",
10
11
  "address": "",
@@ -19,14 +19,17 @@
19
19
  "dependencies": {
20
20
  "@astrojs/image": "^0.12.1",
21
21
  "@astrojs/node": "^4.0.0",
22
- "@cloudcommerce/api": "^0.1.1",
23
- "@cloudcommerce/firebase": "^0.1.1",
24
- "@cloudcommerce/ssr": "^0.1.1"
22
+ "@cloudcommerce/api": "^0.1.3",
23
+ "@cloudcommerce/firebase": "^0.1.3",
24
+ "@cloudcommerce/ssr": "^0.1.3"
25
25
  },
26
26
  "devDependencies": {
27
- "@cloudcommerce/i18n": "^0.1.1",
28
- "@cloudcommerce/storefront": "^0.1.1",
29
- "@cloudcommerce/types": "^0.1.1"
27
+ "@cloudcommerce/i18n": "^0.1.3",
28
+ "@cloudcommerce/storefront": "^0.1.3",
29
+ "@cloudcommerce/types": "^0.1.3",
30
+ "@fontsource/dm-serif-text": "^4.5.9",
31
+ "@fontsource/roboto-condensed": "^4.5.9",
32
+ "@iconify-json/tabler": "^1.1.53"
30
33
  },
31
34
  "pnpm": {
32
35
  "peerDependencyRules": {
@@ -1,5 +1,13 @@
1
1
  <script lang="ts" setup>
2
- import { toRefs, ImgHTMLAttributes } from 'vue';
2
+ import {
3
+ type ImgHTMLAttributes,
4
+ ref,
5
+ computed,
6
+ watch,
7
+ toRefs,
8
+ onMounted,
9
+ } from 'vue';
10
+ import { useWindowScroll } from '@vueuse/core';
3
11
 
4
12
  export interface Props {
5
13
  logo?: ImgHTMLAttributes;
@@ -10,26 +18,157 @@ const props = withDefaults(defineProps<Props>(), {
10
18
  logoAltHeading: 'h2',
11
19
  });
12
20
  const { logo } = toRefs(props);
21
+ const { y } = useWindowScroll();
22
+ const header = ref<HTMLElement | null>(null);
23
+ const logoImg = ref<HTMLElement | null>(null);
24
+ let height: number = (Number(logo.value.height) || 0) + 20;
25
+ onMounted(() => {
26
+ logoImg.value.onload = () => {
27
+ height = header.value.offsetHeight;
28
+ };
29
+ });
30
+ const isHidden = ref(false);
31
+ const isSticky = computed(() => y.value > height);
32
+ watch(y, (newY, oldY) => {
33
+ isHidden.value = newY > 0 && newY > oldY;
34
+ });
13
35
  </script>
14
36
 
15
37
  <template>
16
- <header class="header bg-surface bg-opacity-90 backdrop-blur-md
17
- sticky top-0 z-50 py-1 sm:py-2">
18
- <div class="container">
19
- <div class="grid grid-flow-col auto-cols-max justify-between items-center">
38
+ <header
39
+ class="header z-50 sticky top-0"
40
+ :class="[
41
+ isHidden ? 'opacity-0 -translate-y-full' : null,
42
+ isSticky ? 'bg-white/80 backdrop-blur-md shadow' : null,
43
+ ]"
44
+ style="transition: opacity var(--transition-slow), transform var(--transition)"
45
+ ref="header"
46
+ >
47
+ <div
48
+ class="container mx-auto relative py-1 sm:py-2 px-2 md:px-4 xl:px-7"
49
+ :class="isSticky
50
+ ? 'overflow-hidden'
51
+ : 'bg-white/70 rounded-t-md rounded-tl-none lg:pt-3 xl:pt-4 xl:pb-3'"
52
+ :style="{ marginTop: isSticky ? null : '70px' }"
53
+ >
54
+ <div
55
+ v-if="!isSticky"
56
+ class="absolute top-0 left-0 w-full flex justify-between"
57
+ style="height: 66px; margin-top: -60px"
58
+ >
59
+ <div class="mt-auto" style="padding-bottom: 6px">
60
+ <a
61
+ class="inline-block bg-white/70 text-secondary font-bold uppercase
62
+ rounded-t-md px-4 py-2 mr-2 lg:mr-3"
63
+ href="#"
64
+ >
65
+ <i class="i-building-store mr-1"></i> Conheça a Tia Sônia
66
+ </a>
67
+ <a
68
+ class="inline-block bg-secondary-subtle/70 text-white font-bold uppercase
69
+ rounded-t-md px-4 py-2"
70
+ href="#"
71
+ >
72
+ <i class="i-chevron-down mr-1"></i> Marcas parceiras
73
+ </a>
74
+ </div>
75
+ <div class="h-full flex flex-col-reverse justify-between text-sm text-right mr-4">
76
+ <div>
77
+ <a class="secondary hover:secondary-bold rounded p-2 px-3 mr-2" href="#">
78
+ <i class="i-calendar-time mr-1"></i> Assinatura Tia Sônia
79
+ <b class="ml-1">10% OFF</b>
80
+ </a>
81
+ <a class="primary-subtle hover:primary rounded p-2 px-3" href="#">
82
+ Indique e ganhe <i class="i-pig-money ml-1"></i>
83
+ </a>
84
+ </div>
85
+ <div class="text-white pr-1">
86
+ <nav>
87
+ <ul class="flex flex-row-reverse gap-3 lg:gap-4">
88
+ <li>
89
+ <a href="#">
90
+ <strong>Para Você</strong>
91
+ </a>
92
+ </li>
93
+ <li>
94
+ <a href="#">
95
+ Área do lojista
96
+ </a>
97
+ </li>
98
+ <li>
99
+ <a href="#">
100
+ Onde encontrar
101
+ </a>
102
+ </li>
103
+ <li>
104
+ <a href="#">
105
+ Contato
106
+ </a>
107
+ </li>
108
+ <li>
109
+ <a href="#">
110
+ <i class="i-notes"></i> Prescritores
111
+ </a>
112
+ </li>
113
+ </ul>
114
+ </nav>
115
+ </div>
116
+ </div>
117
+ </div>
118
+ <div class="grid grid-flow-col grid-cols-3 justify-between items-center">
20
119
  <slot name="aside">
21
120
  <div class="header__aside md:hidden">
22
121
  <div class="i-bars-3-bottom-left"></div>
23
122
  </div>
24
123
  </slot>
124
+ <nav>
125
+ <ul class="flex items-center gap-2 md:gap-3 text-sm">
126
+ <li>
127
+ <a
128
+ class="text-on-primary font-bold uppercase rounded px-4 py-2"
129
+ :class="isSticky ? 'bg-primary' : 'bg-primary/80'"
130
+ href="#"
131
+ >
132
+ <i class="i-chevron-down mr-1"></i> Produtos
133
+ </a>
134
+ </li>
135
+ <li class="flex-grow">
136
+ <form>
137
+ <label for="header-search" class="mb-2 sr-only">
138
+ Buscar
139
+ </label>
140
+ <div class="relative text-base-700">
141
+ <div class="absolute inset-y-0 left-0
142
+ flex items-center pl-3 pt-1 pointer-events-none">
143
+ <i class="i-search"></i>
144
+ </div>
145
+ <input
146
+ type="search"
147
+ id="header-search"
148
+ class="w-full pr-4 py-2 pl-9 text-sm bg-white/80 rounded border-none"
149
+ placeholder="Buscar granolas, snacks, coquinho ..."
150
+ required
151
+ />
152
+ </div>
153
+ </form>
154
+ </li>
155
+ </ul>
156
+ </nav>
25
157
  <slot name="logo" v-bind="{ logo }">
26
158
  <a v-if="logo" href="/">
27
159
  <component :is="(logo.alt && logoAltHeading) || 'span'" class="m-0">
28
- <img v-bind="logo" />
160
+ <img
161
+ v-bind="logo"
162
+ ref="logoImg"
163
+ class="w-auto mx-auto"
164
+ :style="isSticky
165
+ ? 'height: 80px; margin-bottom: -40px'
166
+ : 'height: 122px; margin-top: -76px'"
167
+ />
29
168
  </component>
30
169
  </a>
31
170
  </slot>
32
- <div class="flex items-center">
171
+ <div class="flex items-center justify-end">
33
172
  <slot name="actions">
34
173
  <slot name="nav" />
35
174
  <slot name="search" />
@@ -0,0 +1,5 @@
1
+ <template>
2
+ <a class="text-2xl text-secondary hover:text-secondary-bold ml-2">
3
+ <slot />
4
+ </a>
5
+ </template>
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <a class="text-2xl text-gray-accent hover:text-primary no-underline ml-2">
2
+ <a class="text-2xl text-secondary hover:text-secondary-bold ml-2">
3
3
  <slot />
4
4
  </a>
5
5
  </template>
@@ -1,9 +1,10 @@
1
- <script lang="ts" setup>
2
- import HeaderNavLink from '@@components/header/HeaderNavLink.vue';
3
- </script>
4
-
5
1
  <template>
6
- <nav class="font-semibold px-3">
7
- <HeaderNavLink>nav</HeaderNavLink>
2
+ <nav class="font-bold uppercase text-sm px-3 flex gap-2 lg:gap-4">
3
+ <a href="#" class="text-secondary hover:text-secondary-bold">
4
+ Mais vendidos
5
+ </a>
6
+ <a href="#" class="text-primary-800 hover:text-primary-900">
7
+ Promoções
8
+ </a>
8
9
  </nav>
9
10
  </template>
@@ -1,6 +1,11 @@
1
1
  ---
2
2
  import type { PageContext } from '@@sf/ssr-context';
3
3
  import Base from '@@sf/layouts/Base.astro';
4
+ import '@fontsource/dm-serif-text';
5
+ import '@fontsource/roboto-condensed';
6
+ import '@fontsource/roboto-condensed/400-italic.css';
7
+ import '@fontsource/roboto-condensed/700.css';
8
+ import '@fontsource/roboto-condensed/700-italic.css';
4
9
  import InlineScripts from '~/scripts/InlineScripts.astro';
5
10
 
6
11
  export interface Props {
@@ -17,18 +22,25 @@ const { pageContext, title } = Astro.props as Props;
17
22
  </Base>
18
23
 
19
24
  <style is:global>
20
- @media only screen and (prefers-color-scheme: dark) {
21
- :root:not([data-theme=light]) a:not([role=button]) {
22
- --color: var(--primary-100);
23
- }
24
- :root:not([data-theme=light]) a:not([role=button]):is([aria-current], :hover, :active, :focus) {
25
- --color: var(--primary-300);
26
- }
25
+ :root {
26
+ --custom-font-sans: "Roboto Condensed";
27
+ --font-brand: "DM Serif Text", serif;
28
+ --c-brand-yellow: rgb(253, 218, 37);
29
+ --c-brand-blue: rgb(27, 54, 93);
30
+ --c-brand-light-blue: rgb(0, 87, 183);
31
+ --un-prose-links: var(--c-secondary);
27
32
  }
28
33
  html {
29
34
  scroll-behavior: smooth;
30
35
  }
31
36
  body {
32
37
  overflow-x: hidden;
38
+ background-color: var(--c-brand-light-blue);
39
+ }
40
+ body > * {
41
+ @apply bg-white;
42
+ }
43
+ a {
44
+ transition: color var(--transition), background-color var(--transition);
33
45
  }
34
46
  </style>
@@ -12,8 +12,24 @@ const { pageContext, title } = Astro.props as Props;
12
12
  ---
13
13
 
14
14
  <Base pageContext={pageContext} title={title}>
15
+ <img
16
+ src="/img/uploads/granolas-espalhadas.png"
17
+ width="477"
18
+ height="396"
19
+ fetchpriority="low"
20
+ class="absolute bg-transparent rotate-180 top-0 -left-10 lg:left-6 max-w-full -z-10"
21
+ />
15
22
  <slot name="header">
16
23
  <Header pageContext={pageContext} />
17
24
  </slot>
18
- <slot />
25
+ <main class="container mx-auto">
26
+ <slot />
27
+ </main>
28
+ <img
29
+ src="/img/uploads/granolas-espalhadas.png"
30
+ width="477"
31
+ height="396"
32
+ fetchpriority="low"
33
+ class="fixed bg-transparent -bottom-70 -right-60 -z-10"
34
+ />
19
35
  </Base>
@@ -5,7 +5,6 @@ import type CmsContacts from '@@sf/types/cms-contacts';
5
5
  import type { PageContext } from '@@sf/ssr-context';
6
6
  import { i19buyOnWhatsApp } from '@@i18n';
7
7
  import { getImage } from '@@sf/ssr/image';
8
- import TopBar, { Props as TopBarProps } from '@@components/TopBar.vue';
9
8
  import TheHeader, { Props as TheHeaderProps } from '@@components/TheHeader.vue';
10
9
  import HeaderNav from '@@components/header/HeaderNav.vue';
11
10
  import HeaderButtons, { Props as HeaderButtonsProps } from '@@components/header/HeaderButtons.vue';
@@ -13,7 +12,6 @@ import HeaderButtons, { Props as HeaderButtonsProps } from '@@components/header/
13
12
  export interface Props {
14
13
  pageContext: PageContext;
15
14
  logoTransformOptions?: Parameters<typeof getImage>[0];
16
- topBarProps?: Partial<TopBarProps>;
17
15
  theHeaderProps?: Partial<TheHeaderProps>;
18
16
  headerButtonsProps?: Partial<HeaderButtonsProps>;
19
17
  }
@@ -25,7 +23,6 @@ const {
25
23
  cms,
26
24
  },
27
25
  logoTransformOptions,
28
- topBarProps,
29
26
  theHeaderProps,
30
27
  headerButtonsProps,
31
28
  } = Astro.props as Props;
@@ -68,7 +65,6 @@ if (contacts.whatsapp) {
68
65
  }
69
66
 
70
67
  declare global {
71
- var TopBarProps: TopBarProps;
72
68
  var TheHeaderProps: TheHeaderProps;
73
69
  var HeaderButtonsProps: HeaderButtonsProps;
74
70
  }
@@ -78,7 +74,6 @@ globalThis.TopBarProps = {
78
74
  hasPhoneLinks: header.contacts_stripe.phone_wpp,
79
75
  hasNetworkLinks: header.contacts_stripe.socials,
80
76
  contacts,
81
- ...topBarProps,
82
77
  };
83
78
  globalThis.TheHeaderProps = {
84
79
  logo: {
@@ -101,11 +96,8 @@ globalThis.HeaderButtonsProps = {
101
96
  ---
102
97
 
103
98
  <Fragment>
104
- <slot name="top-bar">
105
- <TopBar {...globalThis.TopBarProps} />
106
- </slot>
107
99
  <slot name="header">
108
- <TheHeader {...globalThis.TheHeaderProps}>
100
+ <TheHeader {...globalThis.TheHeaderProps} client:idle>
109
101
  <Fragment slot="nav">
110
102
  <HeaderNav />
111
103
  </Fragment>
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  import type { PageContext } from '@@sf/ssr-context';
3
3
  import api from '@cloudcommerce/api';
4
+ import { Image } from '@astrojs/image/components';
4
5
 
5
6
  export interface Props {
6
7
  pageContext: PageContext;
@@ -9,11 +10,17 @@ export interface Props {
9
10
  const products = (await api.get('products')).data.result;
10
11
  ---
11
12
 
12
- <main>
13
- <h1>Welcome to <span class="text-primary">Astro</span></h1>
14
- <ul role="list" class="mt-3 fs-20">
15
- {products.map((product) => <li>
16
- <a href={`/${product.slug}`}>{product.sku}</a>
17
- </li>)}
18
- </ul>
19
- </main>
13
+ <Image src="/img/uploads/fimdeano1920x736.jpg"
14
+ format={'webp'}
15
+ width={1920} height={736}
16
+ alt="Seu fim de ano na Tia Sônia. Cupons QUERO10, QUERO15, QUERO20."
17
+ />
18
+ <h1 class="font-brand">
19
+ Welcome to
20
+ <span class="text-secondary font-sans font-bold">FEITO NA BAHIA</span>
21
+ </h1>
22
+ <ul role="list" class="mt-3 fs-20">
23
+ {products.map((product) => <li>
24
+ <a href={`/${product.slug}`}>{product.sku}</a>
25
+ </li>)}
26
+ </ul>
@@ -1,2 +1,10 @@
1
+ process.env.STOREFRONT_BASE_DIR = __dirname;
2
+
3
+ globalThis.storefront_theme_options = {
4
+ generalIcons: 'tabler',
5
+ };
6
+
1
7
  // eslint-disable-next-line import/no-extraneous-dependencies
2
- module.exports = require('@cloudcommerce/storefront/tailwind.config.cjs');
8
+ const defaultConfig = require('@cloudcommerce/storefront/tailwind.config.cjs');
9
+
10
+ module.exports = defaultConfig;
@@ -1,4 +1,6 @@
1
1
  // eslint-disable-next-line import/no-extraneous-dependencies
2
2
  const { genUnoCSSConfig } = require('@cloudcommerce/storefront/uno.config');
3
3
 
4
- export default genUnoCSSConfig();
4
+ export default genUnoCSSConfig({
5
+ shoppingCartIcon: 'paper-bag',
6
+ });
@@ -23,6 +23,6 @@
23
23
  "url": "https://github.com/ecomplus/cloud-commerce/issues"
24
24
  },
25
25
  "dependencies": {
26
- "@cloudcommerce/cli": "^0.1.1"
26
+ "@cloudcommerce/cli": "^0.1.3"
27
27
  }
28
28
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "cloudcommerce",
3
3
  "type": "module",
4
- "version": "0.1.2",
4
+ "version": "0.1.4",
5
5
  "description": "Open fair-code headless commerce platform: API-first, microservices based, event driven and cloud native",
6
6
  "main": "packages/api/lib/index.js",
7
7
  "author": "E-Com Club Softwares para E-commerce <ti@e-com.club>",
@@ -20,9 +20,9 @@
20
20
  "@commitlint/config-conventional": "^17.3.0",
21
21
  "@commitlint/rules": "^17.3.0",
22
22
  "@types/node": "^18.11.17",
23
- "@typescript-eslint/eslint-plugin": "^5.46.1",
24
- "@typescript-eslint/parser": "^5.46.1",
25
- "esbuild": "^0.16.9",
23
+ "@typescript-eslint/eslint-plugin": "^5.47.0",
24
+ "@typescript-eslint/parser": "^5.47.0",
25
+ "esbuild": "^0.16.10",
26
26
  "eslint": "^8.30.0",
27
27
  "eslint-config-airbnb-base": "^15.0.0",
28
28
  "eslint-plugin-import": "^2.26.0",
@@ -34,10 +34,11 @@
34
34
  "typescript": "^4.9.4",
35
35
  "uglify-js": "^3.17.4",
36
36
  "vite": "^3.2.5",
37
- "vitest": "^0.26.0",
37
+ "vitest": "^0.26.2",
38
38
  "zx": "^7.1.1"
39
39
  },
40
40
  "scripts": {
41
+ "fix-install": "bash scripts/pre-install.sh && pnpm i --frozen-lockfile",
41
42
  "postinstall": "husky install && pnpm run -r prepare-monorepo",
42
43
  "new-pkg": "bash scripts/new-package.sh",
43
44
  "build": "turbo run build",
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@cloudcommerce/api",
3
3
  "type": "module",
4
- "version": "0.1.2",
4
+ "version": "0.1.4",
5
5
  "description": "E-Com Plus Cloud Commerce APIs client/adapter",
6
6
  "main": "lib/api.js",
7
7
  "types": "lib/api.d.ts",