@ozdao/prometheus-framework 0.2.117 → 0.2.119

Sign up to get free protection for your applications and to get access to all the features.
Files changed (217) hide show
  1. package/dist/community.server.js +1 -1
  2. package/dist/community.server.mjs +1 -1
  3. package/dist/events.server.js +1 -1
  4. package/dist/events.server.mjs +1 -1
  5. package/dist/gallery.server.js +9 -3
  6. package/dist/gallery.server.mjs +9 -3
  7. package/dist/main-DL3vRQCi.js +92 -0
  8. package/dist/main-Ds3Z5x5d.mjs +14206 -0
  9. package/dist/main.css +1 -1
  10. package/dist/orders.server.js +1 -1
  11. package/dist/orders.server.mjs +1 -1
  12. package/dist/organizations.server.js +1 -1
  13. package/dist/organizations.server.mjs +1 -1
  14. package/dist/products.server.js +1 -1
  15. package/dist/products.server.mjs +1 -1
  16. package/dist/prometheus-framework/src/components/Block/Block.vue.cjs +1 -1
  17. package/dist/prometheus-framework/src/components/Block/Block.vue.js +1 -1
  18. package/dist/prometheus-framework/src/components/Button/Button.vue.cjs +1 -1
  19. package/dist/prometheus-framework/src/components/Button/Button.vue.js +1 -94
  20. package/dist/prometheus-framework/src/components/Button/Button.vue2.cjs +1 -1
  21. package/dist/prometheus-framework/src/components/Button/Button.vue2.js +94 -1
  22. package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue2.cjs +1 -1
  23. package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue2.js +116 -117
  24. package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue.cjs +1 -1
  25. package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue.js +58 -1
  26. package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue2.cjs +1 -1
  27. package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue2.js +1 -58
  28. package/dist/prometheus-framework/src/components/Feed/Feed.vue.cjs +1 -1
  29. package/dist/prometheus-framework/src/components/Feed/Feed.vue.js +123 -109
  30. package/dist/prometheus-framework/src/components/Field/Field.vue.cjs +1 -1
  31. package/dist/prometheus-framework/src/components/Field/Field.vue.js +1 -84
  32. package/dist/prometheus-framework/src/components/Field/Field.vue2.cjs +1 -1
  33. package/dist/prometheus-framework/src/components/Field/Field.vue2.js +84 -1
  34. package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.cjs +1 -1
  35. package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.js +1 -1
  36. package/dist/prometheus-framework/src/components/FieldTags/BlockTags.vue.cjs +1 -1
  37. package/dist/prometheus-framework/src/components/FieldTags/BlockTags.vue.js +32 -26
  38. package/dist/prometheus-framework/src/components/Popup/Popup.vue.cjs +1 -1
  39. package/dist/prometheus-framework/src/components/Popup/Popup.vue.js +1 -73
  40. package/dist/prometheus-framework/src/components/Popup/Popup.vue2.cjs +1 -1
  41. package/dist/prometheus-framework/src/components/Popup/Popup.vue2.js +77 -1
  42. package/dist/prometheus-framework/src/components/Select/Select.vue.cjs +1 -1
  43. package/dist/prometheus-framework/src/components/Select/Select.vue.js +1 -103
  44. package/dist/prometheus-framework/src/components/Select/Select.vue2.cjs +1 -1
  45. package/dist/prometheus-framework/src/components/Select/Select.vue2.js +103 -1
  46. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.cjs +1 -1
  47. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.js +1 -45
  48. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue2.cjs +1 -1
  49. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue2.js +45 -1
  50. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.cjs +1 -1
  51. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.js +2 -2
  52. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.cjs +1 -1
  53. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.js +1 -1
  54. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.cjs +1 -1
  55. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.js +2 -2
  56. package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.cjs +1 -1
  57. package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.js +2 -2
  58. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.cjs +1 -1
  59. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.js +2 -2
  60. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.cjs +1 -1
  61. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.js +2 -2
  62. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.cjs +1 -1
  63. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.js +2 -2
  64. package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.cjs +1 -1
  65. package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.js +1 -1
  66. package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.cjs +1 -1
  67. package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.js +3 -3
  68. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.cjs +1 -1
  69. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.js +4 -4
  70. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.cjs +1 -1
  71. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.js +17 -18
  72. package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.cjs +1 -1
  73. package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.js +1 -1
  74. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.cjs +1 -5
  75. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.js +0 -66
  76. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.cjs +5 -1
  77. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.js +66 -0
  78. package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.cjs +1 -1
  79. package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.js +1 -1
  80. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.cjs +1 -1
  81. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.js +2 -2
  82. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.cjs +1 -1
  83. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.js +1 -1
  84. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.cjs +1 -1
  85. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +4 -4
  86. package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.cjs +1 -1
  87. package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.js +3 -3
  88. package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.cjs +1 -1
  89. package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.js +44 -69
  90. package/dist/prometheus-framework/src/modules/gallery/components/blocks/PhotoViewer.vue.cjs +1 -0
  91. package/dist/prometheus-framework/src/modules/gallery/components/blocks/PhotoViewer.vue.js +64 -0
  92. package/dist/prometheus-framework/src/modules/gallery/components/blocks/PhotoViewer.vue2.cjs +1 -0
  93. package/dist/prometheus-framework/src/modules/gallery/components/blocks/PhotoViewer.vue2.js +1 -0
  94. package/dist/prometheus-framework/src/modules/gallery/components/pages/Gallery.vue.cjs +1 -1
  95. package/dist/prometheus-framework/src/modules/gallery/components/pages/Gallery.vue.js +101 -14
  96. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
  97. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +167 -104
  98. package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.cjs +1 -1
  99. package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.js +2 -2
  100. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.cjs +1 -1
  101. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.js +1 -1
  102. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.cjs +1 -1
  103. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.js +4 -4
  104. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonDate.vue.cjs +1 -1
  105. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonDate.vue.js +38 -1
  106. package/dist/prometheus-framework/src/modules/globals/components/sections/SectionPageTitle.vue.cjs +1 -1
  107. package/dist/prometheus-framework/src/modules/globals/components/sections/SectionPageTitle.vue.js +3 -3
  108. package/dist/prometheus-framework/src/modules/globals/services/globals.store.cjs +1 -1
  109. package/dist/prometheus-framework/src/modules/globals/services/globals.store.js +21 -21
  110. package/dist/prometheus-framework/src/modules/icons/navigation/IconChevronBottom.vue.cjs +1 -0
  111. package/dist/prometheus-framework/src/modules/icons/navigation/IconChevronBottom.vue.js +30 -0
  112. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonBlogpost.vue.cjs +1 -1
  113. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonBlogpost.vue.js +3 -3
  114. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonEvent.vue.cjs +1 -1
  115. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonEvent.vue.js +1 -1
  116. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonEventShort.vue.cjs +1 -1
  117. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonEventShort.vue.js +5 -5
  118. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonOrganization.vue.cjs +1 -1
  119. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonOrganization.vue.js +1 -1
  120. package/dist/prometheus-framework/src/modules/landing/components/sections/SectionGuide.vue.cjs +1 -0
  121. package/dist/prometheus-framework/src/modules/landing/components/sections/SectionGuide.vue.js +98 -0
  122. package/dist/prometheus-framework/src/modules/landing/landing.client.cjs +1 -1
  123. package/dist/prometheus-framework/src/modules/landing/landing.client.js +6 -4
  124. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.cjs +1 -1
  125. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.js +2 -2
  126. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderBackoffice.vue.cjs +1 -1
  127. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderBackoffice.vue.js +1 -1
  128. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.cjs +1 -1
  129. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js +4 -4
  130. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.cjs +1 -1
  131. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.js +3 -3
  132. package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.cjs +1 -1
  133. package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.js +2 -2
  134. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.cjs +1 -1
  135. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.js +1 -1
  136. package/dist/prometheus-framework/src/modules/orders/components/sections/FormPayment.vue.cjs +1 -1
  137. package/dist/prometheus-framework/src/modules/orders/components/sections/FormPayment.vue.js +1 -1
  138. package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.cjs +1 -1
  139. package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.js +1 -1
  140. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +1 -1
  141. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +4 -4
  142. package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.cjs +1 -1
  143. package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.js +2 -2
  144. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.cjs +1 -1
  145. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.js +4 -4
  146. package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.cjs +1 -1
  147. package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.js +1 -1
  148. package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.cjs +1 -1
  149. package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.js +3 -3
  150. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.cjs +1 -1
  151. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.js +3 -3
  152. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +1 -1
  153. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +5 -5
  154. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.cjs +1 -1
  155. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.js +2 -2
  156. package/dist/prometheus-framework/src/modules/products/components/blocks/ImagesThumbnails.vue.cjs +1 -1
  157. package/dist/prometheus-framework/src/modules/products/components/blocks/ImagesThumbnails.vue.js +1 -1
  158. package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.cjs +1 -1
  159. package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.js +1 -1
  160. package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.cjs +1 -1
  161. package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.js +1 -1
  162. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.cjs +1 -1
  163. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.js +1 -1
  164. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.cjs +1 -1
  165. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.js +3 -3
  166. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +1 -1
  167. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.js +3 -3
  168. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.cjs +1 -1
  169. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js +3 -3
  170. package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.cjs +1 -1
  171. package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.js +1 -1
  172. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.cjs +1 -1
  173. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js +3 -3
  174. package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.cjs +1 -1
  175. package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.js +31 -32
  176. package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.cjs +1 -1
  177. package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.js +1 -1
  178. package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.cjs +1 -1
  179. package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.js +3 -3
  180. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +1 -1
  181. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +3 -3
  182. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.cjs +1 -1
  183. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.js +2 -2
  184. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +1 -1
  185. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +5 -5
  186. package/dist/prometheus-framework.cjs.js +1 -1
  187. package/dist/prometheus-framework.es.js +1 -1
  188. package/dist/queryProcessor-g8208K6g.mjs +178 -0
  189. package/dist/queryProcessor-haY_gPGg.js +177 -0
  190. package/dist/style.css +1 -1
  191. package/dist/wallet.server.js +1 -1
  192. package/dist/wallet.server.mjs +1 -1
  193. package/dist/web-B8tq3Fda.mjs +54 -0
  194. package/dist/web-ByJkgGrt.js +1 -0
  195. package/package.json +1 -1
  196. package/src/components/DatePicker/Calendar.vue +82 -55
  197. package/src/components/Feed/Feed.vue +45 -16
  198. package/src/components/FieldTags/BlockTags.vue +30 -23
  199. package/src/components/Popup/Popup.vue +2 -2
  200. package/src/modules/events/components/pages/Events.vue +2 -48
  201. package/src/modules/gallery/components/blocks/PhotoViewer.vue +115 -0
  202. package/src/modules/gallery/components/pages/Gallery.vue +103 -6
  203. package/src/modules/gallery/components/sections/BackofficeGallery.vue +100 -32
  204. package/src/modules/gallery/controllers/gallery.controller.js +45 -38
  205. package/src/modules/globals/components/blocks/CardHeader.vue +1 -1
  206. package/src/modules/globals/components/elements/ButtonDate.vue +37 -43
  207. package/src/modules/globals/components/layouts/Client.vue +1 -1
  208. package/src/modules/globals/components/sections/SectionPageTitle.vue +1 -1
  209. package/src/modules/globals/controllers/utils/queryProcessor.js +21 -2
  210. package/src/modules/globals/services/globals.store.js +13 -17
  211. package/src/modules/icons/skeletons/SkeletonBlogpost.vue +1 -1
  212. package/src/modules/icons/skeletons/SkeletonEvent.vue +1 -1
  213. package/src/modules/icons/skeletons/SkeletonEventShort.vue +1 -1
  214. package/src/modules/icons/skeletons/SkeletonOrganization.vue +1 -1
  215. package/src/modules/landing/landing.client.js +2 -0
  216. package/src/modules/products/components/sections/FilterProducts.vue +2 -1
  217. package/src/modules/gallery/components/sections/GalleryWithCategories.vue +0 -176
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
 
3
- <div v-if="search" class="flex-nowrap flex gap-thin mn-b-thin">
3
+ <div v-if="search || date || sort" class="flex-nowrap flex gap-thin mn-b-thin">
4
4
 
5
5
  <BlockSearch
6
6
  v-if="search"
@@ -9,17 +9,19 @@
9
9
  @search="updateSearch"
10
10
  />
11
11
 
12
- <div class="flex-center flex pd-thin bg-light radius-extra aspect-1x1 h-100">
12
+ <!-- <div class="flex-center flex pd-thin bg-light radius-extra aspect-1x1 h-100">
13
13
  <IconFilter class="w-1r h-auto"/>
14
- </div>
14
+ </div> -->
15
15
 
16
16
  <Dropdown
17
+ v-if="date"
17
18
  :label="{
18
- component: ButtonDate
19
+ component: ButtonDate,
20
+ props: { date: date }
19
21
  }"
20
- :class="search.class || 'bg-light'"
21
- class="flex-child flex-child-grow-1 flex-child-shrink-0 pd-r-small pd-l-small pd-thin bg-light radius-big"
22
- :align="'right'"
22
+ :class="date.class || 'bg-light'"
23
+ class="flex-child flex-child-shrink-0 pd-r-small pd-l-small pd-thin bg-light radius-big"
24
+ :align="search ? 'right' : 'left'"
23
25
  >
24
26
 
25
27
  <Calendar
@@ -37,9 +39,9 @@
37
39
  props: { order: sort.order },
38
40
  class: 'w-1r'
39
41
  }"
40
- :class="search.class || 'bg-light'"
42
+ :class="sort.class || 'bg-light'"
41
43
  class="radius-extra aspect-1x1 h-100"
42
- :align="'right'"
44
+ :align="search ? 'right' : 'left'"
43
45
  >
44
46
 
45
47
  <BlockSorting
@@ -181,8 +183,8 @@ let sentinel = ref(null)
181
183
  let currentSkip = ref(props.options.skip ? props.options.skip : 0);
182
184
  let currentLimit = ref(props.options.limit ? props.options.limit : 10);
183
185
 
184
- let sortParam = ref(sort.value?.param || 'createdAt');
185
- let sortOrder = ref(sort.value?.order || 'asc');
186
+ // let sortParam = ref(sort.value?.param || 'createdAt');
187
+ // let sortOrder = ref(sort.value?.order || 'asc');
186
188
 
187
189
  let currentSearch = ref('');
188
190
 
@@ -203,8 +205,10 @@ const loadMoreItems = async () => {
203
205
  skip: currentSkip.value,
204
206
  limit: currentLimit.value,
205
207
  search: currentSearch.value,
206
- sortParam: sortParam.value,
207
- sortOrder: sortOrder.value,
208
+ dateStart: date.value ? date.value.start : null,
209
+ dateEnd: date.value ? date.value.end : null,
210
+ sortParam: sort.value ? sort.value.param : null,
211
+ sortOrder: sort.value ? sort.value.order : null,
208
212
  ...props.options
209
213
  });
210
214
 
@@ -223,11 +227,14 @@ const loadMoreItems = async () => {
223
227
  };
224
228
 
225
229
  const fetchItems = async () => {
230
+ console.log('Date is', date.value)
226
231
  const data = await props.store.read({
227
232
  skip: currentSkip.value,
228
233
  limit: currentLimit.value,
229
- sortParam: sortParam.value,
230
- sortOrder: sortOrder.value,
234
+ dateStart: date.value ? date.value.start : null,
235
+ dateEnd: date.value ? date.value.end : null,
236
+ sortParam: sort.value ? sort.value.param : null,
237
+ sortOrder: sort.value ? sort.value.order : null,
231
238
  search: currentSearch.value,
232
239
  ...props.options
233
240
  });
@@ -252,6 +259,27 @@ watch(() => props.external, (newVal, oldVal) => {
252
259
  }
253
260
  }, { deep: true });
254
261
 
262
+ watch(() => date.value, (newVal, oldVal) => {
263
+ if (newVal !== oldVal) {
264
+ fetchItems();
265
+ }
266
+ }, { deep: true });
267
+
268
+ watch(() => sort.value?.order, (newVal, oldVal) => {
269
+
270
+ if (newVal !== oldVal) {
271
+ fetchItems();
272
+ }
273
+ }, { deep: true });
274
+
275
+ watch(() => sort.value?.param, (newVal, oldVal) => {
276
+
277
+ if (newVal !== oldVal) {
278
+ fetchItems();
279
+ }
280
+ }, { deep: true });
281
+
282
+
255
283
  watch(() => props.options, (newVal, oldVal) => {
256
284
  if (
257
285
  newVal.organization !== oldVal.organization ||
@@ -261,7 +289,8 @@ watch(() => props.options, (newVal, oldVal) => {
261
289
  newVal.search !== oldVal.search ||
262
290
  newVal.status !== oldVal.status ||
263
291
  newVal.hidden !== oldVal.hidden ||
264
- newVal.type !== oldVal.type
292
+ newVal.type !== oldVal.type ||
293
+ newVal.tags !== oldVal.tags
265
294
  ) {
266
295
  fetchItems();
267
296
  }
@@ -17,40 +17,47 @@
17
17
  class="mn-b-thin bg-light radius-medium pd-small"
18
18
  />
19
19
 
20
- <p class="mn-b-medium">
21
- <p class="p-small mn-b-thin">Suggested:</p>
22
-
23
- <span
24
- v-if="filteredSuggestedItems.length > 0"
25
- v-for="(tag,index) in filteredSuggestedItems"
26
- @click="addTag(tag)"
27
- class="cursor-pointer t-medium ti-tag-toDefactor"
28
- :class="{'mn-r-micro':index !== filteredSuggestedItems.length - 1}"
29
- >
30
- {{ tag.text }}
31
- </span>
32
- <span v-else>You added all suggested tags</span>
33
- </p>
20
+ <p class="p-small mn-b-thin">Suggested:</p>
21
+
22
+ <span
23
+ v-if="filteredSuggestedItems.length > 0"
24
+ v-for="(tag,index) in filteredSuggestedItems"
25
+ @click="addTag(tag)"
26
+ class="cursor-pointer t-medium ti-tag-toDefactor"
27
+ :class="{'mn-r-micro':index !== filteredSuggestedItems.length - 1}"
28
+ >
29
+ {{ tag.text }}
30
+ </span>
31
+ <span v-else>You added all suggested tags</span>
34
32
  </div>
35
33
  </template>
36
34
 
37
35
  <script setup>
38
36
  import FieldTags from '@pf/src/components/FieldTags/FieldTags.vue'
39
- import { ref, computed, defineEmits, onMounted } from 'vue';
37
+ import { ref, computed, onMounted } from 'vue';
40
38
 
41
39
  const emits = defineEmits(['tags-changed']);
42
- const props = defineProps(['tags']);
40
+ const props = defineProps({
41
+ tags: {
42
+ type: Array
43
+ },
44
+ tagsSuggested: {
45
+ type: Array,
46
+ default: [
47
+ { text: 'story' },
48
+ { text: 'news' },
49
+ { text: 'guide' },
50
+ { text: 'discussion' },
51
+ { text: 'photos' },
52
+ ]
53
+ }
54
+ });
43
55
 
44
56
  const tag = ref('');
45
57
 
46
58
  const selectedTags = ref([]);
47
- const autocompleteItems = ref([
48
- { text: 'story' },
49
- { text: 'news' },
50
- { text: 'guide' },
51
- { text: 'discussion' },
52
- { text: 'photos' },
53
- ]);
59
+
60
+ const autocompleteItems = ref(props.tagsSuggested);
54
61
 
55
62
  if (props.tags) selectedTags.value = props.tags.map(tag => ({text: tag}))
56
63
 
@@ -6,8 +6,8 @@
6
6
 
7
7
  <transition name="TransitionTranslateY" mode="out-in">
8
8
  <section class="pos-relative z-index-4" v-bind="$attrs" :class="$attrs.class">
9
- <h4 class="mn-b-small">{{title}}</h4>
10
- <IconCross @click="closePopup()" class="cursor-pointer pos-absolute pos-t-0 pos-r-0 mn-t-semi mn-r-semi hover-scale-1 i-regular z-index-5"/>
9
+ <h4 v-if="title" class="mn-b-small">{{title}}</h4>
10
+ <IconCross :fill="'rgb(var(--white))'" @click="closePopup()" class="cursor-pointer bg-second pd-micro radius-extra pos-absolute pos-t-0 pos-r-0 mn-t-semi mn-r-semi hover-scale-1 i-medium z-index-5"/>
11
11
  <slot></slot>
12
12
  </section>
13
13
  </transition>
@@ -9,60 +9,14 @@
9
9
  Featured
10
10
  </h2>
11
11
  </header>
12
+
12
13
  <List
13
14
  :user="auth.state.user._id"
14
15
  class="bg-light mn-b-medium radius-big"
15
16
  :phase="'planned'"
16
17
  />
17
18
 
18
-
19
- <div class="cols-2 gap-medium pd-medium bg-light radius-big">
20
- <div class="">
21
- <h2
22
- class="mn-b-medium"
23
- >
24
- Finished Events
25
- </h2>
26
- <List
27
- :user="auth.state.user._id"
28
- class="bg-white mn-b-medium radius-big"
29
- :phase="'finished'"
30
- />
31
- </div>
32
-
33
- <div class="">
34
- <h2
35
- class="mn-b-medium"
36
- >
37
- Planned
38
- </h2>
39
- <List
40
- :user="auth.state.user._id"
41
- class="bg-white mn-b-medium radius-big"
42
- :phase="'planned'"
43
- />
44
- </div>
45
- </div>
46
-
47
-
48
- <header
49
- class="mn-b-medium flex-v-center flex-nowrap flex"
50
- >
51
- <h2
52
- class="mn-r-medium"
53
- >
54
- All Events
55
- </h2>
56
-
57
- <button
58
- @click="router.push({name: 'Create Event'})"
59
- class="radius-100 i-big hover-scale-1 cursor-pointer t-white bg-second"
60
- >
61
- +
62
- </button>
63
- </header>
64
-
65
- <DatePicker
19
+ <DatePicker
66
20
  v-model:date="events.state.filter.date"
67
21
  :locale="$i18n.locale"
68
22
  class="radius-semi o-hidden bg-light mn-b-thin pd-l-zero pd-r-zero pd-medium"
@@ -0,0 +1,115 @@
1
+ <template>
2
+ <div class="photo-container" @wheel="handleWheel" @mousedown="startDrag" @touchstart="handleTouchStart" @touchmove="handleTouchMove" @touchend="handleTouchEnd">
3
+ <img :src="photoUrl" :style="imgStyle" ref="image" @load="initialize" />
4
+ </div>
5
+ </template>
6
+
7
+ <script setup>
8
+ import { ref, reactive, computed } from 'vue';
9
+
10
+ const props = defineProps({
11
+ photoUrl: String,
12
+ show: Boolean,
13
+ });
14
+
15
+ const scale = ref(1);
16
+ const position = reactive({ x: 0, y: 0 });
17
+ const dragging = ref(false);
18
+ const startPosition = reactive({ x: 0, y: 0 });
19
+ const startScale = ref(1);
20
+ const startDistance = ref(0);
21
+
22
+ const imgStyle = computed(() => ({
23
+ transform: `scale(${scale.value}) translate(${position.x}px, ${position.y}px)`,
24
+ }));
25
+
26
+ const handleWheel = (event) => {
27
+ event.preventDefault();
28
+ const delta = event.deltaY > 0 ? -0.1 : 0.1;
29
+ scale.value = Math.min(Math.max(1, scale.value + delta), 3);
30
+ };
31
+
32
+ const startDrag = (event) => {
33
+ event.preventDefault();
34
+ dragging.value = true;
35
+ startPosition.x = event.type === 'mousedown' ? event.clientX : event.touches[0].clientX;
36
+ startPosition.y = event.type === 'mousedown' ? event.clientY : event.touches[0].clientY;
37
+ const move = (moveEvent) => {
38
+ if (dragging.value) {
39
+ const currentX = moveEvent.type === 'mousemove' ? moveEvent.clientX : moveEvent.touches[0].clientX;
40
+ const currentY = moveEvent.type === 'mousemove' ? moveEvent.clientY : moveEvent.touches[0].clientY;
41
+ position.x += (currentX - startPosition.x) / scale.value;
42
+ position.y += (currentY - startPosition.y) / scale.value;
43
+ startPosition.x = currentX;
44
+ startPosition.y = currentY;
45
+ }
46
+ };
47
+ const endDrag = () => {
48
+ dragging.value = false;
49
+ document.removeEventListener('mousemove', move);
50
+ document.removeEventListener('mouseup', endDrag);
51
+ document.removeEventListener('touchmove', move);
52
+ document.removeEventListener('touchend', endDrag);
53
+ };
54
+ document.addEventListener('mousemove', move);
55
+ document.addEventListener('mouseup', endDrag);
56
+ document.addEventListener('touchmove', move);
57
+ document.addEventListener('touchend', endDrag);
58
+ };
59
+
60
+ const handleTouchStart = (event) => {
61
+ if (event.touches.length === 2) {
62
+ const touch1 = event.touches[0];
63
+ const touch2 = event.touches[1];
64
+ const distanceX = Math.abs(touch1.clientX - touch2.clientX);
65
+ const distanceY = Math.abs(touch1.clientY - touch2.clientY);
66
+ startDistance.value = Math.sqrt(distanceX ** 2 + distanceY ** 2);
67
+ startScale.value = scale.value;
68
+ } else {
69
+ startDrag(event);
70
+ }
71
+ };
72
+
73
+ const handleTouchMove = (event) => {
74
+ if (event.touches.length === 2) {
75
+ event.preventDefault();
76
+ const touch1 = event.touches[0];
77
+ const touch2 = event.touches[1];
78
+ const distanceX = Math.abs(touch1.clientX - touch2.clientX);
79
+ const distanceY = Math.abs(touch1.clientY - touch2.clientY);
80
+ const newDistance = Math.sqrt(distanceX ** 2 + distanceY ** 2);
81
+ const scaleFactor = newDistance / startDistance.value;
82
+ scale.value = Math.min(Math.max(1, startScale.value * scaleFactor), 3);
83
+ }
84
+ };
85
+
86
+ const handleTouchEnd = (event) => {
87
+ if (event.touches.length === 0) {
88
+ startDistance.value = 0;
89
+ }
90
+ };
91
+
92
+ const initialize = () => {
93
+ scale.value = 1;
94
+ position.x = 0;
95
+ position.y = 0;
96
+ };
97
+ </script>
98
+
99
+ <style scoped>
100
+ .photo-container {
101
+ width: 100%;
102
+ height: 100%;
103
+ background: black;
104
+ overflow: hidden;
105
+ position: relative;
106
+ cursor: grab;
107
+ }
108
+
109
+ .photo-container img {
110
+ width: 100%;
111
+ height: 100%;
112
+ object-fit: scale-down;
113
+ transition: transform 0.3s;
114
+ }
115
+ </style>
@@ -1,15 +1,112 @@
1
1
  <template>
2
- <div class="wrapper">
3
- <Title :text="$t('gallery.title')" class="pd-medium" />
2
+ <div class="cols-1 gap-thin pd-thin">
3
+ <SectionPageTitle
4
+ :title="$t('gallery.title')"
5
+ @update:tabs_current="(update) => tab = update"
6
+ :tabs_current="tab"
7
+ :tabs="[
8
+ { name: 'All', value: 'all' },
9
+ { name: 'Place', value: 'place' },
10
+ { name: 'Drinks', value: 'drinks' },
11
+ { name: 'People', value: 'people' },
12
+ { name: 'Events', value: 'events' }
13
+ ]"
14
+ class="mn-b-small bg-light bg-light radius-big"
15
+ />
16
+ <Popup
17
+ @close-popup="closePreviewPopup"
18
+ :isPopupOpen="isOpenPreviewPopup"
19
+ class="bg-black o-hidden w-100 h-100 radius-big"
20
+ >
21
+ <PhotoViewer
22
+ :photoUrl="selectedPhoto.image"
23
+ />
24
+ </Popup>
4
25
 
5
- <div style="min-height: 100vh">
6
- <GalleryWithCategories/>
7
- </div>
26
+ <Feed
27
+ v-model:items="photos"
28
+ v-model:sort="sort"
29
+ v-model:date="date"
30
+ :states="{
31
+ empty: {
32
+ title: 'No Photos Found',
33
+ description: 'Currently, there are no photos in gallery.'
34
+ },
35
+ }"
36
+ :store="{
37
+ read: (options) => gallery.read(options)
38
+ }"
39
+ :options="{
40
+ limit: 15,
41
+ status: 'published',
42
+ ...(tab !== 'all' && { tags: tab })
43
+ }"
44
+ v-slot="{
45
+ items
46
+ }"
47
+ class="cols-3 gap-thin"
48
+ >
49
+ <div v-for="item in items" :key="item._id" class="bg-light radius-medium o-hidden flex-column pos-relative flex-wrap">
50
+ <div class="w-100 h-100 pos-relative">
51
+ <img
52
+ :src="(FILE_SERVER_URL || '') + item.cover"
53
+ class="w-100 h-100 object-fit-cover bg-black " @click="openPreviewPopup(item)"
54
+ />
55
+ </div>
56
+ </div>
57
+ </Feed>
8
58
  </div>
9
59
  </template>
10
60
 
11
61
  <script setup>
62
+ import { ref, onMounted, reactive, computed } from 'vue'
63
+
12
64
  import Title from '@pf/src/modules/globals/components/sections/Title.vue';
13
65
 
14
- import GalleryWithCategories from '@pf/src/modules/gallery/components/sections/GalleryWithCategories.vue';
66
+ import Feed from '@pf/src/components/Feed/Feed.vue'
67
+ import Popup from '@pf/src/components/Popup/Popup.vue'
68
+
69
+ import SectionPageTitle from '@pf/src/modules/globals/components/sections/SectionPageTitle.vue'
70
+
71
+ import PhotoViewer from '@pf/src/modules/gallery/components/blocks/PhotoViewer.vue'
72
+
73
+ import gallery from '@pf/src/modules/gallery/store/gallery';
74
+
75
+ const photos = ref([])
76
+
77
+ const tab = ref('all')
78
+
79
+ let sort = ref({
80
+ param: 'createdAt',
81
+ order: 'desc',
82
+ options: [{
83
+ label: 'Date',
84
+ value: 'createdAt'
85
+ },{
86
+ label: 'Popularity',
87
+ value: 'views'
88
+ },{
89
+ label: 'Creator',
90
+ value: 'creator'
91
+ }]
92
+ })
93
+ // Date
94
+ let date = ref({
95
+ start: null,
96
+ end: null
97
+ })
98
+
99
+ const selectedPhoto = ref(null);
100
+
101
+ // Preview Photo
102
+ const isOpenPreviewPopup = ref(false);
103
+ function openPreviewPopup(photo) {
104
+ isOpenPreviewPopup.value = true;
105
+ selectedPhoto.value = photo;
106
+ }
107
+ function closePreviewPopup() {
108
+ isOpenPreviewPopup.value = false;
109
+ selectedPhoto.value = null;
110
+ }
111
+
15
112
  </script>