@meeovi/layer-commerce 1.0.3 → 1.0.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 (58) hide show
  1. package/app/components/catalog/product/ProductAccordion/types.ts +3 -3
  2. package/app/components/catalog/product/ProductProperties/types.ts +3 -3
  3. package/app/components/catalog/product/ProductSlider/types.ts +5 -5
  4. package/app/components/catalog/product/RecommendedProducts/types.ts +3 -3
  5. package/app/components/catalog/product/bestsellers.vue +8 -20
  6. package/app/components/catalog/product/deals.vue +7 -22
  7. package/app/components/catalog/product/exclusives.vue +8 -10
  8. package/app/components/catalog/product/featuredproducts.vue +8 -20
  9. package/app/components/catalog/product/latestproducts.vue +8 -20
  10. package/app/components/catalog/product/productCard.vue +55 -21
  11. package/app/components/catalog/product/productDetails.vue +20 -14
  12. package/app/components/catalog/product/relatedproducts.vue +5 -20
  13. package/app/components/catalog/product/sizeOptions.vue +3 -8
  14. package/app/components/catalog/shops/relatedstores.vue +6 -21
  15. package/app/components/categories/chart/[id].vue +200 -0
  16. package/app/components/categories/chart/add-chart.vue +142 -0
  17. package/app/components/categories/chart/chart.vue +82 -0
  18. package/app/components/categories/chart/monthlyChart.vue +46 -0
  19. package/app/components/categories/chart/weeklyChart.vue +46 -0
  20. package/app/components/categories/chart/yearlyChart.vue +46 -0
  21. package/app/components/categories/charts.vue +118 -0
  22. package/app/components/categories/deals.vue +101 -0
  23. package/app/components/categories/eats.vue +49 -0
  24. package/app/components/categories/restaurants.vue +26 -0
  25. package/app/components/categories/station/[id].vue +72 -0
  26. package/app/components/categories/stations.vue +124 -0
  27. package/app/components/categories/time/time.vue +63 -0
  28. package/app/components/categories/travel.vue +75 -0
  29. package/app/components/categories/weather/weather.vue +44 -0
  30. package/app/components/content/pages/showcases.vue +1 -1
  31. package/app/components/marketing/promotions/giftcards.vue +20 -45
  32. package/app/components/marketing/promotions/subscriptions.vue +8 -21
  33. package/app/components/placeholders/Comments.vue +15 -0
  34. package/app/components/placeholders/CreateListBtn.vue +7 -0
  35. package/app/components/placeholders/Event.vue +9 -0
  36. package/app/components/placeholders/ListShowcases.vue +9 -0
  37. package/app/components/placeholders/Short.vue +9 -0
  38. package/app/components/placeholders/Space.vue +9 -0
  39. package/app/components/placeholders/Tag.vue +7 -0
  40. package/app/components/sales/CheckoutAddress/types.ts +12 -11
  41. package/app/components/sales/OrderSummary/types.ts +3 -3
  42. package/app/components/sales/incentives.vue +13 -37
  43. package/app/composables/cart/registry.ts +7 -0
  44. package/app/composables/index.ts +1 -0
  45. package/app/composables/products/registry.ts +7 -0
  46. package/app/composables/registry.ts +21 -0
  47. package/app/composables/useCatalog.ts +64 -0
  48. package/app/composables/useContent.ts +57 -0
  49. package/app/composables/useProducts/types.ts +15 -10
  50. package/app/pages/brand/[...slug].vue +1 -1
  51. package/app/pages/departments/[...slug].vue +385 -0
  52. package/app/pages/departments/category/[...slug].vue +135 -0
  53. package/app/pages/product/[...id].vue +3 -3
  54. package/app/pages/shop/[...slug].vue +12 -18
  55. package/app/pages/shops.vue +18 -25
  56. package/global.d.ts +14 -0
  57. package/package.json +2 -1
  58. package/tsconfig.json +10 -1
@@ -3,7 +3,7 @@
3
3
  <v-card elevation="0">
4
4
  <v-toolbar title="Shops on Meeovi" color="green"></v-toolbar>
5
5
  <v-tabs v-model="tab" bg-color="green" align-tabs="center">
6
- <v-tab v-if="menus?.active === 'Active'" v-for="(menu, index) in shopbar?.menus" :key="index">
6
+ <v-tab v-if="shopbar?.active === 'Active'" v-for="(menu, index) in shopbar?.menus" :key="index">
7
7
  <NuxtLink :to="menu?.url">{{ menu?.name }}</NuxtLink>
8
8
  </v-tab>
9
9
  </v-tabs>
@@ -14,8 +14,8 @@
14
14
  <section data-bs-version="5.1" class="clients1 cid-uHg1k6KLf8" id="clients1-ap">
15
15
  <div class="container">
16
16
  <div class="row justify-content-center">
17
- <div class="card col-12 col-md-6 col-lg-4" v-for=" (stores, index) in stores" :key="index">
18
- <store :store="stores" />
17
+ <div class="card col-12 col-md-6 col-lg-4" v-for="(shop, index) in stores" :key="index">
18
+ <store :store="shop" />
19
19
  </div>
20
20
  </div>
21
21
  </div>
@@ -26,8 +26,8 @@
26
26
  <section data-bs-version="5.1" class="clients1 cid-uHg1k6KLf8" id="clients1-ap">
27
27
  <div class="container">
28
28
  <div class="row justify-content-center">
29
- <div class="card col-12 col-md-6 col-lg-4" v-for=" (stores, index) in stores" :key="index">
30
- <store :store="stores" />
29
+ <div class="card col-12 col-md-6 col-lg-4" v-for="(shop, index) in stores" :key="index">
30
+ <store :store="shop" />
31
31
  </div>
32
32
  </div>
33
33
  </div>
@@ -38,8 +38,8 @@
38
38
  <section data-bs-version="5.1" class="clients1 cid-uHg1k6KLf8" id="clients1-ap">
39
39
  <div class="container">
40
40
  <div class="row justify-content-center">
41
- <div class="card col-12 col-md-6 col-lg-4" v-for=" (stores, index) in stores" :key="index">
42
- <store :store="stores" />
41
+ <div class="card col-12 col-md-6 col-lg-4" v-for="(shop, index) in stores" :key="index">
42
+ <store :store="shop" />
43
43
  </div>
44
44
  </div>
45
45
  </div>
@@ -51,30 +51,23 @@
51
51
  </div>
52
52
  </template>
53
53
 
54
- <script setup>
54
+ <script setup lang="ts">
55
+ import { ref } from 'vue'
56
+ import { useHead, useNuxtApp, useAsyncData } from '#imports'
55
57
  import store from '../components/catalog/shops/stores.vue'
56
58
 
57
59
  const tab = ref(null)
58
- const {
59
- $directus,
60
- $readItems,
61
- $readItem
62
- } = useNuxtApp()
60
+
61
+ import { useContentFallback } from '../composables/useContent'
62
+ const content = useContentFallback()
63
63
 
64
- const {
65
- data: stores
66
- } = await useAsyncData('stores', () => {
67
- return $directus.request($readItems('shops', {
68
- fields: ['*', {
69
- '*': ['*']
70
- }]
71
- }))
64
+ const { data: stores } = await useAsyncData('stores', async () => {
65
+ return await content.listShops({ fields: ['*', { '*': ['*'] }] })
72
66
  })
73
67
 
74
- const {
75
- data: shopbar
76
- } = await useAsyncData('shopbar', () => {
77
- return $directus.request($readItem('navigation', '55'))
68
+ const { data: shopbar } = await useAsyncData('shopbar', () => {
69
+ const nuxtApp = useNuxtApp() as any
70
+ return nuxtApp.$directus ? nuxtApp.$directus.request(nuxtApp.$readItem('navigation', '55')) : null
78
71
  })
79
72
 
80
73
  useHead({
package/global.d.ts ADDED
@@ -0,0 +1,14 @@
1
+ declare module '#imports' {
2
+ // Minimal shims for Nuxt auto-imports used in script-setup
3
+ export const useHead: any
4
+ export const useNuxtApp: any
5
+ export const useAsyncData: any
6
+ export const useState: any
7
+ export const useFetch: any
8
+ }
9
+
10
+ declare module '*.vue' {
11
+ import { DefineComponent } from 'vue'
12
+ const component: DefineComponent<{}, {}, any>
13
+ export default component
14
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meeovi/layer-commerce",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "Commerce Layer for the Alternate Framework",
5
5
  "keywords": [
6
6
  "commerce",
@@ -26,6 +26,7 @@
26
26
  "@meeovi/adapter-magento": "^1.0.2",
27
27
  "@meeovi/api": "^1.0.1",
28
28
  "@meeovi/core": "^1.0.1",
29
+ "@meeovi/layer-social": "^1.0.4",
29
30
  "@meeovi/sdk": "^1.0.2",
30
31
  "@meeovi/types": "^1.0.0",
31
32
  "@polar-sh/better-auth": "^1.6.4",
package/tsconfig.json CHANGED
@@ -11,5 +11,14 @@
11
11
  "skipLibCheck": true,
12
12
  "noEmitOnError": false
13
13
  },
14
- "include": ["src", "index.ts", "app/types", "app/utils/client.ts", "app/utils/normalizers"]
14
+ "include": [
15
+ "src",
16
+ "index.ts",
17
+ "app",
18
+ "app/**/*.vue",
19
+ "app/types",
20
+ "global.d.ts",
21
+ "app/utils/client.ts",
22
+ "app/utils/normalizers"
23
+ ]
15
24
  }