@ozdao/prometheus-framework 0.1.67 → 0.1.69

Sign up to get free protection for your applications and to get access to all the features.
Files changed (164) hide show
  1. package/dist/BackofficeGallery-59a591ab.js +1 -0
  2. package/dist/BackofficeGallery-be6f69a9.mjs +307 -0
  3. package/dist/BackofficeReports-06166952.js +1 -0
  4. package/dist/BackofficeReports-50fd799c.mjs +44 -0
  5. package/dist/BlockTags-00325fa0.mjs +853 -0
  6. package/dist/BlockTags-58f95c8a.js +1 -0
  7. package/dist/ButtonToggleMembership-84d0e018.mjs +90 -0
  8. package/dist/ButtonToggleMembership-b905812f.js +1 -0
  9. package/dist/CardBlogpost-1b81b54e.mjs +246 -0
  10. package/dist/CardBlogpost-7107e04a.js +1 -0
  11. package/dist/CardOrganization-49ab5190.mjs +234 -0
  12. package/dist/CardOrganization-e6ac27f1.js +1 -0
  13. package/dist/CardProduct-4c0cb9a1.js +1 -0
  14. package/dist/CardProduct-ea0e1f84.mjs +192 -0
  15. package/dist/Chips-817cf959.js +1 -0
  16. package/dist/Chips-8c836ba6.mjs +213 -0
  17. package/dist/Community-8c4e011b.js +1 -0
  18. package/dist/Community-bd6f0cbb.mjs +131 -0
  19. package/dist/Dashboard-73b50724.js +1 -0
  20. package/dist/Dashboard-bc81b5f6.mjs +151 -0
  21. package/dist/Dropdown-60e3dc6c.js +1 -0
  22. package/dist/Dropdown-d1c81d45.mjs +169 -0
  23. package/dist/EditOrder-2b746caf.mjs +221 -0
  24. package/dist/EditOrder-e632f0cc.js +1 -0
  25. package/dist/Events-999cc8ed.js +1 -0
  26. package/dist/Events-ad8bbf27.mjs +134 -0
  27. package/dist/Feed-35e13c22.mjs +156 -0
  28. package/dist/Feed-53d96b18.mjs +361 -0
  29. package/dist/Feed-694a2fad.js +1 -0
  30. package/dist/Feed-ac4bb6ea.js +1 -0
  31. package/dist/Feed-d1d01771.js +1 -0
  32. package/dist/Feed-f7c04014.mjs +124 -0
  33. package/dist/Image-61cfd52d.js +9 -0
  34. package/dist/Image-e8be4acc.mjs +480 -0
  35. package/dist/LeftoverAdd-a268a95c.js +1 -0
  36. package/dist/LeftoverAdd-e4d93760.mjs +229 -0
  37. package/dist/Leftovers-6976802d.mjs +135 -0
  38. package/dist/Leftovers-d8f1d152.js +1 -0
  39. package/dist/Members-aeb2bca1.mjs +109 -0
  40. package/dist/Members-b9664e83.js +1 -0
  41. package/dist/Menu-93d34d9f.js +1 -0
  42. package/dist/Menu-eaf6b44c.mjs +13 -0
  43. package/dist/MenuItem-4a5881bd.mjs +85 -0
  44. package/dist/MenuItem-f35cad93.js +1 -0
  45. package/dist/Orders-8bc8963c.js +1 -0
  46. package/dist/Orders-eb262d8c.mjs +75 -0
  47. package/dist/Organizations-9926aa51.mjs +72 -0
  48. package/dist/Organizations-c653d814.js +1 -0
  49. package/dist/Payments-98328000.js +1 -0
  50. package/dist/Payments-a9066cdf.mjs +11 -0
  51. package/dist/Popup-0d8e1392.mjs +96 -0
  52. package/dist/Popup-eb11fa82.js +1 -0
  53. package/dist/Product-15043af7.mjs +651 -0
  54. package/dist/Product-82c022a4.js +7 -0
  55. package/dist/ProductEdit-05da9866.mjs +258 -0
  56. package/dist/ProductEdit-2f075296.js +1 -0
  57. package/dist/ProductsBackoffice-8462f626.js +1 -0
  58. package/dist/ProductsBackoffice-8d0f0ee8.mjs +85 -0
  59. package/dist/ProfileBlogposts-43855cb9.js +1 -0
  60. package/dist/ProfileBlogposts-f32170a3.mjs +78 -0
  61. package/dist/ProfileEvents-54be2d43.mjs +69 -0
  62. package/dist/ProfileEvents-ab69e27e.js +1 -0
  63. package/dist/ProfileOrganizations-0787cf34.mjs +72 -0
  64. package/dist/ProfileOrganizations-eb62dde4.js +1 -0
  65. package/dist/Publics-8e726d20.mjs +45 -0
  66. package/dist/Publics-ae589bf1.js +1 -0
  67. package/dist/Select-95f4701a.js +1 -0
  68. package/dist/Select-dab17282.mjs +80 -0
  69. package/dist/Select.vue_vue_type_style_index_0_scoped_dfe03dc2_lang-0ea8fbf8.js +1 -0
  70. package/dist/Select.vue_vue_type_style_index_0_scoped_dfe03dc2_lang-4ed993c7.mjs +1 -0
  71. package/dist/Socials-43293869.js +1 -0
  72. package/dist/Socials-8193477c.mjs +189 -0
  73. package/dist/UploadImage-0e8e4278.mjs +83 -0
  74. package/dist/UploadImage-8c71bda6.js +1 -0
  75. package/dist/UploadImageMultiple-c34a6c6f.mjs +58 -0
  76. package/dist/UploadImageMultiple-d1316df5.js +1 -0
  77. package/dist/Wallet-727195d9.mjs +21700 -0
  78. package/dist/Wallet-f4dda407.js +10 -0
  79. package/dist/auth-04684a60.js +7 -0
  80. package/dist/auth-7e39361f.mjs +633 -0
  81. package/dist/auth.client.cjs +1 -1
  82. package/dist/auth.client.js +5 -5
  83. package/dist/auth.server.js +1 -1
  84. package/dist/auth.server.mjs +1 -1
  85. package/dist/auth.validation-d614130d.js +1 -0
  86. package/dist/auth.validation-f4bf1deb.mjs +24 -0
  87. package/dist/axios-33aeb810.mjs +1435 -0
  88. package/dist/axios-ceccf20e.js +5 -0
  89. package/dist/backoffice.client.cjs +1 -1
  90. package/dist/backoffice.client.js +20 -20
  91. package/dist/categories-7e17a7eb.js +1 -0
  92. package/dist/categories-b7f9e8c0.mjs +122 -0
  93. package/dist/community.client.cjs +1 -1
  94. package/dist/community.client.js +209 -202
  95. package/dist/components/Upload/Upload.vue.d.ts.map +1 -1
  96. package/dist/events.client.cjs +2 -2
  97. package/dist/events.client.js +24 -27
  98. package/dist/landing.client.cjs +1 -1
  99. package/dist/landing.client.js +64 -40
  100. package/dist/leftovers-86e7d438.mjs +67 -0
  101. package/dist/leftovers-c9f70579.js +1 -0
  102. package/dist/legal.client.cjs +1 -1
  103. package/dist/legal.client.js +6 -7
  104. package/dist/main.css +1 -1
  105. package/dist/memberships-559590ad.mjs +68 -0
  106. package/dist/memberships-58af22e0.js +1 -0
  107. package/dist/modules/constructor/components/elements/H2.vue.d.ts +1 -1
  108. package/dist/modules/constructor/components/elements/Textarea.vue.d.ts +1 -1
  109. package/dist/modules/products/components/sections/EditProductInfo.vue.d.ts +1 -5
  110. package/dist/orders-1325c51b.js +1 -0
  111. package/dist/orders-c7cbe706.mjs +85 -0
  112. package/dist/organizations-71777b32.js +1 -0
  113. package/dist/organizations-93f7b610.mjs +122 -0
  114. package/dist/organizations.client-6ca27fb3.js +3 -0
  115. package/dist/organizations.client-bd63a7b2.mjs +2997 -0
  116. package/dist/organizations.client.cjs +1 -1
  117. package/dist/organizations.client.js +56 -61
  118. package/dist/products-61d83d74.js +1 -0
  119. package/dist/products-7f1e5a75.mjs +108 -0
  120. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.cjs +1 -1
  121. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.js +67 -65
  122. package/dist/prometheus-framework.cjs.js +21 -21
  123. package/dist/prometheus-framework.es.js +682 -690
  124. package/dist/reports-a67b4fb4.js +1 -0
  125. package/dist/reports-c579b02a.mjs +91 -0
  126. package/dist/reports.client.cjs +1 -1
  127. package/dist/reports.client.js +2 -2
  128. package/dist/states.validation-3b4604bc.mjs +13 -0
  129. package/dist/states.validation-9b43a097.js +1 -0
  130. package/dist/style.css +1 -1
  131. package/dist/users.client.cjs +1 -1
  132. package/dist/users.client.js +279 -208
  133. package/package.json +30 -35
  134. package/src/components/Button/Button.vue +1 -1
  135. package/src/components/Sidebar/Sidebar.vue +10 -8
  136. package/src/components/Upload/Upload.vue +8 -28
  137. package/src/modules/auth/components/pages/SignIn.vue +2 -2
  138. package/src/modules/auth/controllers/auth.controller.js +1 -1
  139. package/src/modules/auth/store/auth.js +21 -24
  140. package/src/modules/backoffice/components/admin/ProductEdit.vue +2 -0
  141. package/src/modules/constructor/components/sections/Constructor.vue +7 -54
  142. package/src/modules/gallery/components/pages/Gallery.vue +7 -1
  143. package/src/modules/gallery/components/sections/GalleryWithCategories.vue +24 -8
  144. package/src/modules/gallery/gallery.client.js +5 -1
  145. package/src/modules/marketplace/components/layouts/Marketplace.vue +1 -0
  146. package/src/modules/organizations/components/pages/Organization.vue +2 -2
  147. package/src/modules/payments/components/pages/Payments.vue +4 -3
  148. package/src/modules/products/components/blocks/CardLeftover.vue +0 -1
  149. package/src/modules/products/components/blocks/CardProduct.vue +15 -1
  150. package/src/modules/products/components/sections/EditProductInfo.vue +16 -14
  151. package/src/modules/products/components/sections/FilterProducts.vue +0 -2
  152. package/src/modules/products/components/sections/SectionProduct.vue +1 -0
  153. package/src/modules/products/components/sections/SortProducts.vue +2 -0
  154. package/src/modules/products/store/categories.js +9 -9
  155. package/src/modules/products/store/leftovers.js +6 -9
  156. package/src/modules/products/store/products.js +2 -0
  157. package/src/modules/users/components/pages/Profile.vue +3 -5
  158. package/src/modules/wallet/components/pages/Wallet.vue +1 -1
  159. package/src/styles/components/button.scss +253 -0
  160. package/src/styles/theme.scss +1 -0
  161. package/src/modules/constructor/components/elements/Audio.vue +0 -82
  162. package/src/modules/constructor/components/elements/Embed.vue +0 -85
  163. package/src/modules/globals/mixins/mixins.js +0 -52
  164. package/src/modules/globals/router/routerGuards.js +0 -28
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ozdao/prometheus-framework",
3
- "version": "0.1.67",
3
+ "version": "0.1.69",
4
4
  "description": "Web3 Framework focused on user experience and ease of development.",
5
5
  "author": "OZ DAO <hello@ozdao.dev>",
6
6
  "license": "GPL-3.0-or-later",
@@ -38,64 +38,64 @@
38
38
  "import": "./dist/style.css"
39
39
  },
40
40
  "./modules/auth/client": {
41
- "import": "./dist/prometheus-framework/src/modules/auth/auth.client.js",
42
- "require": "./dist/prometheus-framework/src/modules/auth/auth.client.cjs"
41
+ "import": "./dist/auth.client.js",
42
+ "require": "./dist/auth.client.cjs"
43
43
  },
44
44
  "./modules/auth/server": {
45
45
  "import": "./dist/auth.server.mjs",
46
46
  "require": "./dist/auth.server.js"
47
47
  },
48
48
  "./modules/community/client": {
49
- "import": "./dist/prometheus-framework/src/modules/community/community.client.js",
50
- "require": "./dist/prometheus-framework/src/modules/community/community.client.cjs"
49
+ "import": "./dist/community.client.js",
50
+ "require": "./dist/community.client.cjs"
51
51
  },
52
52
  "./modules/community/server": {
53
53
  "import": "./dist/community.server.mjs",
54
54
  "require": "./dist/community.server.js"
55
55
  },
56
56
  "./modules/globals/client": {
57
- "import": "./dist/prometheus-framework/src/modules/globals/globals.client.js",
58
- "require": "./dist/prometheus-framework/src/modules/globals/globals.client.cjs"
57
+ "import": "./dist/globals.client.js",
58
+ "require": "./dist/globals.client.cjs"
59
59
  },
60
60
  "./modules/globals/server": {
61
61
  "import": "./dist/globals.server.mjs",
62
62
  "require": "./dist/globals.server.js"
63
63
  },
64
64
  "./modules/orders/client": {
65
- "import": "./dist/prometheus-framework/src/modules/orders/orders.client.js",
66
- "require": "./dist/prometheus-framework/src/modules/orders/orders.client.cjs"
65
+ "import": "./dist/orders.client.js",
66
+ "require": "./dist/orders.client.cjs"
67
67
  },
68
68
  "./modules/orders/server": {
69
69
  "import": "./dist/orders.server.mjs",
70
70
  "require": "./dist/orders.server.js"
71
71
  },
72
72
  "./modules/organizations/client": {
73
- "import": "./dist/prometheus-framework/src/modules/organizations/organizations.client.js",
74
- "require": "./dist/prometheus-framework/src/modules/organizations/organizations.client.cjs"
73
+ "import": "./dist/organizations.client.js",
74
+ "require": "./dist/organizations.client.cjs"
75
75
  },
76
76
  "./modules/organizations/server": {
77
77
  "import": "./dist/organizations.server.mjs",
78
78
  "require": "./dist/organizations.server.js"
79
79
  },
80
80
  "./modules/products/client": {
81
- "import": "./dist/prometheus-framework/src/modules/products/products.client.js",
82
- "require": "./dist/prometheus-framework/src/modules/products/products.client.cjs"
81
+ "import": "./dist/products.client.js",
82
+ "require": "./dist/products.client.cjs"
83
83
  },
84
84
  "./modules/products/server": {
85
85
  "import": "./dist/products.server.mjs",
86
86
  "require": "./dist/products.server.js"
87
87
  },
88
88
  "./modules/spots/client": {
89
- "import": "./dist/prometheus-framework/src/modules/spots/spots.client.js",
90
- "require": "./dist/prometheus-framework/src/modules/spots/spots.client.cjs"
89
+ "import": "./dist/spots.client.js",
90
+ "require": "./dist/spots.client.cjs"
91
91
  },
92
92
  "./modules/spots/server": {
93
93
  "import": "./dist/spots.server.mjs",
94
94
  "require": "./dist/spots.server.js"
95
95
  },
96
96
  "./modules/users/client": {
97
- "import": "./dist/prometheus-framework/src/modules/users/users.client.js",
98
- "require": "./dist/prometheus-framework/src/modules/users/users.client.cjs"
97
+ "import": "./dist/users.client.js",
98
+ "require": "./dist/users.client.cjs"
99
99
  },
100
100
  "./modules/users/server": {
101
101
  "import": "./dist/users.server.mjs",
@@ -106,40 +106,36 @@
106
106
  "require": "./dist/events.server.js"
107
107
  },
108
108
  "./modules/events/client": {
109
- "import": "./dist/prometheus-framework/src/modules/events/events.client.js",
110
- "require": "./dist/prometheus-framework/src/modules/events/events.client.cjs"
109
+ "import": "./dist/events.client.js",
110
+ "require": "./dist/events.client.cjs"
111
111
  },
112
112
  "./modules/files/client": {
113
- "import": "./dist/prometheus-framework/src/modules/files/files.client.js",
114
- "require": "./dist/prometheus-framework/src/modules/files/files.client.cjs"
113
+ "import": "./dist/files.client.js",
114
+ "require": "./dist/files.client.cjs"
115
115
  },
116
116
  "./modules/files/server": {
117
117
  "import": "./dist/files.server.mjs",
118
118
  "require": "./dist/files.server.js"
119
119
  },
120
120
  "./modules/landing/client": {
121
- "import": "./dist/prometheus-framework/src/modules/landing/landing.client.js",
122
- "require": "./dist/prometheus-framework/src/modules/landing/landing.client.cjs"
123
- },
124
- "./modules/gallery/client": {
125
- "import": "./dist/prometheus-framework/src/modules/gallery/gallery.client.js",
126
- "require": "./dist/prometheus-framework/src/modules/gallery/gallery.client.cjs"
121
+ "import": "./dist/landing.client.js",
122
+ "require": "./dist/landing.client.cjs"
127
123
  },
128
124
  "./modules/gallery/server": {
129
125
  "import": "./dist/gallery.server.mjs",
130
126
  "require": "./dist/gallery.server.js"
131
127
  },
132
128
  "./modules/backoffice/client": {
133
- "import": "./dist/prometheus-framework/src/modules/backoffice/backoffice.client.js",
134
- "require": "./dist/prometheus-framework/src/modules/backoffice/backoffice.client.cjs"
129
+ "import": "./dist/backoffice.client.js",
130
+ "require": "./dist/backoffice.client.cjs"
135
131
  },
136
132
  "./modules/legal/client": {
137
- "import": "./dist/prometheus-framework/src/modules/legal/legal.client.js",
138
- "require": "./dist/prometheus-framework/src/modules/legal/legal.client.cjs"
133
+ "import": "./dist/legal.client.js",
134
+ "require": "./dist/legal.client.cjs"
139
135
  },
140
136
  "./modules/reports/client": {
141
- "import": "./dist/prometheus-framework/src/modules/reports/reports.client.js",
142
- "require": "./dist/prometheus-framework/src/modules/reports/reports.client.cjs"
137
+ "import": "./dist/reports.client.js",
138
+ "require": "./dist/reports.client.cjs"
143
139
  },
144
140
  "./modules/reports/server": {
145
141
  "import": "./dist/reports.server.mjs",
@@ -175,8 +171,7 @@
175
171
  "nodemailer": "^6.9.4",
176
172
  "openai": "^4.7.1",
177
173
  "uuidv4": "^6.2.13",
178
- "vue": "^3.2.25",
179
- "vue-i18n": "^9.7.0"
174
+ "vue": "^3.2.25"
180
175
  },
181
176
  "devDependencies": {
182
177
  "@babel/preset-flow": "^7.22.15",
@@ -142,7 +142,7 @@
142
142
 
143
143
  opacity: 1;
144
144
 
145
- // color: rgba(var(--white), 1);;
145
+ color: rgba(var(--white), 1);;
146
146
 
147
147
  cursor: pointer;
148
148
  }
@@ -1,18 +1,13 @@
1
1
  <template>
2
- <div
3
- :class="['sidebar t-black bg-grey', stateSidebar ? 'open' : '']"
4
- >
5
- <div
6
- class="sidebar-content"
7
- >
2
+ <div :class="['sidebar t-black bg-grey', stateSidebar ? 'open' : '']">
3
+ <div class="sidebar-content">
8
4
  <slot></slot>
9
5
  </div>
10
6
  </div>
11
7
  </template>
12
8
 
13
9
  <script setup>
14
- import { ref } from 'vue';
15
-
10
+ import { ref, } from 'vue';
16
11
  import { useRoute, useRouter } from 'vue-router'
17
12
 
18
13
  const router = useRouter()
@@ -21,6 +16,7 @@ const route = useRoute()
21
16
  const isOpen = ref(false);
22
17
 
23
18
  const props = defineProps(['stateSidebar'])
19
+
24
20
  </script>
25
21
 
26
22
  <style scoped>
@@ -35,6 +31,12 @@ const props = defineProps(['stateSidebar'])
35
31
  z-index: 1000;
36
32
  }
37
33
 
34
+ .active {
35
+
36
+ }
37
+
38
+
39
+
38
40
  .sidebar.open {
39
41
  left: 0;
40
42
  }
@@ -1,7 +1,5 @@
1
1
  <template>
2
2
  <div :class="[$attrs.class, { 'bg-fourth-nano': validation }]" class="flex-center flex-nowrap flex">
3
- {{fileURL}}
4
-
5
3
  <!-- Label -->
6
4
  <div v-if="label" class="t-transp mn-r-small">
7
5
  <span>{{label}}</span>
@@ -31,7 +29,6 @@
31
29
 
32
30
  <script setup>
33
31
  import { ref, computed,} from 'vue'
34
- import axios from 'axios';
35
32
 
36
33
  const emit = defineEmits(['update:field', 'focus', 'blur', 'file-change']);
37
34
 
@@ -46,33 +43,16 @@ const props = defineProps({
46
43
  }
47
44
  });
48
45
 
49
- const fileURL = ref(null);
50
- const fileInput = ref(null);
51
-
52
46
  // Handles file change event
53
-
54
- async function onFileChange(e) {
55
-
56
- let file = e.target.files[0];
57
- let formData = new FormData();
58
-
59
- formData.append("file", file);
60
-
61
- try {
62
- const $axios = axios.create({baseURL: process.env.API_URL, withCredentials: true})
63
-
64
- let response = await $axios.post(`/api/upload/file?folderName=${encodeURIComponent(props.uploadPath)}`, formData, {
65
- headers: {
66
- "Content-Type": "multipart/form-data"
67
- }
68
- });
69
-
70
- fileURL.value = response.data.filepath;
71
- emit('file-change', fileURL.value);
72
- } catch (error) {
73
- console.error(error);
47
+ const onFileChange = (event) => {
48
+ if (props.multiple) {
49
+ const files = Array.from(event.target.files);
50
+ emit('file-change', { files });
51
+ } else {
52
+ const file = event.target.files[0];
53
+ emit('file-change', { file });
74
54
  }
75
- }
55
+ };
76
56
  </script>
77
57
 
78
58
  <style lang="scss" scoped>
@@ -1,4 +1,4 @@
1
- <!-- <i18n>
1
+ <i18n>
2
2
  {
3
3
  "en": {
4
4
  "title": "Welcome to The Commune",
@@ -31,7 +31,7 @@
31
31
  "soon": "СКОРО"
32
32
  }
33
33
  }
34
- </i18n> -->
34
+ </i18n>
35
35
 
36
36
  <template>
37
37
  <section class="">
@@ -41,7 +41,7 @@ const controllerFactory = (db) => {
41
41
 
42
42
  let user = await User.findOne(query).populate('roles').exec();
43
43
 
44
- if ((type === 'email' || type === 'phone')) {
44
+ if ((type === 'email' || type === 'phone') && req.body.password) {
45
45
 
46
46
  const passwordIsValid = bcrypt.compareSync(req.body.password, user.password);
47
47
 
@@ -27,27 +27,27 @@
27
27
  },
28
28
  });
29
29
 
30
- // async function initialize() {
31
- // const userCookie = await getCookie('user');
30
+ async function initialize() {
31
+ const userCookie = await getCookie('user');
32
32
 
33
- // if (userCookie) {
34
- // const {_id, email, phone, roles, accessToken} = userCookie;
33
+ if (userCookie) {
34
+ const {_id, email, phone, roles, accessToken} = userCookie;
35
35
 
36
- // Object.assign(state.user, {_id, email, phone});
37
- // Object.assign(state.access, {token: accessToken, roles, status: !!accessToken});
36
+ Object.assign(state.user, {_id, email, phone});
37
+ Object.assign(state.access, {token: accessToken, roles, status: !!accessToken});
38
38
 
39
- // $axios.interceptors.request.use((config) => {
40
- // if (accessToken) {
41
- // config.headers['x-access-token'] = accessToken;
42
- // }
43
- // return config;
44
- // }, (error) => {
45
- // return Promise.reject(error);
46
- // });
47
- // }
48
- // }
39
+ $axios.interceptors.request.use((config) => {
40
+ if (accessToken) {
41
+ config.headers['x-access-token'] = accessToken;
42
+ }
43
+ return config;
44
+ }, (error) => {
45
+ return Promise.reject(error);
46
+ });
47
+ }
48
+ }
49
49
 
50
- // initialize();
50
+ initialize();
51
51
 
52
52
  const actions = {
53
53
  async login (user, type) {
@@ -214,13 +214,10 @@
214
214
 
215
215
  function getCookie(name) {
216
216
  if (process.env.MOBILE_APP) {
217
- // return CapacitorCookies.getCookie({
218
- // url: process.env.API_URL,
219
- // key: name
220
- // })
221
- // .then(response => JSON.parse(response.value));
222
- const cookie = Cookies.get(name);
223
- return cookie ? JSON.parse(cookie) : null;
217
+ return CapacitorCookies.getCookie({
218
+ url: process.env.API_URL,
219
+ key: name
220
+ }).then(response => JSON.parse(response.value));
224
221
  } else {
225
222
  // Для веб-версии
226
223
  const cookie = Cookies.get(name);
@@ -61,6 +61,7 @@
61
61
  <script setup>
62
62
  // Import libs
63
63
  import { reactive, computed, onMounted, toRefs } from 'vue'
64
+ import { useStore } from 'vuex'
64
65
  import { useRoute, useRouter } from 'vue-router'
65
66
  // Import components
66
67
  import EditProductInfo from '@/components/sections/product/EditProductInfo.vue';
@@ -70,6 +71,7 @@
70
71
  import EditModifications from '@/components/sections/product/EditModifications.vue';
71
72
 
72
73
  // Accessing router and store
74
+ const store = useStore()
73
75
  const route = useRoute()
74
76
  const router = useRouter()
75
77
 
@@ -36,60 +36,17 @@ a<template>
36
36
  <transition name="fade">
37
37
  <div
38
38
  v-if="showControls === index"
39
- class="pos-absolute z-index-4 i-semi"
40
- style="right: calc(100% + 0.5rem); top: calc(50% - 1.125rem);"
39
+ class="pos-absolute pos-r-100 pos-t-0 z-index-4 i-semi"
41
40
  @mousedown.prevent="startDragging = true"
42
41
  >
43
- <button
44
- @click="showMenu = !showMenu"
45
- class="mn-small cursor-pointer w-100 i-semi bg-white radius-thin"
46
- >
47
- {{ block.content ? '...' : '+' }}
48
- </button>
49
-
50
- <div
51
- v-if="showMenu"
52
- class="z-index-5 radius-thin pd-thin bg-white w-max mn-small flex-nowrap flex-column flex"
53
- >
54
- <span
55
- @click="handleDeleteBlock(block)"
56
- class="mn-thin w-max t-red bg-white button-small button"
57
- >
58
- Remove
59
- </span>
60
- <span
61
- @click="handleAddBlock('ImageUpload', '', index)"
62
- class="mn-thin w-max t-black bg-white button-small button"
63
- >
64
- Add Image
65
- </span>
66
- <span
67
- @click="handleAddBlock('H2', '', index)"
68
- class="w-max button-small t-black bg-white button"
69
- >
70
- Add Title
71
- </span>
72
- <span
73
- @click="handleAddBlock('Embed', '', index)"
74
- class="w-max button-small t-black bg-white button"
75
- >
76
- Add Embed
77
- </span>
78
- <!-- <span
79
- @click="handleAddBlock('Audio', '', index)"
80
- class="w-max button-small t-black bg-white button"
81
- >
82
- Add Audio
83
- </span> -->
84
-
42
+ <button @click="showMenu = !showMenu" class="mn-small w-100 i-semi bg-white radius-thin">{{ block.content ? '...' : '+' }}</button>
43
+ <div v-if="showMenu" class="z-index-5 radius-thin mn-small relative left-0 mt-2 w-max bg-white shadow-lg rounded">
44
+ <button @click="handleDeleteBlock(block)" class="block w-max text-left px-4 py-2 hover:bg-gray-200">Remove</button>
45
+ <button @click="handleAddBlock('ImageUpload', '', index)" class="block w-max text-left px-4 py-2 hover:bg-gray-200">Add Image</button>
46
+ <button @click="handleAddBlock('H2', '', index)" class="block w-max text-left px-4 py-2 hover:bg-gray-200">Add Title</button>
85
47
  </div>
86
-
87
-
88
48
  </div>
89
49
  </transition>
90
-
91
-
92
-
93
50
  </div>
94
51
  </VueDraggableNext>
95
52
  </section>
@@ -102,8 +59,6 @@ import H2 from '../elements/H2.vue';
102
59
  import Caption from '../elements/Caption.vue';
103
60
  import Bullets from '../elements/Bullets.vue';
104
61
  import ImageUpload from '../elements/ImageUpload.vue';
105
- import Embed from '../elements/Embed.vue';
106
- import Audio from '../elements/Audio.vue';
107
62
 
108
63
  import { ref, watchEffect, computed, emit } from 'vue';
109
64
  import { VueDraggableNext } from 'vue-draggable-next';
@@ -121,9 +76,7 @@ const ComponentMap = {
121
76
  'H2': H2,
122
77
  'Bullets': Bullets,
123
78
  'Caption': Caption,
124
- 'ImageUpload': ImageUpload,
125
- 'Embed': Embed,
126
- 'Audio': Audio
79
+ 'ImageUpload': ImageUpload
127
80
  };
128
81
 
129
82
  function handleAddBlock(type = 'Textarea', content = '', index, data) {
@@ -9,7 +9,13 @@
9
9
  </template>
10
10
 
11
11
  <script setup>
12
- import Title from '@pf/src/modules/globals/components/sections/Title.vue';
12
+ /////////////////////////////
13
+ // COMPONENT DEPENDENCIES
14
+ /////////////////////////////
15
+ import { onMounted } from 'vue'
16
+ import { gsap } from "gsap/dist/gsap";
17
+ import { ScrollTrigger } from "gsap/dist/ScrollTrigger";
13
18
 
19
+ import Title from '@pf/src/modules/globals/components/sections/Title.vue';
14
20
  import GalleryWithCategories from '@pf/src/modules/gallery/components/sections/GalleryWithCategories.vue';
15
21
  </script>
@@ -16,6 +16,7 @@
16
16
  </div>
17
17
 
18
18
  <div ref="grid" class="pd-medium cols-4 gap-thin">
19
+ <!-- :class="['grid-item pd-small', item.size.value, ...item.categories]" -->
19
20
  <div
20
21
  v-for="(item, index) in filteredGallery"
21
22
  :key="item.id"
@@ -29,6 +30,26 @@
29
30
  class="w-100 h-100 o-hidden radius-medium object-fit-cover"
30
31
  @click="openModal(item.image)"
31
32
  />
33
+ <!-- <div class="pd-small radius-small bg-white" v-else>
34
+ <img :src="'/photos/' + item.cover" class="w-100 radius-small mn-small h-10r object-fit-cover " @click="openModal(item)" />
35
+
36
+ <p class="t-black p-small mn-small">
37
+ <span class="uppercase t-transp ">Size</span>
38
+ <br>
39
+ <span class="pd-2px radius-big d-inline-block bg-grey">{{item.size.name}}</span>
40
+ </p>
41
+
42
+ <p class="t-black p-small mn-small uppe">
43
+ <span class="uppercase t-transp">Categories</span>
44
+ <br>
45
+ <span class="pd-2px radius-big d-inline-block bg-grey t-semi" v-for="category in item.categories">{{category}}</span>
46
+ </p>
47
+
48
+ <div class="flex-nowrap flex">
49
+ <button class="mn-r-thin button-small w-100 button" @click="editPhoto(item)">Edit</button>
50
+ <button class="button-small w-100 button" @click="deletePhoto(item._id)">Delete</button>
51
+ </div>
52
+ </div> -->
32
53
  </transition>
33
54
  </div>
34
55
 
@@ -49,7 +70,6 @@
49
70
  </transition>
50
71
 
51
72
  <transition name="modal">
52
-
53
73
  <div v-if="selectedImage.image !== false && modal === 'edit-modal'" class="flex-v-center flex m modal pd-big">
54
74
  <div class="modal-content radius-small pd-medium bg-white">
55
75
  <span class="close" @click="closeModal">&times;</span>
@@ -109,15 +129,11 @@
109
129
 
110
130
  <script setup>
111
131
  import { ref, onMounted, reactive, computed } from 'vue'
112
- import { useRoute } from 'vue-router'
113
-
114
- import Field from '@pf/src/components/Field/Field.vue'
115
- import Button from '@pf/src/components/Button/Button.vue'
116
- import Select from '@pf/src/components/Select/Select.vue'
117
- import Upload from '@pf/src/components/Upload/Upload.vue'
118
-
132
+ import { Button, Field, Select, Upload } from '@ozdao/prometheus-framework'
119
133
  import { state, actions } from '@pf/src/modules/gallery/store/gallery';
120
134
 
135
+ import { useRoute } from 'vue-router'
136
+
121
137
  const route = useRoute()
122
138
 
123
139
  const isEditablePath = false
@@ -1,10 +1,14 @@
1
- import * as galleryStore from './store/gallery.js';
1
+ import * as galleryStore from './store/gallery.store.js';
2
2
 
3
3
  // Importing Vue Router routes from the router directory
4
4
  import galleryRouter from './router/gallery.router.js';
5
5
 
6
+ import galleryPage from './components/pages/Gallery.vue'
7
+
6
8
  // Exporting components, store modules, and routes
7
9
  export {
8
10
  galleryStore,
9
11
  galleryRouter,
12
+ filesStore,
13
+ filesRoutes
10
14
  };
@@ -2,6 +2,7 @@
2
2
  <div class="min-h-100vh pd-thin">
3
3
 
4
4
  <div class=" br-solid br-1px br-grey bg-grey radius-big">
5
+ <Breadcrumbs class=" br-b br-solid br-black-transp pd-medium"/>
5
6
 
6
7
  <header class=" pd-medium mn-r-auto flex-v-center t-left flex-nowrap flex">
7
8
  <h2 class="t-left">
@@ -49,9 +49,9 @@
49
49
  :tabs="[
50
50
 
51
51
  { name: 'Community', value: 'community' },
52
- // { name: 'Products', value: 'products' },
52
+ { name: 'Products', value: 'products' },
53
53
  { name: 'Events', value: 'events' },
54
- // { name: 'Spots', value: 'spots' }
54
+ { name: 'Spots', value: 'spots' }
55
55
  ]"
56
56
  class="mn-small o-hidden h5 radius-big bg-grey"
57
57
  />
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <!-- Toolbar -->
3
- <section class="br-bot-dark bg-white pd-big">
3
+ <!-- <section class="br-bot-dark bg-white pd-big">
4
4
  <header class="flex-nojustify flex-bottom flex-nowrap flex">
5
5
  <h1 class="mn-r-small">Заказы</h1>
6
6
 
@@ -54,7 +54,7 @@
54
54
 
55
55
  </p>
56
56
  </div>
57
- </section>
57
+ </section> -->
58
58
  </template>
59
59
 
60
60
 
@@ -65,8 +65,9 @@
65
65
  import { useRoute,useRouter } from 'vue-router'
66
66
 
67
67
 
68
+ // const store = useStore()
68
69
  const route = useRoute()
69
- const router = useRouter()
70
+ const router = useRouter()
70
71
 
71
72
  // await store.dispatch('orders/fetchOrders').then(
72
73
  // succes => { console.log('sycces') },
@@ -64,7 +64,6 @@
64
64
  import IconEdit from '@pf/src/modules/icons/navigation/IconEdit.vue'
65
65
  import PlaceholderUserpic from '@pf/src/modules/icons/placeholders/PlaceholderUserpic.vue'
66
66
 
67
-
68
67
  const router = useRouter()
69
68
 
70
69
  const props = defineProps({
@@ -25,7 +25,6 @@
25
25
  >
26
26
  <!-- Image Wrappers -->
27
27
  <img v-if="product.images[0]" :src="(FILE_SERVER_URL || '') + product.images[0]" class="w-100 h-100">
28
-
29
28
  <svg
30
29
  v-else
31
30
  class="h-100 w-100"
@@ -108,7 +107,22 @@
108
107
 
109
108
  const props = defineProps(['product'])
110
109
 
110
+ function addToFavorites(product) {
111
+ store.dispatch('favorites/addProductToFavorites', product);
112
+
113
+ console.log('hello');
114
+ }
111
115
  const { t } = useI18n()
116
+
117
+ const isInFavorites = computed(() => {
118
+ return store.state.favorites.items.filter(function(item, index) {
119
+ if (item._id === props.product._id) {
120
+ return true;
121
+ }
122
+ })
123
+ })
124
+
125
+
112
126
  </script>
113
127
 
114
128
  <style lang="scss">