@ozdao/martyrs 0.2.571 → 0.2.574

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 (819) hide show
  1. package/dist/_virtual/dayjs.min.js +1 -1
  2. package/dist/_virtual/weekOfYear.js +1 -1
  3. package/dist/builder.js +1194 -45
  4. package/dist/loader.js +30 -0
  5. package/dist/{main-BFvlam0J.js → main-BfEQkhXS.js} +1173 -1191
  6. package/dist/martyrs/dist/{main-BFvlam0J.js → main-BfEQkhXS.js} +94 -112
  7. package/dist/martyrs/dist/main-BfEQkhXS.js.map +1 -0
  8. package/dist/martyrs/dist/{web-CH5wzMHy.js → web-BqTV9va1.js} +3 -3
  9. package/dist/martyrs/dist/{web-CH5wzMHy.js.map → web-BqTV9va1.js.map} +1 -1
  10. package/dist/martyrs/node_modules/.pnpm/{@capacitor_core@7.0.1 → @capacitor_core@7.4.4}/node_modules/@capacitor/core/dist/index.js +2 -1
  11. package/dist/martyrs/node_modules/.pnpm/@capacitor_core@7.4.4/node_modules/@capacitor/core/dist/index.js.map +1 -0
  12. package/dist/martyrs/node_modules/.pnpm/{@capacitor_preferences@7.0.0_@capacitor_core@7.0.1 → @capacitor_preferences@7.0.2_@capacitor_core@7.4.4}/node_modules/@capacitor/preferences/dist/esm/index.js +1 -1
  13. package/dist/martyrs/node_modules/.pnpm/{@capacitor_preferences@7.0.0_@capacitor_core@7.0.1 → @capacitor_preferences@7.0.2_@capacitor_core@7.4.4}/node_modules/@capacitor/preferences/dist/esm/index.js.map +1 -1
  14. package/dist/martyrs/node_modules/.pnpm/{@capacitor_preferences@7.0.0_@capacitor_core@7.0.1 → @capacitor_preferences@7.0.2_@capacitor_core@7.4.4}/node_modules/@capacitor/preferences/dist/esm/web.js +1 -1
  15. package/dist/martyrs/node_modules/.pnpm/{@capacitor_preferences@7.0.0_@capacitor_core@7.0.1 → @capacitor_preferences@7.0.2_@capacitor_core@7.4.4}/node_modules/@capacitor/preferences/dist/esm/web.js.map +1 -1
  16. package/dist/{node_modules/.pnpm/@vue_server-renderer@3.5.13_vue@3.5.13_typescript@5.8.3_ → martyrs}/node_modules/@vue/server-renderer/dist/server-renderer.esm-bundler.js +1 -1
  17. package/dist/martyrs/node_modules/@vue/server-renderer/dist/server-renderer.esm-bundler.js.map +1 -0
  18. package/dist/martyrs/node_modules/@vue/shared/dist/shared.esm-bundler.js.map +1 -0
  19. package/dist/{node_modules/.pnpm/dayjs@1.11.13 → martyrs}/node_modules/dayjs/dayjs.min.js +1 -1
  20. package/dist/martyrs/node_modules/dayjs/dayjs.min.js.map +1 -0
  21. package/dist/{node_modules/.pnpm/dayjs@1.11.13 → martyrs}/node_modules/dayjs/plugin/weekOfYear.js +1 -1
  22. package/dist/martyrs/node_modules/dayjs/plugin/weekOfYear.js.map +1 -0
  23. package/dist/martyrs/node_modules/uuid/dist/esm-browser/regex.js +5 -0
  24. package/dist/martyrs/node_modules/uuid/dist/esm-browser/regex.js.map +1 -0
  25. package/dist/martyrs/node_modules/uuid/dist/esm-browser/rng.js +15 -0
  26. package/dist/martyrs/node_modules/uuid/dist/esm-browser/rng.js.map +1 -0
  27. package/dist/martyrs/node_modules/uuid/dist/esm-browser/stringify.js +17 -0
  28. package/dist/martyrs/node_modules/uuid/dist/esm-browser/stringify.js.map +1 -0
  29. package/dist/martyrs/node_modules/uuid/dist/esm-browser/v4.js +13 -0
  30. package/dist/martyrs/node_modules/uuid/dist/esm-browser/v4.js.map +1 -0
  31. package/dist/martyrs/node_modules/uuid/dist/esm-browser/validate.js +8 -0
  32. package/dist/martyrs/node_modules/uuid/dist/esm-browser/validate.js.map +1 -0
  33. package/dist/martyrs/src/components/Block/Block.vue.js +2 -2
  34. package/dist/martyrs/src/components/Block/Block.vue.js.map +1 -1
  35. package/dist/martyrs/src/components/BottomSheet/BottomSheet.vue.js +1 -1
  36. package/dist/martyrs/src/components/BottomSheet/BottomSheet.vue.js.map +1 -1
  37. package/dist/martyrs/src/components/Button/Button.vue2.js +1 -1
  38. package/dist/martyrs/src/components/Calendar/Calendar.vue2.js +6 -6
  39. package/dist/martyrs/src/components/Calendar/Calendar.vue2.js.map +1 -1
  40. package/dist/martyrs/src/components/Checkbox/Checkbox.vue.js +2 -2
  41. package/dist/martyrs/src/components/Checkbox/Checkbox.vue.js.map +1 -1
  42. package/dist/martyrs/src/components/Chips/Chips.vue.js +2 -2
  43. package/dist/martyrs/src/components/Countdown/Countdown.vue.js +5 -5
  44. package/dist/martyrs/src/components/Countdown/Countdown.vue.js.map +1 -1
  45. package/dist/martyrs/src/components/DatePicker/DatePicker.vue.js +4 -4
  46. package/dist/martyrs/src/components/DatePicker/DatePicker.vue.js.map +1 -1
  47. package/dist/martyrs/src/components/EditImages/{EditImages.vue.js → EditImages.vue2.js} +3 -3
  48. package/dist/martyrs/src/components/EditImages/EditImages.vue2.js.map +1 -0
  49. package/dist/martyrs/src/components/Feed/Carousel.vue.js +1 -1
  50. package/dist/martyrs/src/components/Feed/Feed.vue.js +3 -3
  51. package/dist/martyrs/src/components/Feed/Feed.vue.js.map +1 -1
  52. package/dist/martyrs/src/components/FieldBig/FieldBig.vue.js +2 -2
  53. package/dist/martyrs/src/components/FieldBig/FieldBig.vue.js.map +1 -1
  54. package/dist/martyrs/src/components/FieldPhone/FieldPhone.vue.js +1 -1
  55. package/dist/martyrs/src/components/FieldPhone/FieldPhone.vue.js.map +1 -1
  56. package/dist/martyrs/src/components/FieldTags/BlockTags.vue.js +1 -1
  57. package/dist/martyrs/src/components/FieldTags/BlockTags.vue.js.map +1 -1
  58. package/dist/martyrs/src/components/Loader/{Loader.vue.js → Loader.vue2.js} +3 -3
  59. package/dist/martyrs/src/components/Loader/Loader.vue2.js.map +1 -0
  60. package/dist/martyrs/src/components/LocationMarker/LocationMarker.vue.js +1 -1
  61. package/dist/martyrs/src/components/Media/Media.vue.js +1 -1
  62. package/dist/martyrs/src/components/Menu/{Menu.vue.js → Menu.vue2.js} +2 -2
  63. package/dist/martyrs/src/components/Menu/Menu.vue2.js.map +1 -0
  64. package/dist/martyrs/src/components/Menu/MenuItem.vue.js +2 -2
  65. package/dist/martyrs/src/components/Menu/MenuItem.vue.js.map +1 -1
  66. package/dist/martyrs/src/components/PhotoViewer/PhotoViewer.vue.js +2 -2
  67. package/dist/martyrs/src/components/PhotoViewer/PhotoViewer.vue.js.map +1 -1
  68. package/dist/martyrs/src/components/Radio/Radio.vue.js +1 -1
  69. package/dist/martyrs/src/components/Radio/Radio.vue.js.map +1 -1
  70. package/dist/martyrs/src/components/Select/Select.vue.js +2 -2
  71. package/dist/martyrs/src/components/Select/Select.vue.js.map +1 -1
  72. package/dist/martyrs/src/components/SelectMulti/{SelectMulti.vue2.js → SelectMulti.vue.js} +2 -2
  73. package/dist/martyrs/src/components/SelectMulti/SelectMulti.vue.js.map +1 -0
  74. package/dist/martyrs/src/components/Table/Table.vue.js +3 -3
  75. package/dist/martyrs/src/components/Table/Table.vue.js.map +1 -1
  76. package/dist/martyrs/src/components/Text/Text.vue.js +1 -1
  77. package/dist/martyrs/src/components/Text/Text.vue.js.map +1 -1
  78. package/dist/martyrs/src/components/Tooltip/{Tooltip.vue.js → Tooltip.vue2.js} +2 -2
  79. package/dist/martyrs/src/components/Tooltip/Tooltip.vue2.js.map +1 -0
  80. package/dist/martyrs/src/components/UploadImage/UploadImage.vue.js +4 -4
  81. package/dist/martyrs/src/components/UploadImage/UploadImage.vue.js.map +1 -1
  82. package/dist/martyrs/src/components/UploadImageMultiple/UploadImageMultiple.vue.js +4 -4
  83. package/dist/martyrs/src/components/UploadImageMultiple/UploadImageMultiple.vue.js.map +1 -1
  84. package/dist/martyrs/src/modules/auth/views/components/blocks/CardUser.vue.js +2 -2
  85. package/dist/martyrs/src/modules/auth/views/components/blocks/ProfileCard.vue.js +4 -4
  86. package/dist/martyrs/src/modules/auth/views/components/blocks/ProfileCard.vue.js.map +1 -1
  87. package/dist/martyrs/src/modules/auth/views/components/layouts/Auth.vue.js +1 -1
  88. package/dist/martyrs/src/modules/auth/views/components/layouts/Auth.vue.js.map +1 -1
  89. package/dist/martyrs/src/modules/auth/views/components/pages/EnterPassword.vue.js +2 -2
  90. package/dist/martyrs/src/modules/auth/views/components/pages/EnterPassword.vue.js.map +1 -1
  91. package/dist/martyrs/src/modules/auth/views/components/pages/Profile.vue.js +7 -7
  92. package/dist/martyrs/src/modules/auth/views/components/pages/Profile.vue.js.map +1 -1
  93. package/dist/martyrs/src/modules/auth/views/components/pages/ProfileBlogposts.vue.js +1 -1
  94. package/dist/martyrs/src/modules/auth/views/components/pages/ProfileBlogposts.vue.js.map +1 -1
  95. package/dist/martyrs/src/modules/auth/views/components/pages/ProfileEdit.vue.js +1 -1
  96. package/dist/martyrs/src/modules/auth/views/components/pages/ProfileEditAccount.vue.js +1 -1
  97. package/dist/martyrs/src/modules/auth/views/components/pages/ProfileEditAccount.vue.js.map +1 -1
  98. package/dist/martyrs/src/modules/auth/views/components/pages/ResetPassword.vue.js +1 -1
  99. package/dist/martyrs/src/modules/auth/views/components/pages/ResetPassword.vue.js.map +1 -1
  100. package/dist/martyrs/src/modules/auth/views/components/pages/SignIn.vue.js +3 -3
  101. package/dist/martyrs/src/modules/auth/views/components/pages/SignIn.vue.js.map +1 -1
  102. package/dist/martyrs/src/modules/auth/views/components/pages/SignUp.vue.js +1 -1
  103. package/dist/martyrs/src/modules/auth/views/components/pages/SignUp.vue.js.map +1 -1
  104. package/dist/martyrs/src/modules/auth/views/components/pages/UserDashboard.vue.js +3 -3
  105. package/dist/martyrs/src/modules/auth/views/components/pages/UserDashboard.vue.js.map +1 -1
  106. package/dist/martyrs/src/modules/auth/views/components/sections/FeaturedUsers.vue.js +1 -1
  107. package/dist/martyrs/src/modules/auth/views/components/sections/FeaturedUsers.vue.js.map +1 -1
  108. package/dist/martyrs/src/modules/auth/views/components/sections/ProfileEditCredentials.vue.js +7 -7
  109. package/dist/martyrs/src/modules/auth/views/components/sections/ProfileEditCredentials.vue.js.map +1 -1
  110. package/dist/martyrs/src/modules/auth/views/components/sections/SliderFeatures.vue.js +1 -1
  111. package/dist/martyrs/src/modules/auth/views/components/sections/SliderFeatures.vue.js.map +1 -1
  112. package/dist/martyrs/src/modules/auth/views/store/auth.js +1 -1
  113. package/dist/martyrs/src/modules/backoffice/components/pages/Dashboard.vue.js +4 -4
  114. package/dist/martyrs/src/modules/backoffice/components/pages/Dashboard.vue.js.map +1 -1
  115. package/dist/martyrs/src/modules/backoffice/components/partials/Sidebar.vue.js +6 -6
  116. package/dist/martyrs/src/modules/backoffice/components/partials/Sidebar.vue.js.map +1 -1
  117. package/dist/martyrs/src/modules/chats/components/blocks/ChatMessage.vue.js +1 -1
  118. package/dist/martyrs/src/modules/chats/components/blocks/ChatMessage.vue.js.map +1 -1
  119. package/dist/martyrs/src/modules/chats/components/sections/ChatWindow.vue.js +2 -2
  120. package/dist/martyrs/src/modules/chats/components/sections/ChatWindow.vue.js.map +1 -1
  121. package/dist/martyrs/src/modules/community/components/blocks/Activity.vue.js +7 -7
  122. package/dist/martyrs/src/modules/community/components/blocks/CardBlogpost.vue.js +1 -1
  123. package/dist/martyrs/src/modules/community/components/blocks/CardBlogpost.vue.js.map +1 -1
  124. package/dist/martyrs/src/modules/community/components/blocks/FooterBlogpost.vue.js +4 -4
  125. package/dist/martyrs/src/modules/community/components/blocks/FooterBlogpost.vue.js.map +1 -1
  126. package/dist/martyrs/src/modules/community/components/layouts/Community.vue.js +10 -10
  127. package/dist/martyrs/src/modules/community/components/layouts/Community.vue.js.map +1 -1
  128. package/dist/martyrs/src/modules/community/components/pages/BlogPost.vue.js +1 -1
  129. package/dist/martyrs/src/modules/community/components/pages/CreateBlogPost.vue.js +1 -1
  130. package/dist/martyrs/src/modules/community/components/pages/CreateBlogPost.vue.js.map +1 -1
  131. package/dist/martyrs/src/modules/community/components/pages/Posts.vue.js +2 -2
  132. package/dist/martyrs/src/modules/community/components/pages/Posts.vue.js.map +1 -1
  133. package/dist/martyrs/src/modules/community/components/sections/Comment.vue.js +3 -3
  134. package/dist/martyrs/src/modules/community/components/sections/Comment.vue.js.map +1 -1
  135. package/dist/martyrs/src/modules/community/components/sections/Comments.vue.js +1 -1
  136. package/dist/martyrs/src/modules/constructor/components/elements/Audio.vue.js +1 -1
  137. package/dist/martyrs/src/modules/constructor/components/elements/Audio.vue.js.map +1 -1
  138. package/dist/martyrs/src/modules/constructor/components/elements/Embed.vue.js +1 -1
  139. package/dist/martyrs/src/modules/constructor/components/elements/Embed.vue.js.map +1 -1
  140. package/dist/martyrs/src/modules/constructor/components/elements/Textarea.vue2.js +1 -1
  141. package/dist/martyrs/src/modules/constructor/components/elements/Textarea.vue2.js.map +1 -1
  142. package/dist/martyrs/src/modules/constructor/components/elements/Video.vue.js +1 -1
  143. package/dist/martyrs/src/modules/constructor/components/elements/Video.vue.js.map +1 -1
  144. package/dist/martyrs/src/modules/constructor/components/sections/Constructor.vue.js +1 -1
  145. package/dist/martyrs/src/modules/core/views/classes/core.app.js +2 -1
  146. package/dist/martyrs/src/modules/core/views/classes/core.app.js.map +1 -1
  147. package/dist/martyrs/src/modules/core/views/components/blocks/BlockSorting.vue.js +2 -2
  148. package/dist/martyrs/src/modules/core/views/components/blocks/BlockSorting.vue.js.map +1 -1
  149. package/dist/martyrs/src/modules/core/views/components/blocks/CardHeader.vue.js +9 -9
  150. package/dist/martyrs/src/modules/core/views/components/blocks/CardHeader.vue.js.map +1 -1
  151. package/dist/martyrs/src/modules/core/views/components/blocks/HelpCard.vue.js +2 -2
  152. package/dist/martyrs/src/modules/core/views/components/blocks/HelpCard.vue.js.map +1 -1
  153. package/dist/martyrs/src/modules/core/views/components/blocks/PopupAuth.vue.js +1 -1
  154. package/dist/martyrs/src/modules/core/views/components/blocks/PopupAuth.vue.js.map +1 -1
  155. package/dist/martyrs/src/modules/core/views/components/blocks/PopupDateSelector.vue.js +1 -1
  156. package/dist/martyrs/src/modules/core/views/components/elements/ButtonDate.vue.js +1 -1
  157. package/dist/martyrs/src/modules/core/views/components/elements/ButtonDate.vue.js.map +1 -1
  158. package/dist/martyrs/src/modules/core/views/components/elements/PhotoStack.vue.js +3 -3
  159. package/dist/martyrs/src/modules/core/views/components/layouts/App.vue.js +25 -5
  160. package/dist/martyrs/src/modules/core/views/components/layouts/App.vue.js.map +1 -1
  161. package/dist/martyrs/src/modules/core/views/components/layouts/Client.vue.js +4 -4
  162. package/dist/martyrs/src/modules/core/views/components/layouts/Client.vue.js.map +1 -1
  163. package/dist/martyrs/src/modules/core/views/components/partials/BottomNavigationBar.vue.js +11 -11
  164. package/dist/martyrs/src/modules/core/views/components/partials/BottomNavigationBar.vue.js.map +1 -1
  165. package/dist/martyrs/src/modules/core/views/components/partials/CitySelection.vue.js +1 -1
  166. package/dist/martyrs/src/modules/core/views/components/partials/CitySelection.vue.js.map +1 -1
  167. package/dist/martyrs/src/modules/core/views/components/partials/Footer.vue.js +16 -16
  168. package/dist/martyrs/src/modules/core/views/components/partials/Footer.vue.js.map +1 -1
  169. package/dist/martyrs/src/modules/core/views/components/partials/Header.vue.js +7 -7
  170. package/dist/martyrs/src/modules/core/views/components/partials/Header.vue.js.map +1 -1
  171. package/dist/martyrs/src/modules/core/views/components/partials/LocationSelection.vue.js +1 -1
  172. package/dist/martyrs/src/modules/core/views/components/partials/LocationSelection.vue.js.map +1 -1
  173. package/dist/martyrs/src/modules/core/views/components/partials/Navigation.vue.js +23 -23
  174. package/dist/martyrs/src/modules/core/views/components/partials/Navigation.vue.js.map +1 -1
  175. package/dist/martyrs/src/modules/core/views/components/partials/NavigationBar.vue.js +3 -3
  176. package/dist/martyrs/src/modules/core/views/components/partials/NavigationBar.vue.js.map +1 -1
  177. package/dist/martyrs/src/modules/core/views/components/partials/Sidebar.vue.js +7 -7
  178. package/dist/martyrs/src/modules/core/views/components/partials/Sidebar.vue.js.map +1 -1
  179. package/dist/martyrs/src/modules/core/views/components/sections/{Filters.vue.js → Filters.vue2.js} +2 -2
  180. package/dist/martyrs/src/modules/core/views/components/sections/Filters.vue2.js.map +1 -0
  181. package/dist/martyrs/src/modules/core/views/components/sections/SectionPageTitle.vue.js +2 -2
  182. package/dist/martyrs/src/modules/core/views/components/sections/SectionPageTitle.vue.js.map +1 -1
  183. package/dist/martyrs/src/modules/core/views/components/sections/Walkthrough.vue.js +1 -1
  184. package/dist/martyrs/src/modules/core/views/components/sections/filters/FilterCheckbox.vue2.js +2 -2
  185. package/dist/martyrs/src/modules/core/views/components/sections/filters/FilterCheckbox.vue2.js.map +1 -1
  186. package/dist/martyrs/src/modules/core/views/components/sections/filters/FilterDateRange.vue2.js +3 -3
  187. package/dist/martyrs/src/modules/core/views/components/sections/filters/FilterDateRange.vue2.js.map +1 -1
  188. package/dist/martyrs/src/modules/core/views/components/sections/filters/FilterRange.vue.js +2 -2
  189. package/dist/martyrs/src/modules/core/views/components/sections/filters/FilterRange.vue.js.map +1 -1
  190. package/dist/martyrs/src/modules/core/views/store/core.store.js +29 -47
  191. package/dist/martyrs/src/modules/core/views/store/core.store.js.map +1 -1
  192. package/dist/martyrs/src/modules/core/views/utils/vue-app-renderer.js +21 -2
  193. package/dist/martyrs/src/modules/core/views/utils/vue-app-renderer.js.map +1 -1
  194. package/dist/martyrs/src/modules/events/components/blocks/CardEvent.vue.js +5 -5
  195. package/dist/martyrs/src/modules/events/components/blocks/CardEvent.vue.js.map +1 -1
  196. package/dist/martyrs/src/modules/events/components/blocks/CardEventShort.vue.js +3 -3
  197. package/dist/martyrs/src/modules/events/components/blocks/CardEventShort.vue.js.map +1 -1
  198. package/dist/martyrs/src/modules/events/components/pages/EditEvent.vue.js +4 -4
  199. package/dist/martyrs/src/modules/events/components/pages/EditEvent.vue.js.map +1 -1
  200. package/dist/martyrs/src/modules/events/components/pages/EditEventTickets.vue.js +18 -18
  201. package/dist/martyrs/src/modules/events/components/pages/EditEventTickets.vue.js.map +1 -1
  202. package/dist/martyrs/src/modules/events/components/pages/Event.vue.js +7 -7
  203. package/dist/martyrs/src/modules/events/components/pages/Event.vue.js.map +1 -1
  204. package/dist/martyrs/src/modules/events/components/pages/Events.vue.js +2 -2
  205. package/dist/martyrs/src/modules/events/components/pages/Events.vue.js.map +1 -1
  206. package/dist/martyrs/src/modules/events/components/pages/EventsBackoffice.vue.js +2 -2
  207. package/dist/martyrs/src/modules/events/components/pages/EventsBackoffice.vue.js.map +1 -1
  208. package/dist/martyrs/src/modules/events/components/sections/EditTickets.vue.js +5 -5
  209. package/dist/martyrs/src/modules/events/components/sections/EditTickets.vue.js.map +1 -1
  210. package/dist/martyrs/src/modules/events/components/sections/EventsHot.vue.js +2 -2
  211. package/dist/martyrs/src/modules/events/components/sections/EventsHot.vue.js.map +1 -1
  212. package/dist/martyrs/src/modules/events/components/sections/Feed.vue.js +1 -1
  213. package/dist/martyrs/src/modules/events/components/sections/List.vue.js +2 -2
  214. package/dist/martyrs/src/modules/events/components/sections/List.vue.js.map +1 -1
  215. package/dist/martyrs/src/modules/events/components/sections/SelectDate.vue.js +1 -1
  216. package/dist/martyrs/src/modules/events/components/sections/SelectDate.vue.js.map +1 -1
  217. package/dist/martyrs/src/modules/gallery/components/pages/Gallery.vue.js +1 -1
  218. package/dist/martyrs/src/modules/gallery/components/pages/Gallery.vue.js.map +1 -1
  219. package/dist/martyrs/src/modules/gallery/components/sections/BackofficeGallery.vue.js +3 -3
  220. package/dist/martyrs/src/modules/gallery/components/sections/BackofficeGallery.vue.js.map +1 -1
  221. package/dist/martyrs/src/modules/icons/components/IconSearchPopup.vue.js +4 -4
  222. package/dist/martyrs/src/modules/icons/components/IconSearchPopup.vue.js.map +1 -1
  223. package/dist/martyrs/src/modules/icons/navigation/IconSort.vue.js +4 -4
  224. package/dist/martyrs/src/modules/icons/pages/IconsPage.vue.js +7 -7
  225. package/dist/martyrs/src/modules/icons/pages/IconsPage.vue.js.map +1 -1
  226. package/dist/martyrs/src/modules/inventory/components/forms/AdjustmentForm.vue.js +3 -3
  227. package/dist/martyrs/src/modules/inventory/components/forms/AdjustmentForm.vue.js.map +1 -1
  228. package/dist/martyrs/src/modules/inventory/components/forms/HistoryView.vue.js +2 -2
  229. package/dist/martyrs/src/modules/inventory/components/forms/HistoryView.vue.js.map +1 -1
  230. package/dist/martyrs/src/modules/inventory/components/forms/StockAlertsForm.vue.js +1 -1
  231. package/dist/martyrs/src/modules/inventory/components/forms/StockAlertsForm.vue.js.map +1 -1
  232. package/dist/martyrs/src/modules/inventory/components/pages/Inventory.vue.js +10 -10
  233. package/dist/martyrs/src/modules/inventory/components/pages/Inventory.vue.js.map +1 -1
  234. package/dist/martyrs/src/modules/inventory/components/pages/InventoryEdit.vue.js +5 -5
  235. package/dist/martyrs/src/modules/inventory/components/pages/InventoryEdit.vue.js.map +1 -1
  236. package/dist/martyrs/src/modules/landing/components/sections/SectionEarn.vue.js +5 -5
  237. package/dist/martyrs/src/modules/landing/components/sections/SectionEarn.vue.js.map +1 -1
  238. package/dist/martyrs/src/modules/landing/components/sections/SectionGuide.vue.js +2 -2
  239. package/dist/martyrs/src/modules/landing/components/sections/SectionGuide.vue.js.map +1 -1
  240. package/dist/martyrs/src/modules/landing/components/sections/SectionHeroToken.vue.js +1 -1
  241. package/dist/martyrs/src/modules/landing/components/sections/SectionHeroToken.vue.js.map +1 -1
  242. package/dist/martyrs/src/modules/landing/components/sections/SectionJoinUs.vue.js +2 -2
  243. package/dist/martyrs/src/modules/landing/components/sections/SectionJoinUs.vue.js.map +1 -1
  244. package/dist/martyrs/src/modules/landing/components/sections/SectionMobileApp.vue.js +3 -3
  245. package/dist/martyrs/src/modules/landing/components/sections/SectionMobileApp.vue.js.map +1 -1
  246. package/dist/martyrs/src/modules/landing/components/sections/SectionOverview.vue.js +2 -2
  247. package/dist/martyrs/src/modules/landing/components/sections/SectionOverview.vue.js.map +1 -1
  248. package/dist/martyrs/src/modules/landing/components/sections/SectionRoadmap.vue.js +3 -3
  249. package/dist/martyrs/src/modules/landing/components/sections/SectionRoadmap.vue.js.map +1 -1
  250. package/dist/martyrs/src/modules/marketplace/views/components/pages/Marketplace.vue.js +6 -6
  251. package/dist/martyrs/src/modules/marketplace/views/components/pages/Marketplace.vue.js.map +1 -1
  252. package/dist/martyrs/src/modules/marketplace/views/components/sections/SectionMenu.vue.js +4 -4
  253. package/dist/martyrs/src/modules/marketplace/views/components/sections/SectionMenu.vue.js.map +1 -1
  254. package/dist/martyrs/src/modules/music/components/blocks/ActionButtons.vue.js +2 -2
  255. package/dist/martyrs/src/modules/music/components/blocks/ActionButtons.vue.js.map +1 -1
  256. package/dist/martyrs/src/modules/music/components/cards/AlbumCard.vue.js +5 -5
  257. package/dist/martyrs/src/modules/music/components/cards/AlbumCard.vue.js.map +1 -1
  258. package/dist/martyrs/src/modules/music/components/cards/ArtistCard.vue.js +4 -4
  259. package/dist/martyrs/src/modules/music/components/cards/ArtistCard.vue.js.map +1 -1
  260. package/dist/martyrs/src/modules/music/components/cards/ArtistCardSmall.vue.js +3 -3
  261. package/dist/martyrs/src/modules/music/components/cards/ArtistCardSmall.vue.js.map +1 -1
  262. package/dist/martyrs/src/modules/music/components/cards/PlaylistCard.vue.js +5 -5
  263. package/dist/martyrs/src/modules/music/components/cards/PlaylistCard.vue.js.map +1 -1
  264. package/dist/martyrs/src/modules/music/components/cards/TrackListCard.vue.js +5 -5
  265. package/dist/martyrs/src/modules/music/components/cards/TrackListCard.vue.js.map +1 -1
  266. package/dist/martyrs/src/modules/music/components/forms/AlbumForm.vue.js +8 -8
  267. package/dist/martyrs/src/modules/music/components/forms/AlbumForm.vue.js.map +1 -1
  268. package/dist/martyrs/src/modules/music/components/forms/ArtistForm.vue.js +5 -5
  269. package/dist/martyrs/src/modules/music/components/forms/ArtistForm.vue.js.map +1 -1
  270. package/dist/martyrs/src/modules/music/components/forms/PlaylistForm.vue.js +7 -7
  271. package/dist/martyrs/src/modules/music/components/forms/PlaylistForm.vue.js.map +1 -1
  272. package/dist/martyrs/src/modules/music/components/forms/SearchForm.vue.js +2 -2
  273. package/dist/martyrs/src/modules/music/components/forms/SearchForm.vue.js.map +1 -1
  274. package/dist/martyrs/src/modules/music/components/forms/TrackForm.vue.js +13 -13
  275. package/dist/martyrs/src/modules/music/components/forms/TrackForm.vue.js.map +1 -1
  276. package/dist/martyrs/src/modules/music/components/pages/Album.vue.js +23 -23
  277. package/dist/martyrs/src/modules/music/components/pages/Album.vue.js.map +1 -1
  278. package/dist/martyrs/src/modules/music/components/pages/Artist.vue.js +8 -8
  279. package/dist/martyrs/src/modules/music/components/pages/Artist.vue.js.map +1 -1
  280. package/dist/martyrs/src/modules/music/components/pages/MusicHome.vue.js +10 -13
  281. package/dist/martyrs/src/modules/music/components/pages/MusicHome.vue.js.map +1 -1
  282. package/dist/martyrs/src/modules/music/components/pages/MusicLibrary.vue.js +9 -9
  283. package/dist/martyrs/src/modules/music/components/pages/MusicLibrary.vue.js.map +1 -1
  284. package/dist/martyrs/src/modules/music/components/pages/Playlist.vue.js +26 -26
  285. package/dist/martyrs/src/modules/music/components/pages/Playlist.vue.js.map +1 -1
  286. package/dist/martyrs/src/modules/music/components/pages/SearchResults.vue.js +17 -17
  287. package/dist/martyrs/src/modules/music/components/pages/SearchResults.vue.js.map +1 -1
  288. package/dist/martyrs/src/modules/music/components/pages/Track.vue.js +26 -26
  289. package/dist/martyrs/src/modules/music/components/pages/Track.vue.js.map +1 -1
  290. package/dist/martyrs/src/modules/music/components/pages/TrackCreate.vue.js +1 -1
  291. package/dist/martyrs/src/modules/music/components/player/FullscreenPlayer.vue.js +8 -8
  292. package/dist/martyrs/src/modules/music/components/player/FullscreenPlayer.vue.js.map +1 -1
  293. package/dist/martyrs/src/modules/music/music.client.js +6 -6
  294. package/dist/martyrs/src/modules/music/music.client.js.map +1 -1
  295. package/dist/martyrs/src/modules/notifications/components/blocks/NotificationItem.vue.js +2 -2
  296. package/dist/martyrs/src/modules/notifications/components/blocks/NotificationItem.vue.js.map +1 -1
  297. package/dist/martyrs/src/modules/notifications/components/elements/NotificationBadge.vue.js +1 -1
  298. package/dist/martyrs/src/modules/notifications/components/elements/NotificationBadge.vue.js.map +1 -1
  299. package/dist/martyrs/src/modules/notifications/notifications.client.js +2 -2
  300. package/dist/martyrs/src/modules/notifications/store/notifications.store.js +1 -1
  301. package/dist/martyrs/src/modules/orders/components/blocks/CardApplication.vue.js +2 -2
  302. package/dist/martyrs/src/modules/orders/components/blocks/CardCustomer.vue.js +2 -2
  303. package/dist/martyrs/src/modules/orders/components/blocks/CardOrder.vue.js +9 -9
  304. package/dist/martyrs/src/modules/orders/components/blocks/CardOrder.vue.js.map +1 -1
  305. package/dist/martyrs/src/modules/orders/components/blocks/CardOrderBackoffice.vue.js +5 -5
  306. package/dist/martyrs/src/modules/orders/components/blocks/CardOrderBackoffice.vue.js.map +1 -1
  307. package/dist/martyrs/src/modules/orders/components/blocks/CardOrderItem.vue.js +9 -9
  308. package/dist/martyrs/src/modules/orders/components/blocks/CardOrderItem.vue.js.map +1 -1
  309. package/dist/martyrs/src/modules/orders/components/blocks/CardOrderUser.vue.js +5 -5
  310. package/dist/martyrs/src/modules/orders/components/blocks/CardOrderUser.vue.js.map +1 -1
  311. package/dist/martyrs/src/modules/orders/components/blocks/StatusHistory.vue.js +2 -2
  312. package/dist/martyrs/src/modules/orders/components/blocks/StatusHistory.vue.js.map +1 -1
  313. package/dist/martyrs/src/modules/orders/components/elements/FieldSubscribeNewsletter.vue.js +1 -1
  314. package/dist/martyrs/src/modules/orders/components/elements/FieldSubscribeNewsletter.vue.js.map +1 -1
  315. package/dist/martyrs/src/modules/orders/components/elements/PriceTotal.vue.js +3 -3
  316. package/dist/martyrs/src/modules/orders/components/elements/PriceTotal.vue.js.map +1 -1
  317. package/dist/martyrs/src/modules/orders/components/forms/FormApplicationDetails.vue.js +2 -2
  318. package/dist/martyrs/src/modules/orders/components/forms/FormApplicationDetails.vue.js.map +1 -1
  319. package/dist/martyrs/src/modules/orders/components/forms/FormCustomerDetails.vue.js +3 -3
  320. package/dist/martyrs/src/modules/orders/components/forms/FormCustomerDetails.vue.js.map +1 -1
  321. package/dist/martyrs/src/modules/orders/components/forms/FormSelectCustomer.vue.js +1 -1
  322. package/dist/martyrs/src/modules/orders/components/pages/OrderBackoffice.vue.js +17 -17
  323. package/dist/martyrs/src/modules/orders/components/pages/OrderBackoffice.vue.js.map +1 -1
  324. package/dist/martyrs/src/modules/orders/components/pages/OrderCreate.vue.js +2 -2
  325. package/dist/martyrs/src/modules/orders/components/pages/OrderCreate.vue.js.map +1 -1
  326. package/dist/martyrs/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js +4 -4
  327. package/dist/martyrs/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js.map +1 -1
  328. package/dist/martyrs/src/modules/orders/components/partials/ShopCart.vue.js +2 -2
  329. package/dist/martyrs/src/modules/orders/components/partials/ShopCart.vue.js.map +1 -1
  330. package/dist/martyrs/src/modules/orders/components/sections/ApplicationDetails.vue.js +3 -3
  331. package/dist/martyrs/src/modules/orders/components/sections/ApplicationDetails.vue.js.map +1 -1
  332. package/dist/martyrs/src/modules/orders/components/sections/AskToLogin.vue.js +1 -1
  333. package/dist/martyrs/src/modules/orders/components/sections/AskToLogin.vue.js.map +1 -1
  334. package/dist/martyrs/src/modules/orders/components/sections/CustomerDetails.vue.js +3 -3
  335. package/dist/martyrs/src/modules/orders/components/sections/CustomerDetails.vue.js.map +1 -1
  336. package/dist/martyrs/src/modules/orders/components/sections/FormDelivery.vue.js +2 -2
  337. package/dist/martyrs/src/modules/orders/components/sections/Succes.vue.js +3 -3
  338. package/dist/martyrs/src/modules/orders/store/shopcart.js +1 -1
  339. package/dist/martyrs/src/modules/organizations/components/blocks/CardDepartment.vue.js +2 -2
  340. package/dist/martyrs/src/modules/organizations/components/blocks/CardOrganization.vue.js +3 -3
  341. package/dist/martyrs/src/modules/organizations/components/blocks/CardOrganization.vue.js.map +1 -1
  342. package/dist/martyrs/src/modules/organizations/components/blocks/Contacts.vue.js +8 -8
  343. package/dist/martyrs/src/modules/organizations/components/blocks/Contacts.vue.js.map +1 -1
  344. package/dist/martyrs/src/modules/organizations/components/blocks/Rating.vue.js +1 -1
  345. package/dist/martyrs/src/modules/organizations/components/forms/AddExistingMembersForm.vue.js +3 -3
  346. package/dist/martyrs/src/modules/organizations/components/forms/AddExistingMembersForm.vue.js.map +1 -1
  347. package/dist/martyrs/src/modules/organizations/components/forms/DepartmentForm.vue.js +1 -1
  348. package/dist/martyrs/src/modules/organizations/components/forms/DepartmentForm.vue.js.map +1 -1
  349. package/dist/martyrs/src/modules/organizations/components/forms/InviteForm.vue.js +1 -1
  350. package/dist/martyrs/src/modules/organizations/components/forms/InviteForm.vue.js.map +1 -1
  351. package/dist/martyrs/src/modules/organizations/components/pages/Department.vue.js +2 -2
  352. package/dist/martyrs/src/modules/organizations/components/pages/Department.vue.js.map +1 -1
  353. package/dist/martyrs/src/modules/organizations/components/pages/Members.vue.js +1 -1
  354. package/dist/martyrs/src/modules/organizations/components/pages/Members.vue.js.map +1 -1
  355. package/dist/martyrs/src/modules/organizations/components/pages/Organization.vue.js +6 -6
  356. package/dist/martyrs/src/modules/organizations/components/pages/Organization.vue.js.map +1 -1
  357. package/dist/martyrs/src/modules/organizations/components/pages/OrganizationBackoffice.vue.js +2 -2
  358. package/dist/martyrs/src/modules/organizations/components/pages/OrganizationEdit.vue.js +1 -1
  359. package/dist/martyrs/src/modules/organizations/components/pages/Organizations.vue.js +2 -2
  360. package/dist/martyrs/src/modules/organizations/components/pages/Organizations.vue.js.map +1 -1
  361. package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.js +4 -4
  362. package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.js.map +1 -1
  363. package/dist/martyrs/src/modules/organizations/components/sections/MembersAdd.vue.js +1 -1
  364. package/dist/martyrs/src/modules/organizations/components/sections/MembersAdd.vue.js.map +1 -1
  365. package/dist/martyrs/src/modules/organizations/components/sections/Organizations.vue.js +1 -1
  366. package/dist/martyrs/src/modules/pages/views/components/blocks/CardPage.vue.js +3 -3
  367. package/dist/martyrs/src/modules/pages/views/components/blocks/CardPage.vue.js.map +1 -1
  368. package/dist/martyrs/src/modules/pages/views/components/pages/Page.vue.js +5 -5
  369. package/dist/martyrs/src/modules/pages/views/components/pages/Page.vue.js.map +1 -1
  370. package/dist/martyrs/src/modules/pages/views/components/pages/PageEdit.vue.js +1 -1
  371. package/dist/martyrs/src/modules/products/components/blocks/CardCategory.vue.js +1 -1
  372. package/dist/martyrs/src/modules/products/components/blocks/CardCategory.vue.js.map +1 -1
  373. package/dist/martyrs/src/modules/products/components/blocks/CardPosition.vue.js +4 -4
  374. package/dist/martyrs/src/modules/products/components/blocks/CardPosition.vue.js.map +1 -1
  375. package/dist/martyrs/src/modules/products/components/blocks/CardProduct.vue.js +3 -3
  376. package/dist/martyrs/src/modules/products/components/blocks/CardProduct.vue.js.map +1 -1
  377. package/dist/martyrs/src/modules/products/components/blocks/ProductDiscounts.vue.js +5 -5
  378. package/dist/martyrs/src/modules/products/components/blocks/ProductDiscounts.vue.js.map +1 -1
  379. package/dist/martyrs/src/modules/products/components/blocks/ProductImages.vue.js +3 -3
  380. package/dist/martyrs/src/modules/products/components/blocks/ProductImages.vue.js.map +1 -1
  381. package/dist/martyrs/src/modules/products/components/blocks/ProductVariants.vue.js +2 -2
  382. package/dist/martyrs/src/modules/products/components/blocks/ProductVariants.vue.js.map +1 -1
  383. package/dist/martyrs/src/modules/products/components/elements/Image360.vue.js +5 -5
  384. package/dist/martyrs/src/modules/products/components/elements/Image360.vue.js.map +1 -1
  385. package/dist/martyrs/src/modules/products/components/elements/Price.vue.js +2 -2
  386. package/dist/martyrs/src/modules/products/components/elements/Price.vue.js.map +1 -1
  387. package/dist/martyrs/src/modules/products/components/elements/QuantitySelector.vue.js +3 -3
  388. package/dist/martyrs/src/modules/products/components/elements/QuantitySelector.vue.js.map +1 -1
  389. package/dist/martyrs/src/modules/products/components/elements/THC.vue.js +1 -1
  390. package/dist/martyrs/src/modules/products/components/pages/Categories.vue.js +2 -2
  391. package/dist/martyrs/src/modules/products/components/pages/Categories.vue.js.map +1 -1
  392. package/dist/martyrs/src/modules/products/components/pages/CategoryEdit.vue.js +3 -3
  393. package/dist/martyrs/src/modules/products/components/pages/CategoryEdit.vue.js.map +1 -1
  394. package/dist/martyrs/src/modules/products/components/pages/Product.vue.js +7 -7
  395. package/dist/martyrs/src/modules/products/components/pages/Product.vue.js.map +1 -1
  396. package/dist/martyrs/src/modules/products/components/pages/ProductEdit.vue.js +8 -8
  397. package/dist/martyrs/src/modules/products/components/pages/ProductEdit.vue.js.map +1 -1
  398. package/dist/martyrs/src/modules/products/components/pages/Products.vue.js +12 -12
  399. package/dist/martyrs/src/modules/products/components/pages/Products.vue.js.map +1 -1
  400. package/dist/martyrs/src/modules/products/components/sections/EditAttributes.vue.js +4 -4
  401. package/dist/martyrs/src/modules/products/components/sections/EditAttributes.vue.js.map +1 -1
  402. package/dist/martyrs/src/modules/products/components/sections/EditDiscounts.vue.js +6 -6
  403. package/dist/martyrs/src/modules/products/components/sections/EditDiscounts.vue.js.map +1 -1
  404. package/dist/martyrs/src/modules/products/components/sections/EditRecommended.vue.js +1 -1
  405. package/dist/martyrs/src/modules/products/components/sections/EditRecommended.vue.js.map +1 -1
  406. package/dist/martyrs/src/modules/products/components/sections/EditVariants.vue.js +9 -9
  407. package/dist/martyrs/src/modules/products/components/sections/EditVariants.vue.js.map +1 -1
  408. package/dist/martyrs/src/modules/products/components/sections/FilterProducts.vue.js +3 -3
  409. package/dist/martyrs/src/modules/products/components/sections/FilterProducts.vue.js.map +1 -1
  410. package/dist/martyrs/src/modules/products/components/sections/ProductConfigurator.vue.js +2 -2
  411. package/dist/martyrs/src/modules/products/components/sections/ProductConfigurator.vue.js.map +1 -1
  412. package/dist/martyrs/src/modules/products/components/sections/ProductsRecommended.vue.js +2 -2
  413. package/dist/martyrs/src/modules/products/components/sections/ProductsRecommended.vue.js.map +1 -1
  414. package/dist/martyrs/src/modules/products/components/sections/SectionProduct.vue.js +6 -6
  415. package/dist/martyrs/src/modules/products/components/sections/SectionProduct.vue.js.map +1 -1
  416. package/dist/martyrs/src/modules/rents/views/components/blocks/CardRent.vue.js +1 -1
  417. package/dist/martyrs/src/modules/rents/views/components/blocks/CardRent.vue.js.map +1 -1
  418. package/dist/martyrs/src/modules/rents/views/components/pages/Gant/DateLabel.vue.js +1 -1
  419. package/dist/martyrs/src/modules/rents/views/components/pages/Gant/GanttBar.vue.js +2 -2
  420. package/dist/martyrs/src/modules/rents/views/components/pages/Gant/GanttBar.vue.js.map +1 -1
  421. package/dist/martyrs/src/modules/rents/views/components/pages/Gant/GanttChart.vue.js +8 -8
  422. package/dist/martyrs/src/modules/rents/views/components/pages/Gant/GanttChart.vue.js.map +1 -1
  423. package/dist/martyrs/src/modules/rents/views/components/pages/Gant/GanttHeaderCell.vue.js +1 -1
  424. package/dist/martyrs/src/modules/rents/views/components/pages/Gant/GanttHeaderCell.vue.js.map +1 -1
  425. package/dist/martyrs/src/modules/rents/views/components/pages/Rents.vue.js +1 -1
  426. package/dist/martyrs/src/modules/rents/views/components/pages/Rents.vue.js.map +1 -1
  427. package/dist/martyrs/src/modules/rents/views/components/pages/RentsEdit.vue.js +6 -6
  428. package/dist/martyrs/src/modules/rents/views/components/pages/RentsEdit.vue.js.map +1 -1
  429. package/dist/martyrs/src/modules/reports/components/pages/BackofficeReports.vue.js +3 -3
  430. package/dist/martyrs/src/modules/reports/components/pages/BackofficeReports.vue.js.map +1 -1
  431. package/dist/martyrs/src/modules/reports/components/sections/FormReport.vue.js +1 -1
  432. package/dist/martyrs/src/modules/reports/components/sections/FormReport.vue.js.map +1 -1
  433. package/dist/martyrs/src/modules/spots/components/blocks/CardSpot.vue.js +5 -5
  434. package/dist/martyrs/src/modules/spots/components/blocks/CardSpot.vue.js.map +1 -1
  435. package/dist/martyrs/src/modules/spots/components/blocks/SpotMemberModify.vue.js +2 -2
  436. package/dist/martyrs/src/modules/spots/components/blocks/SpotMemberModify.vue.js.map +1 -1
  437. package/dist/martyrs/src/modules/spots/components/layouts/Spots.vue.js +2 -2
  438. package/dist/martyrs/src/modules/spots/components/layouts/Spots.vue.js.map +1 -1
  439. package/dist/martyrs/src/modules/spots/components/pages/Spot.vue.js +6 -6
  440. package/dist/martyrs/src/modules/spots/components/pages/Spot.vue.js.map +1 -1
  441. package/dist/martyrs/src/modules/spots/components/pages/SpotEdit.vue.js +2 -2
  442. package/dist/martyrs/src/modules/spots/components/pages/SpotEdit.vue.js.map +1 -1
  443. package/dist/martyrs/src/modules/spots/components/pages/Spots.vue.js +3 -3
  444. package/dist/martyrs/src/modules/spots/components/pages/Spots.vue.js.map +1 -1
  445. package/dist/martyrs/src/modules/spots/components/sections/WorktimeEdit.vue.js +5 -5
  446. package/dist/martyrs/src/modules/spots/components/sections/WorktimeEdit.vue.js.map +1 -1
  447. package/dist/martyrs/src/modules/wallet/views/components/blocks/CardBalanceReplenished.vue.js +5 -5
  448. package/dist/martyrs/src/modules/wallet/views/components/blocks/CardBalanceReplenished.vue.js.map +1 -1
  449. package/dist/martyrs/src/modules/wallet/views/components/blocks/CardDeposit.vue.js +5 -5
  450. package/dist/martyrs/src/modules/wallet/views/components/blocks/CardDeposit.vue.js.map +1 -1
  451. package/dist/martyrs/src/modules/wallet/views/components/blocks/CashDeposit.vue.js +2 -2
  452. package/dist/martyrs/src/modules/wallet/views/components/blocks/CashDeposit.vue.js.map +1 -1
  453. package/dist/martyrs/src/modules/wallet/views/components/blocks/CryptoDeposit.vue.js +4 -4
  454. package/dist/martyrs/src/modules/wallet/views/components/blocks/CryptoDeposit.vue.js.map +1 -1
  455. package/dist/martyrs/src/modules/wallet/views/components/blocks/CryptoDepositProcessing.vue.js +12 -12
  456. package/dist/martyrs/src/modules/wallet/views/components/blocks/CryptoDepositProcessing.vue.js.map +1 -1
  457. package/dist/martyrs/src/modules/wallet/views/components/elements/ConnectMetamask.vue.js +4 -4
  458. package/dist/martyrs/src/modules/wallet/views/components/elements/ConnectMetamask.vue.js.map +1 -1
  459. package/dist/martyrs/src/modules/wallet/views/components/pages/Wallet.vue.js +23 -23
  460. package/dist/martyrs/src/modules/wallet/views/components/pages/Wallet.vue.js.map +1 -1
  461. package/dist/martyrs.css +1 -1
  462. package/dist/martyrs.es.js +1 -1
  463. package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/utils.js +1 -1
  464. package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/renderer/utils.js +1 -1
  465. package/dist/style.css +194 -202
  466. package/dist/{web-CH5wzMHy.js → web-BqTV9va1.js} +1 -1
  467. package/package.json +6 -8
  468. package/src/builder/modes/ssr.prod.js +1 -0
  469. package/src/builder/modes/ssr.rspack.dev.js +13 -6
  470. package/src/builder/rspack/rspack.config.base.js +7 -0
  471. package/src/builder/rspack/rspack.config.ssr.client.js +19 -44
  472. package/src/builder/templates/page.js +21 -0
  473. package/src/components/Block/Block.vue +1 -1
  474. package/src/components/BottomSheet/BottomSheet.vue +1 -1
  475. package/src/components/Calendar/Calendar.vue +5 -5
  476. package/src/components/Checkbox/Checkbox.vue +2 -2
  477. package/src/components/Chips/Chips.vue +2 -2
  478. package/src/components/Completion/Completion.vue +2 -2
  479. package/src/components/Countdown/Countdown.vue +5 -5
  480. package/src/components/DatePicker/DatePicker.vue +4 -4
  481. package/src/components/EditImages/EditImages.vue +1 -1
  482. package/src/components/Feed/Feed.old.vue +1 -1
  483. package/src/components/Feed/Feed.vue +1 -1
  484. package/src/components/FieldBig/FieldBig.vue +2 -2
  485. package/src/components/FieldPhone/FieldPhone.vue +1 -1
  486. package/src/components/FieldTags/BlockTags.vue +1 -1
  487. package/src/components/Loader/Loader.vue +1 -1
  488. package/src/components/Menu/MenuItem.vue +2 -2
  489. package/src/components/PhotoViewer/PhotoViewer.vue +1 -1
  490. package/src/components/Radio/Radio.vue +1 -1
  491. package/src/components/Select/Select.vue +1 -1
  492. package/src/components/Table/Table.vue +2 -2
  493. package/src/components/Text/Text.vue +1 -1
  494. package/src/components/UploadImage/UploadImage.vue +2 -2
  495. package/src/components/UploadImageMultiple/UploadImageMultiple.vue +3 -3
  496. package/src/configurator/components/layouts/layoutConfigurator.vue +1 -1
  497. package/src/configurator/components/pages/Styles.vue +2 -2
  498. package/src/jit/.claude/settings.local.json +10 -0
  499. package/src/jit/CLAUDE.md +387 -0
  500. package/src/jit/core.js +274 -0
  501. package/src/jit/extractor.js +140 -0
  502. package/src/jit/index.js +19 -0
  503. package/src/jit/loader.js +46 -0
  504. package/src/jit/plugin.js +209 -0
  505. package/src/jit/rules.js +474 -0
  506. package/src/jit/variants.js +128 -0
  507. package/src/modules/auth/views/components/blocks/CardUser.vue +2 -2
  508. package/src/modules/auth/views/components/blocks/ProfileCard.vue +4 -4
  509. package/src/modules/auth/views/components/layouts/Auth.vue +1 -1
  510. package/src/modules/auth/views/components/pages/EnterPassword.vue +2 -2
  511. package/src/modules/auth/views/components/pages/Profile.vue +5 -5
  512. package/src/modules/auth/views/components/pages/ProfileBlogposts.vue +1 -1
  513. package/src/modules/auth/views/components/pages/ProfileEditAccount.vue +2 -2
  514. package/src/modules/auth/views/components/pages/ResetPassword.vue +1 -1
  515. package/src/modules/auth/views/components/pages/SignIn.vue +3 -3
  516. package/src/modules/auth/views/components/pages/SignUp.vue +1 -1
  517. package/src/modules/auth/views/components/pages/UserDashboard.vue +3 -3
  518. package/src/modules/auth/views/components/sections/FeaturedUsers.vue +1 -1
  519. package/src/modules/auth/views/components/sections/ProfileCompletion.vue +2 -2
  520. package/src/modules/auth/views/components/sections/ProfileEditCredentials.vue +7 -7
  521. package/src/modules/auth/views/components/sections/SliderFeatures.vue +1 -1
  522. package/src/modules/backoffice/components/admin/Backcalls.vue +1 -1
  523. package/src/modules/backoffice/components/admin/FastOrders.vue +1 -1
  524. package/src/modules/backoffice/components/admin/ProductEdit.vue +2 -2
  525. package/src/modules/backoffice/components/admin/UserEdit.vue +1 -1
  526. package/src/modules/backoffice/components/admin/Users.vue +2 -2
  527. package/src/modules/backoffice/components/pages/Dashboard.vue +4 -4
  528. package/src/modules/backoffice/components/partials/Sidebar.vue +5 -5
  529. package/src/modules/chats/components/blocks/ChatMessage.vue +1 -1
  530. package/src/modules/chats/components/sections/ChatWindow.vue +2 -2
  531. package/src/modules/community/components/blocks/Activity.vue +7 -7
  532. package/src/modules/community/components/blocks/CardBlogpost.vue +1 -1
  533. package/src/modules/community/components/blocks/FooterBlogpost.vue +4 -4
  534. package/src/modules/community/components/layouts/Community.vue +10 -10
  535. package/src/modules/community/components/pages/CreateBlogPost.vue +1 -1
  536. package/src/modules/community/components/pages/Posts.vue +2 -2
  537. package/src/modules/community/components/sections/Comment.vue +2 -2
  538. package/src/modules/constructor/components/elements/Audio.vue +1 -1
  539. package/src/modules/constructor/components/elements/Caption.vue +1 -1
  540. package/src/modules/constructor/components/elements/Embed.vue +1 -1
  541. package/src/modules/constructor/components/elements/Textarea.vue +1 -1
  542. package/src/modules/constructor/components/elements/Video.vue +1 -1
  543. package/src/modules/core/views/classes/core.app.js +2 -1
  544. package/src/modules/core/views/components/blocks/BlockSorting.vue +2 -2
  545. package/src/modules/core/views/components/blocks/CardFooter.vue +4 -4
  546. package/src/modules/core/views/components/blocks/CardHeader.vue +7 -7
  547. package/src/modules/core/views/components/blocks/HelpCard.vue +1 -1
  548. package/src/modules/core/views/components/blocks/PopupAuth.vue +1 -1
  549. package/src/modules/core/views/components/elements/ButtonDate.vue +1 -1
  550. package/src/modules/core/views/components/elements/PhotoStack.vue +3 -3
  551. package/src/modules/core/views/components/layouts/App.vue +28 -4
  552. package/src/modules/core/views/components/layouts/Client.vue +4 -4
  553. package/src/modules/core/views/components/partials/BottomNavigationBar.vue +15 -15
  554. package/src/modules/core/views/components/partials/CitySelection.vue +1 -1
  555. package/src/modules/core/views/components/partials/Footer.centered.vue +17 -17
  556. package/src/modules/core/views/components/partials/Footer.vue +18 -18
  557. package/src/modules/core/views/components/partials/Header.vue +10 -11
  558. package/src/modules/core/views/components/partials/LocationSelection.vue +1 -1
  559. package/src/modules/core/views/components/partials/Navigation.vue +20 -19
  560. package/src/modules/core/views/components/partials/NavigationBar.vue +3 -3
  561. package/src/modules/core/views/components/partials/Sidebar.vue +6 -6
  562. package/src/modules/core/views/components/sections/SectionPageTitle.vue +2 -2
  563. package/src/modules/core/views/components/sections/filters/FilterCheckbox.vue +1 -1
  564. package/src/modules/core/views/components/sections/filters/FilterDateRange.vue +2 -2
  565. package/src/modules/core/views/components/sections/filters/FilterPrice.vue +2 -2
  566. package/src/modules/core/views/components/sections/filters/FilterRange.vue +2 -2
  567. package/src/modules/core/views/store/core.store.js +36 -60
  568. package/src/modules/core/views/utils/vue-app-renderer.js +31 -1
  569. package/src/modules/events/components/blocks/CardEvent.vue +6 -6
  570. package/src/modules/events/components/blocks/CardEventShort.vue +3 -3
  571. package/src/modules/events/components/pages/EditEvent.vue +1 -1
  572. package/src/modules/events/components/pages/EditEventTickets.vue +18 -18
  573. package/src/modules/events/components/pages/Event.vue +5 -5
  574. package/src/modules/events/components/pages/Events.vue +2 -2
  575. package/src/modules/events/components/pages/EventsBackoffice.vue +2 -2
  576. package/src/modules/events/components/sections/EditTickets.vue +5 -5
  577. package/src/modules/events/components/sections/EventsHot.vue +2 -2
  578. package/src/modules/events/components/sections/List.vue +1 -1
  579. package/src/modules/events/components/sections/SelectDate.vue +1 -1
  580. package/src/modules/gallery/components/pages/Gallery.vue +1 -1
  581. package/src/modules/gallery/components/sections/BackofficeGallery.vue +1 -1
  582. package/src/modules/governance/reactcode/src/components/CreateInitiativeForm.tsx +14 -14
  583. package/src/modules/governance/reactcode/src/components/CreateMilestoneForm.tsx +13 -13
  584. package/src/modules/governance/reactcode/src/components/EmptyState.tsx +2 -2
  585. package/src/modules/governance/reactcode/src/components/InitiativeCard.tsx +1 -1
  586. package/src/modules/governance/reactcode/src/components/LinkedEntityCard.tsx +1 -1
  587. package/src/modules/governance/reactcode/src/components/MilestoneCard.tsx +2 -2
  588. package/src/modules/governance/reactcode/src/components/ProductRepositories.tsx +6 -6
  589. package/src/modules/governance/reactcode/src/components/ProductSummary.tsx +18 -18
  590. package/src/modules/governance/reactcode/src/components/ProductTeam.tsx +7 -7
  591. package/src/modules/governance/reactcode/src/components/ProposeTaskForm.tsx +9 -9
  592. package/src/modules/governance/reactcode/src/components/TaskAssignForm.tsx +4 -4
  593. package/src/modules/governance/reactcode/src/components/TaskCard.tsx +1 -1
  594. package/src/modules/governance/reactcode/src/components/TaskStatusBadge.tsx +1 -1
  595. package/src/modules/governance/reactcode/src/components/VoteForm.tsx +6 -6
  596. package/src/modules/governance/reactcode/src/components/VotingCard.tsx +2 -2
  597. package/src/modules/governance/reactcode/src/components/VotingResults.tsx +15 -15
  598. package/src/modules/governance/reactcode/src/pages/InitiativeDetailPage.tsx +41 -41
  599. package/src/modules/governance/reactcode/src/pages/InitiativeMilestonesPage.tsx +8 -8
  600. package/src/modules/governance/reactcode/src/pages/InitiativesListPage.tsx +6 -6
  601. package/src/modules/governance/reactcode/src/pages/MilestoneDetailPage.tsx +9 -9
  602. package/src/modules/governance/reactcode/src/pages/RoadmapPage.tsx +14 -14
  603. package/src/modules/governance/reactcode/src/pages/TaskDetailPage.tsx +44 -44
  604. package/src/modules/governance/reactcode/src/pages/VotingDetailPage.tsx +8 -8
  605. package/src/modules/governance/reactcode/src/pages/VotingsListPage.tsx +3 -3
  606. package/src/modules/governance/reactcode-2/App.tsx +28 -0
  607. package/src/modules/governance/reactcode-2/README.md +20 -0
  608. package/src/modules/governance/reactcode-2/components/Charts.tsx +58 -0
  609. package/src/modules/governance/reactcode-2/components/Layout.tsx +457 -0
  610. package/src/modules/governance/reactcode-2/components/TaskPage.tsx +325 -0
  611. package/src/modules/governance/reactcode-2/components/VoteBadge.tsx +27 -0
  612. package/src/modules/governance/reactcode-2/components/VotingsFeedPage.tsx +328 -0
  613. package/src/modules/governance/reactcode-2/constants.ts +154 -0
  614. package/src/modules/governance/reactcode-2/index.html +70 -0
  615. package/src/modules/governance/reactcode-2/index.tsx +15 -0
  616. package/src/modules/governance/reactcode-2/metadata.json +5 -0
  617. package/src/modules/governance/reactcode-2/package.json +23 -0
  618. package/src/modules/governance/reactcode-2/pnpm-lock.yaml +1410 -0
  619. package/src/modules/governance/reactcode-2/tsconfig.json +29 -0
  620. package/src/modules/governance/reactcode-2/types.ts +48 -0
  621. package/src/modules/governance/reactcode-2/vite.config.ts +23 -0
  622. package/src/modules/governance/views/components/blocks/CardInitiativeItem.vue +10 -10
  623. package/src/modules/governance/views/components/blocks/CardMilestoneItem.vue +15 -15
  624. package/src/modules/governance/views/components/blocks/CardTaskItem.vue +9 -9
  625. package/src/modules/governance/views/components/blocks/CardVotingItem.vue +11 -11
  626. package/src/modules/governance/views/components/layouts/Governance.vue +1 -1
  627. package/src/modules/governance/views/components/pages/Governance.vue +3 -3
  628. package/src/modules/governance/views/components/pages/Initiative.vue +112 -112
  629. package/src/modules/governance/views/components/pages/InitiativeMilestones.vue +31 -31
  630. package/src/modules/governance/views/components/pages/Initiatives.vue +20 -22
  631. package/src/modules/governance/views/components/pages/Milestone.vue +25 -25
  632. package/src/modules/governance/views/components/pages/Roadmap.vue +47 -47
  633. package/src/modules/governance/views/components/pages/Task.vue +106 -106
  634. package/src/modules/governance/views/components/pages/Tasks.vue +16 -16
  635. package/src/modules/governance/views/components/pages/Voting.vue +23 -23
  636. package/src/modules/governance/views/components/pages/Votings.vue +7 -7
  637. package/src/modules/governance/views/components/partials/EmptyState.vue +3 -3
  638. package/src/modules/governance/views/components/partials/LinkedEntityCard.vue +11 -11
  639. package/src/modules/governance/views/components/partials/TaskStatusBadge.vue +4 -4
  640. package/src/modules/governance/views/components/partials/VoteForm.vue +14 -14
  641. package/src/modules/governance/views/components/partials/VotingResults.vue +22 -22
  642. package/src/modules/icons/components/IconSearchPopup.vue +3 -3
  643. package/src/modules/icons/entities/IconCash.vue +23 -0
  644. package/src/modules/icons/navigation/IconSort.vue +4 -4
  645. package/src/modules/icons/pages/IconsPage.vue +7 -7
  646. package/src/modules/inventory/components/forms/AdjustmentForm.vue +3 -3
  647. package/src/modules/inventory/components/forms/HistoryView.vue +1 -1
  648. package/src/modules/inventory/components/forms/StockAlertsForm.vue +1 -1
  649. package/src/modules/inventory/components/pages/Inventory.vue +10 -10
  650. package/src/modules/inventory/components/pages/InventoryEdit.vue +6 -6
  651. package/src/modules/landing/components/blocks/MapBlock.vue +2 -2
  652. package/src/modules/landing/components/sections/Examples.vue +1 -1
  653. package/src/modules/landing/components/sections/InstagramSection.vue +1 -1
  654. package/src/modules/landing/components/sections/SectionEarn.vue +4 -4
  655. package/src/modules/landing/components/sections/SectionFeature.vue +1 -1
  656. package/src/modules/landing/components/sections/SectionFocus.vue +2 -2
  657. package/src/modules/landing/components/sections/SectionGuide.vue +2 -2
  658. package/src/modules/landing/components/sections/SectionHeroToken.vue +1 -1
  659. package/src/modules/landing/components/sections/SectionHeroVideo.vue +2 -2
  660. package/src/modules/landing/components/sections/SectionJoinUs.vue +2 -2
  661. package/src/modules/landing/components/sections/SectionMobileApp.vue +3 -3
  662. package/src/modules/landing/components/sections/SectionOverview.vue +2 -2
  663. package/src/modules/landing/components/sections/SectionRoadmap.vue +2 -2
  664. package/src/modules/marketplace/views/components/layouts/Marketplace.vue +8 -8
  665. package/src/modules/marketplace/views/components/pages/Marketplace.vue +5 -5
  666. package/src/modules/marketplace/views/components/sections/SectionMenu.vue +2 -2
  667. package/src/modules/music/components/SidebarMusic.vue +11 -11
  668. package/src/modules/music/components/blocks/ActionButtons.vue +2 -2
  669. package/src/modules/music/components/cards/AlbumCard.vue +4 -4
  670. package/src/modules/music/components/cards/ArtistCard.vue +3 -8
  671. package/src/modules/music/components/cards/ArtistCardSmall.vue +2 -2
  672. package/src/modules/music/components/cards/PlaylistCard.vue +4 -4
  673. package/src/modules/music/components/cards/TrackListCard.vue +5 -5
  674. package/src/modules/music/components/forms/AlbumForm.vue +8 -8
  675. package/src/modules/music/components/forms/ArtistForm.vue +4 -4
  676. package/src/modules/music/components/forms/PlaylistForm.vue +7 -7
  677. package/src/modules/music/components/forms/SearchForm.vue +1 -1
  678. package/src/modules/music/components/forms/TrackForm.vue +13 -13
  679. package/src/modules/music/components/pages/Album.vue +22 -22
  680. package/src/modules/music/components/pages/Artist.vue +7 -7
  681. package/src/modules/music/components/pages/MusicHome.vue +13 -18
  682. package/src/modules/music/components/pages/MusicLibrary.vue +9 -9
  683. package/src/modules/music/components/pages/Playlist.vue +25 -25
  684. package/src/modules/music/components/pages/SearchResults.vue +15 -15
  685. package/src/modules/music/components/pages/Track.vue +25 -25
  686. package/src/modules/music/components/player/FullscreenPlayer.vue +5 -5
  687. package/src/modules/notifications/components/blocks/NotificationItem.vue +1 -1
  688. package/src/modules/notifications/components/elements/NotificationBadge.vue +1 -1
  689. package/src/modules/orders/components/blocks/CardApplication.vue +1 -1
  690. package/src/modules/orders/components/blocks/CardCustomer.vue +1 -1
  691. package/src/modules/orders/components/blocks/CardOrder.vue +9 -9
  692. package/src/modules/orders/components/blocks/CardOrderBackoffice.vue +5 -5
  693. package/src/modules/orders/components/blocks/CardOrderItem.vue +9 -9
  694. package/src/modules/orders/components/blocks/CardOrderUser.vue +3 -3
  695. package/src/modules/orders/components/blocks/CardOrderVar1.vue +4 -4
  696. package/src/modules/orders/components/blocks/StatusHistory.vue +3 -3
  697. package/src/modules/orders/components/elements/FieldSubscribeNewsletter.vue +1 -1
  698. package/src/modules/orders/components/elements/PriceTotal.vue +3 -3
  699. package/src/modules/orders/components/forms/FormApplicationDetails.vue +2 -2
  700. package/src/modules/orders/components/forms/FormCustomerDetails.vue +3 -3
  701. package/src/modules/orders/components/pages/Favorites.vue +1 -1
  702. package/src/modules/orders/components/pages/OrderBackoffice.vue +15 -15
  703. package/src/modules/orders/components/pages/OrderCreate.vue +2 -2
  704. package/src/modules/orders/components/pages/OrderCreateBackoffice.vue +4 -4
  705. package/src/modules/orders/components/pages/Orders_refact.vue +3 -3
  706. package/src/modules/orders/components/partials/ShopCart.vue +2 -2
  707. package/src/modules/orders/components/sections/ApplicationDetails.vue +2 -2
  708. package/src/modules/orders/components/sections/AskToLogin.vue +1 -1
  709. package/src/modules/orders/components/sections/CustomerDetails.vue +2 -2
  710. package/src/modules/orders/components/sections/Succes.vue +4 -4
  711. package/src/modules/organizations/components/blocks/CardDepartment.vue +1 -1
  712. package/src/modules/organizations/components/blocks/CardOrganization.vue +4 -4
  713. package/src/modules/organizations/components/blocks/Contacts.vue +8 -8
  714. package/src/modules/organizations/components/blocks/Rating.vue +1 -1
  715. package/src/modules/organizations/components/forms/AddExistingMembersForm.vue +3 -3
  716. package/src/modules/organizations/components/forms/DepartmentForm.vue +1 -1
  717. package/src/modules/organizations/components/forms/InviteForm.vue +1 -1
  718. package/src/modules/organizations/components/pages/Department.vue +2 -2
  719. package/src/modules/organizations/components/pages/DepartmentEdit.vue +1 -1
  720. package/src/modules/organizations/components/pages/Members.vue +1 -1
  721. package/src/modules/organizations/components/pages/Organization.new.vue +8 -8
  722. package/src/modules/organizations/components/pages/Organization.vue +6 -6
  723. package/src/modules/organizations/components/pages/OrganizationDocuments.vue +2 -2
  724. package/src/modules/organizations/components/pages/Organizations.vue +3 -3
  725. package/src/modules/organizations/components/sections/Documents.vue +2 -2
  726. package/src/modules/organizations/components/sections/MembersAdd.vue +1 -1
  727. package/src/modules/organizations/components/sections/Unit.vue +1 -1
  728. package/src/modules/pages/views/components/blocks/CardPage.vue +2 -2
  729. package/src/modules/pages/views/components/pages/Page.vue +5 -5
  730. package/src/modules/products/components/blocks/CardCategory.vue +1 -1
  731. package/src/modules/products/components/blocks/CardPosition.vue +4 -4
  732. package/src/modules/products/components/blocks/CardProduct.vue +3 -3
  733. package/src/modules/products/components/blocks/ProductDiscounts.vue +3 -3
  734. package/src/modules/products/components/blocks/ProductImages.vue +2 -2
  735. package/src/modules/products/components/blocks/ProductVariants.vue +2 -2
  736. package/src/modules/products/components/elements/Image360.vue +2 -2
  737. package/src/modules/products/components/elements/Price.vue +2 -2
  738. package/src/modules/products/components/elements/QuantitySelector.vue +3 -3
  739. package/src/modules/products/components/elements/THC.vue +1 -1
  740. package/src/modules/products/components/forms/ReorderSettingsForm.vue +1 -1
  741. package/src/modules/products/components/forms/StockAuditForm.vue +2 -2
  742. package/src/modules/products/components/forms/StockHistoryView.vue +1 -1
  743. package/src/modules/products/components/pages/Categories.vue +1 -1
  744. package/src/modules/products/components/pages/CategoryEdit.vue +2 -2
  745. package/src/modules/products/components/pages/Product.vue +6 -6
  746. package/src/modules/products/components/pages/ProductEdit.vue +6 -6
  747. package/src/modules/products/components/pages/Products.vue +11 -11
  748. package/src/modules/products/components/sections/EditAttributes.vue +4 -4
  749. package/src/modules/products/components/sections/EditCategories.vue +1 -1
  750. package/src/modules/products/components/sections/EditDiscounts.vue +6 -6
  751. package/src/modules/products/components/sections/EditRecommended.vue +1 -1
  752. package/src/modules/products/components/sections/EditVariants.vue +8 -8
  753. package/src/modules/products/components/sections/FilterProducts.vue +3 -3
  754. package/src/modules/products/components/sections/ProductConfigurator.vue +2 -2
  755. package/src/modules/products/components/sections/ProductInformationSection.vue +10 -10
  756. package/src/modules/products/components/sections/ProductsRecommended.vue +2 -2
  757. package/src/modules/products/components/sections/SectionProduct.vue +7 -7
  758. package/src/modules/products/experiments/product-recommendation/components/HeroRecommendation.vue +3 -3
  759. package/src/modules/rents/views/components/blocks/CardRent.vue +1 -1
  760. package/src/modules/rents/views/components/pages/Gant/DateLabel.vue +1 -1
  761. package/src/modules/rents/views/components/pages/Gant/GanttBar.vue +2 -2
  762. package/src/modules/rents/views/components/pages/Gant/GanttChart.vue +8 -8
  763. package/src/modules/rents/views/components/pages/Gant/GanttHeaderCell.vue +1 -1
  764. package/src/modules/rents/views/components/pages/Rents.vue +1 -1
  765. package/src/modules/rents/views/components/pages/RentsEdit.vue +6 -6
  766. package/src/modules/reports/components/pages/BackofficeReports.vue +3 -3
  767. package/src/modules/reports/components/sections/FormReport.vue +1 -1
  768. package/src/modules/spots/components/blocks/CardSpot.vue +4 -4
  769. package/src/modules/spots/components/blocks/SpotMemberModify.vue +1 -1
  770. package/src/modules/spots/components/layouts/Spots.vue +2 -2
  771. package/src/modules/spots/components/pages/Spot.vue +5 -5
  772. package/src/modules/spots/components/pages/SpotEdit.vue +2 -2
  773. package/src/modules/spots/components/pages/Spots.vue +3 -3
  774. package/src/modules/spots/components/sections/MapSection.vue +1 -1
  775. package/src/modules/spots/components/sections/WorktimeEdit.vue +4 -4
  776. package/src/modules/wallet/views/components/blocks/CardBalanceReplenished.vue +5 -5
  777. package/src/modules/wallet/views/components/blocks/CardDeposit.vue +5 -5
  778. package/src/modules/wallet/views/components/blocks/CashDeposit.vue +2 -2
  779. package/src/modules/wallet/views/components/blocks/CryptoDeposit.vue +4 -4
  780. package/src/modules/wallet/views/components/blocks/CryptoDepositProcessing.vue +11 -11
  781. package/src/modules/wallet/views/components/elements/ConnectMetamask.vue +4 -4
  782. package/src/modules/wallet/views/components/pages/Wallet.vue +22 -22
  783. package/src/styles/config.scss +193 -507
  784. package/src/styles/layout.scss +81 -1
  785. package/src/styles/reset.scss +2 -0
  786. package/src/styles/theme.scss +1 -8
  787. package/dist/martyrs/dist/main-BFvlam0J.js.map +0 -1
  788. package/dist/martyrs/node_modules/.pnpm/@capacitor_core@7.0.1/node_modules/@capacitor/core/dist/index.js.map +0 -1
  789. package/dist/martyrs/src/components/EditImages/EditImages.vue.js.map +0 -1
  790. package/dist/martyrs/src/components/Loader/Loader.vue.js.map +0 -1
  791. package/dist/martyrs/src/components/Menu/Menu.vue.js.map +0 -1
  792. package/dist/martyrs/src/components/SelectMulti/SelectMulti.vue2.js.map +0 -1
  793. package/dist/martyrs/src/components/Tooltip/Tooltip.vue.js.map +0 -1
  794. package/dist/martyrs/src/modules/core/views/components/sections/Filters.vue.js.map +0 -1
  795. package/dist/node_modules/.pnpm/@vue_server-renderer@3.5.13_vue@3.5.13_typescript@5.8.3_/node_modules/@vue/server-renderer/dist/server-renderer.esm-bundler.js.map +0 -1
  796. package/dist/node_modules/.pnpm/@vue_shared@3.5.13/node_modules/@vue/shared/dist/shared.esm-bundler.js.map +0 -1
  797. package/dist/node_modules/.pnpm/dayjs@1.11.13/node_modules/dayjs/dayjs.min.js.map +0 -1
  798. package/dist/node_modules/.pnpm/dayjs@1.11.13/node_modules/dayjs/plugin/weekOfYear.js.map +0 -1
  799. package/dist/node_modules/.pnpm/uuid@11.1.0/node_modules/uuid/dist/esm-browser/native.js +0 -6
  800. package/dist/node_modules/.pnpm/uuid@11.1.0/node_modules/uuid/dist/esm-browser/native.js.map +0 -1
  801. package/dist/node_modules/.pnpm/uuid@11.1.0/node_modules/uuid/dist/esm-browser/rng.js +0 -15
  802. package/dist/node_modules/.pnpm/uuid@11.1.0/node_modules/uuid/dist/esm-browser/rng.js.map +0 -1
  803. package/dist/node_modules/.pnpm/uuid@11.1.0/node_modules/uuid/dist/esm-browser/stringify.js +0 -11
  804. package/dist/node_modules/.pnpm/uuid@11.1.0/node_modules/uuid/dist/esm-browser/stringify.js.map +0 -1
  805. package/dist/node_modules/.pnpm/uuid@11.1.0/node_modules/uuid/dist/esm-browser/v4.js +0 -20
  806. package/dist/node_modules/.pnpm/uuid@11.1.0/node_modules/uuid/dist/esm-browser/v4.js.map +0 -1
  807. package/src/modules/LAYOUT.MD +0 -767
  808. package/src/modules/STYLES.MD +0 -298
  809. package/src/modules/inventory/inventory.router.js +0 -72
  810. package/src/modules/products/products.router.js +0 -299
  811. package/src/styles/base/all.scss +0 -233
  812. package/src/styles/base/backgrounds.scss +0 -70
  813. package/src/styles/base/borders.scss +0 -407
  814. package/src/styles/base/scrolling.scss +0 -137
  815. package/src/styles/base/shadow_transitions_hover_refactor.scss +0 -158
  816. package/src/styles/base/transitions.scss +0 -109
  817. package/src/styles/responsive.scss +0 -152
  818. package/src/styles/typography.scss +0 -161
  819. /package/dist/{node_modules/.pnpm/@vue_shared@3.5.13 → martyrs}/node_modules/@vue/shared/dist/shared.esm-bundler.js +0 -0
@@ -1,4 +1,4 @@
1
- import { Preferences } from "../../../../../node_modules/.pnpm/@capacitor_preferences@7.0.0_@capacitor_core@7.0.1/node_modules/@capacitor/preferences/dist/esm/index.js";
1
+ import { Preferences } from "../../../../../node_modules/.pnpm/@capacitor_preferences@7.0.2_@capacitor_core@7.4.4/node_modules/@capacitor/preferences/dist/esm/index.js";
2
2
  import { reactive, isReactive } from "vue";
3
3
  import SessionManager from "../classes/session.manager.js";
4
4
  let asyncLocalStorage = null;
@@ -9,23 +9,6 @@ async function getAsyncLocalStorage() {
9
9
  }
10
10
  return asyncLocalStorage;
11
11
  }
12
- function invertColors(variableNames, originalColors, isDarkMode) {
13
- variableNames.forEach((variableName) => {
14
- const baseColor = originalColors[variableName];
15
- const colorArray = baseColor.split(",").map(Number);
16
- let invertedColor;
17
- if (variableName === "--white") {
18
- invertedColor = colorArray.map((value) => 255 - value / 1.075);
19
- } else if (variableName === "--black") {
20
- invertedColor = colorArray.map((value) => 255 - value);
21
- } else if (variableName === "--grey") {
22
- invertedColor = colorArray.map((value) => 255 - value * 2);
23
- } else {
24
- invertedColor = colorArray.map((value) => 255 - value / 1.075);
25
- }
26
- document.documentElement.style.setProperty(variableName, isDarkMode ? invertedColor.join(", ") : baseColor);
27
- });
28
- }
29
12
  function setError(error) {
30
13
  const state = useStore().core.state;
31
14
  state.error.show = true;
@@ -103,7 +86,8 @@ function createStore() {
103
86
  position: null,
104
87
  search: null,
105
88
  theme: {
106
- darkmode: false
89
+ mode: "system"
90
+ // 'light' | 'dark' | 'system'
107
91
  },
108
92
  navigation_bar: {
109
93
  name: null,
@@ -135,40 +119,38 @@ function createStore() {
135
119
  setLoading(status) {
136
120
  state.loading = status;
137
121
  },
138
- // Black/White Theme
139
- async setTheme(isDarkMode) {
140
- if (!state.theme.rootElement) {
141
- state.theme.rootElement = document.documentElement;
142
- }
143
- const root = state.theme.rootElement;
144
- state.theme.darkmode = isDarkMode;
145
- await Preferences.set({
146
- key: "darkmode",
147
- value: JSON.stringify(state.theme.darkmode)
148
- });
149
- if (isDarkMode) {
150
- root.classList.add("dark-theme");
122
+ // Theme: 'light' | 'dark' | 'system'
123
+ async setTheme(mode) {
124
+ state.theme.mode = mode;
125
+ if (mode === "light" || mode === "dark") {
126
+ if (typeof document !== "undefined") {
127
+ document.cookie = `theme=${mode}; path=/; max-age=31536000; SameSite=Lax`;
128
+ }
129
+ await Preferences.set({ key: "theme", value: mode });
151
130
  } else {
152
- root.classList.remove("dark-theme");
153
- }
154
- const variableNames = ["--white", "--light", "--grey", "--dark", "--black"];
155
- if (!state.theme.originalColors) {
156
- state.theme.originalColors = {};
157
- const computedStyle = getComputedStyle(root);
158
- variableNames.forEach((variableName) => {
159
- state.theme.originalColors[variableName] = computedStyle.getPropertyValue(variableName).trim();
160
- });
131
+ if (typeof document !== "undefined") {
132
+ document.cookie = `theme=; path=/; max-age=0`;
133
+ }
134
+ await Preferences.remove({ key: "theme" });
161
135
  }
162
- if (isDarkMode) {
163
- invertColors(variableNames, state.theme.originalColors, isDarkMode);
136
+ const root = document.documentElement;
137
+ root.classList.remove("dark-theme", "light-theme");
138
+ root.removeAttribute("data-theme");
139
+ if (mode === "dark") {
140
+ root.classList.add("dark-theme");
141
+ root.setAttribute("data-theme", "dark");
142
+ root.setAttribute("color-scheme", "dark");
143
+ } else if (mode === "light") {
144
+ root.classList.add("light-theme");
145
+ root.setAttribute("data-theme", "light");
146
+ root.setAttribute("color-scheme", "light");
164
147
  } else {
165
- variableNames.forEach((variableName) => {
166
- root.style.setProperty(variableName, state.theme.originalColors[variableName]);
167
- });
148
+ root.setAttribute("color-scheme", "light dark");
168
149
  }
169
150
  },
170
151
  toggleTheme() {
171
- this.setTheme(!state.theme.darkmode);
152
+ const isDark = state.theme.mode === "dark" || state.theme.mode === "system" && typeof window !== "undefined" && window.matchMedia("(prefers-color-scheme: dark)").matches;
153
+ this.setTheme(isDark ? "light" : "dark");
172
154
  },
173
155
  add(array, item) {
174
156
  const existingItemIndex = array.findIndex((i) => i._id === item._id);
@@ -1 +1 @@
1
- {"version":3,"file":"core.store.js","sources":["../../../../../../../src/modules/core/views/store/core.store.js"],"sourcesContent":["// Vue modules\nimport { Preferences } from '@capacitor/preferences';\nimport { isReactive, reactive } from 'vue';\n\nimport SessionManager from '../classes/session.manager.js';\n\n// AsyncLocalStorage для изоляции SSR store per-request (только Node.js)\nlet asyncLocalStorage = null;\n\nasync function getAsyncLocalStorage() {\n if (!asyncLocalStorage && typeof window === 'undefined') {\n const { AsyncLocalStorage } = await import('async_hooks');\n asyncLocalStorage = new AsyncLocalStorage();\n }\n return asyncLocalStorage;\n}\n\n// ============================================================================\n// HELPER FUNCTIONS\n// ============================================================================\n\nfunction invertColors(variableNames, originalColors, isDarkMode) {\n variableNames.forEach(variableName => {\n const baseColor = originalColors[variableName];\n const colorArray = baseColor.split(',').map(Number);\n\n let invertedColor;\n\n if (variableName === '--white') {\n invertedColor = colorArray.map(value => 255 - value / 1.075);\n } else if (variableName === '--black') {\n invertedColor = colorArray.map(value => 255 - value);\n } else if (variableName === '--grey') {\n invertedColor = colorArray.map(value => 255 - value * 2);\n } else {\n invertedColor = colorArray.map(value => 255 - value / 1.075);\n }\n // Устанавливаем новые значения переменных CSS\n document.documentElement.style.setProperty(variableName, isDarkMode ? invertedColor.join(', ') : baseColor);\n });\n}\n\n// ============================================================================\n// GLOBAL FUNCTIONS (используют useStore() для доступа к state)\n// ============================================================================\n\n// Mutations\nexport function setError(error) {\n const state = useStore().core.state;\n state.error.show = true;\n let errorData;\n\n errorData = error;\n\n // Обработка ошибок из fetch API (Store class)\n if (error?.info) errorData = error.info;\n\n // Обработка ошибок из axios\n if (error?.response?.data) errorData = error.response.data;\n\n // Обработка ошибок верификации\n if ((errorData?.error === 'VALIDATION_ERROR' || errorData?.errors) && errorData?.errors) {\n // Собираем все сообщения об ошибках в одну строку\n const errorMessages = [];\n for (const field in errorData.errors) {\n const fieldErrors = errorData.errors[field];\n if (Array.isArray(fieldErrors)) {\n errorMessages.push(...fieldErrors);\n } else if (typeof fieldErrors === 'string') {\n errorMessages.push(fieldErrors);\n }\n }\n state.error.message = errorMessages.join(', ') || errorData.message || 'Validation error';\n } else if (error && errorData.errorCode) {\n // state.error.message = i18n.global.t(`errors.${errorData.errorCode}`);\n state.error.message = errorData.errorCode;\n } else {\n state.error.message = errorData.message || error.message || 'Unknown error';\n }\n\n state.error.show = true;\n\n if (typeof window !== 'undefined' && window.requestAnimationFrame) {\n requestAnimationFrame(() => {\n setTimeout(() => (state.error.show = false), 5000);\n });\n } else {\n setTimeout(() => (state.error.show = false), 5000);\n }\n}\n\nexport function setSnack(data) {\n const state = useStore().core.state;\n\n // Handle different input formats\n let type = 'notification'\n let message = ''\n let duration = 3000\n\n if (typeof data === 'string') {\n message = data\n } else if (data instanceof Error) {\n type = 'error'\n message = data.message\n } else if (data?.response?.data) {\n // Handle API errors\n type = 'error'\n const errorData = data.response.data\n message = errorData.errorCode || errorData.message || 'Unknown error'\n } else if (typeof data === 'object') {\n type = data.type || 'notification'\n message = data.message || ''\n duration = data.duration || 3000\n }\n\n // Update state\n state.snack = {\n show: true,\n type,\n message,\n duration\n }\n\n // Auto-hide\n if (typeof window !== 'undefined' && window.requestAnimationFrame) {\n requestAnimationFrame(() => {\n setTimeout(() => {state.snack.show = false }, duration)\n });\n } else {\n setTimeout(() => {state.snack.show = false }, duration)\n }\n}\n\n// ============================================================================\n// GLOBAL STORE FACTORY\n// ============================================================================\n\n// Фабрика для создания store\nexport function createStore() {\n // State создается для каждого store instance (изоляция SSR)\n const state = reactive({\n loading: false,\n\n isOpenLocationPopup: false,\n isOpenSidebar: false,\n\n position: null,\n search: null,\n\n theme: {\n darkmode: false,\n },\n\n navigation_bar: {\n name: null,\n actions: null,\n },\n\n error: {\n status: '',\n headers: '',\n data: '',\n show: false,\n name: '',\n message: '',\n },\n snack: {\n show: false,\n type: 'notification',\n message: '',\n duration: 3000\n },\n\n // Session state - данные сессии хранятся здесь\n session: {\n token: null,\n userId: null,\n roles: null,\n accesses: []\n },\n });\n\n // Actions с closure на локальный state\n const actions = {\n setLoading(status) {\n state.loading = status;\n },\n\n // Black/White Theme\n async setTheme(isDarkMode) {\n // Cache root element\n if (!state.theme.rootElement) {\n state.theme.rootElement = document.documentElement;\n }\n const root = state.theme.rootElement;\n\n state.theme.darkmode = isDarkMode;\n\n await Preferences.set({\n key: 'darkmode',\n value: JSON.stringify(state.theme.darkmode),\n });\n\n if (isDarkMode) {\n root.classList.add('dark-theme');\n } else {\n root.classList.remove('dark-theme');\n }\n\n const variableNames = ['--white', '--light', '--grey', '--dark', '--black'];\n\n // Проверяем, сохранены ли оригинальные цвета\n if (!state.theme.originalColors) {\n // Сохраняем оригинальные цвета один раз\n state.theme.originalColors = {};\n const computedStyle = getComputedStyle(root);\n variableNames.forEach(variableName => {\n state.theme.originalColors[variableName] = computedStyle.getPropertyValue(variableName).trim();\n });\n }\n\n if (isDarkMode) {\n invertColors(variableNames, state.theme.originalColors, isDarkMode);\n } else {\n // Восстанавливаем оригинальные цвета батчем\n variableNames.forEach(variableName => {\n root.style.setProperty(variableName, state.theme.originalColors[variableName]);\n });\n }\n },\n\n toggleTheme() {\n this.setTheme(!state.theme.darkmode);\n },\n\n add(array, item) {\n const existingItemIndex = array.findIndex(i => i._id === item._id);\n\n if (existingItemIndex === -1) {\n array.push(item);\n } else {\n array[existingItemIndex] = item;\n }\n },\n\n update(array, item) {\n const existingItemIndex = array.findIndex(i => i._id === item._id);\n if (existingItemIndex === -1) {\n // If the item doesn't exist, push it to the array\n array.push(item);\n } else {\n // Update the item in the array without creating a new array\n Object.assign(array[existingItemIndex], item);\n }\n },\n\n delete(array, item) {\n const existingItemIndex = array.findIndex(c => c._id === item._id);\n\n if (existingItemIndex !== -1) {\n array.splice(existingItemIndex, 1);\n }\n },\n\n increment(array, item) {\n console.log(array);\n console.log(item);\n const arrayItem = array.find(i => i._id === item._id);\n\n if (arrayItem) {\n arrayItem.quantity++;\n }\n },\n\n decrement(array, item) {\n const arrayItem = array.find(i => i._id === item._id);\n\n const arrayItemIndex = array.indexOf(arrayItem);\n\n if (arrayItemIndex > -1) {\n arrayItem.quantity--;\n\n if (arrayItem.quantity < 1) array.splice(arrayItemIndex, 1);\n }\n },\n\n reset(array) {\n array = [];\n },\n };\n\n // SessionManager создается внутри createStore для правильной изоляции в SSR\n const sessionManager = new SessionManager(state.session);\n\n const store = reactive({\n modules: [],\n\n // Core module registered by default\n core: { state, actions, session: sessionManager },\n\n addStore(name, storage) {\n this[name] = storage;\n this.modules.push(name);\n },\n\n async getInitialState() {\n const initialState = {};\n for (const [moduleName, moduleStore] of Object.entries(this)) {\n if (moduleName !== 'modules' && moduleName !== 'addStore' && moduleName !== 'getInitialState' && moduleName !== 'setInitialState') {\n if (moduleStore.state) {\n initialState[moduleName] = JSON.parse(JSON.stringify(moduleStore.state));\n }\n }\n }\n return initialState;\n },\n\n async setInitialState(initialState, isHydration = false) {\n const modules = Object.entries(initialState);\n\n for (const [moduleName, moduleState] of modules) {\n if (this[moduleName] && this[moduleName].state) {\n // При гидратации просто заменяем state целиком для скорости\n if (isHydration) {\n Object.assign(this[moduleName].state, moduleState);\n } else {\n mergeReactive(this[moduleName].state, moduleState);\n }\n }\n }\n }\n });\n\n function mergeReactive(target, source) {\n // Оптимизированная версия слияния\n const keys = Object.keys(source);\n for (let i = 0; i < keys.length; i++) {\n const key = keys[i];\n const sourceValue = source[key];\n\n if (sourceValue !== null && typeof sourceValue === 'object' && !Array.isArray(sourceValue)) {\n if (isReactive(target[key])) {\n mergeReactive(target[key], sourceValue);\n } else {\n target[key] = sourceValue;\n }\n } else {\n target[key] = sourceValue;\n }\n }\n }\n\n return store;\n}\n\n// ============================================================================\n// SSR AND SINGLETON\n// ============================================================================\n\n// Синглтон для клиента\nlet clientStore = null;\n\n// AsyncLocalStorage для SSR (изоляция per-request)\nexport async function setSSRStore(store) {\n if (typeof window === 'undefined') {\n const als = await getAsyncLocalStorage();\n als?.enterWith(store);\n }\n}\n\nexport async function clearSSRStore() {\n if (typeof window === 'undefined') {\n const als = await getAsyncLocalStorage();\n als?.enterWith(null);\n }\n}\n\nexport function useStore() {\n if (typeof window === 'undefined') {\n // SSR: используем store из AsyncLocalStorage (может быть null если не инициализирован)\n const store = asyncLocalStorage?.getStore();\n if (store) {\n return store;\n }\n // Fallback для обратной совместимости\n console.warn('[WARN] SSR store not in AsyncLocalStorage, creating new store instance');\n return createStore();\n }\n // Client: синглтон\n if (!clientStore) {\n clientStore = createStore();\n }\n return clientStore;\n}\n\n// ============================================================================\n// SESSION ACCESSOR\n// ============================================================================\n\n/**\n * Получить текущий экземпляр SessionManager\n * Использовать вместо прямого импорта session для правильной работы с SSR\n */\nexport function useSession() {\n const store = useStore();\n return store.core.session;\n}\n\n// ============================================================================\n// EXPORTS\n// ============================================================================\n\n// Не экспортируем singleton state/actions - теперь используется useStore()\nexport default useStore();\n"],"names":[],"mappings":";;;AAOA,IAAI,oBAAoB;AAExB,eAAe,uBAAuB;AACpC,MAAI,CAAC,qBAAqB,OAAO,WAAW,aAAa;AACvD,UAAM,EAAE,kBAAiB,IAAK,MAAM,OAAO,aAAa;AACxD,wBAAoB,IAAI,kBAAiB;AAAA,EAC3C;AACA,SAAO;AACT;AAMA,SAAS,aAAa,eAAe,gBAAgB,YAAY;AAC/D,gBAAc,QAAQ,kBAAgB;AACpC,UAAM,YAAY,eAAe,YAAY;AAC7C,UAAM,aAAa,UAAU,MAAM,GAAG,EAAE,IAAI,MAAM;AAElD,QAAI;AAEJ,QAAI,iBAAiB,WAAW;AAC9B,sBAAgB,WAAW,IAAI,WAAS,MAAM,QAAQ,KAAK;AAAA,IAC7D,WAAW,iBAAiB,WAAW;AACrC,sBAAgB,WAAW,IAAI,WAAS,MAAM,KAAK;AAAA,IACrD,WAAW,iBAAiB,UAAU;AACpC,sBAAgB,WAAW,IAAI,WAAS,MAAM,QAAQ,CAAC;AAAA,IACzD,OAAO;AACL,sBAAgB,WAAW,IAAI,WAAS,MAAM,QAAQ,KAAK;AAAA,IAC7D;AAEA,aAAS,gBAAgB,MAAM,YAAY,cAAc,aAAa,cAAc,KAAK,IAAI,IAAI,SAAS;AAAA,EAC5G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,qBAAoB;AACtC,SAAK,UAAU,IAAI;AAAA,EACrB;AACF;AAEO,SAAS,WAAW;AACzB,MAAI,OAAO,WAAW,aAAa;AAEjC,UAAM,QAAQ,mBAAmB,SAAQ;AACzC,QAAI,OAAO;AACT,aAAO;AAAA,IACT;AAEA,YAAQ,KAAK,wEAAwE;AACrF,WAAO,YAAW;AAAA,EACpB;AAEA,MAAI,CAAC,aAAa;AAChB,kBAAc,YAAW;AAAA,EAC3B;AACA,SAAO;AACT;AAUO,SAAS,aAAa;AAC3B,QAAM,QAAQ,SAAQ;AACtB,SAAO,MAAM,KAAK;AACpB;AAOA,MAAA,aAAe,SAAQ;"}
1
+ {"version":3,"file":"core.store.js","sources":["../../../../../../../src/modules/core/views/store/core.store.js"],"sourcesContent":["// Vue modules\nimport { Preferences } from '@capacitor/preferences';\nimport { isReactive, reactive } from 'vue';\n\nimport SessionManager from '../classes/session.manager.js';\n\n// AsyncLocalStorage для изоляции SSR store per-request (только Node.js)\nlet asyncLocalStorage = null;\n\nasync function getAsyncLocalStorage() {\n if (!asyncLocalStorage && typeof window === 'undefined') {\n const { AsyncLocalStorage } = await import('async_hooks');\n asyncLocalStorage = new AsyncLocalStorage();\n }\n return asyncLocalStorage;\n}\n\n// ============================================================================\n// GLOBAL FUNCTIONS (используют useStore() для доступа к state)\n// ============================================================================\n\n// Mutations\nexport function setError(error) {\n const state = useStore().core.state;\n state.error.show = true;\n let errorData;\n\n errorData = error;\n\n // Обработка ошибок из fetch API (Store class)\n if (error?.info) errorData = error.info;\n\n // Обработка ошибок из axios\n if (error?.response?.data) errorData = error.response.data;\n\n // Обработка ошибок верификации\n if ((errorData?.error === 'VALIDATION_ERROR' || errorData?.errors) && errorData?.errors) {\n // Собираем все сообщения об ошибках в одну строку\n const errorMessages = [];\n for (const field in errorData.errors) {\n const fieldErrors = errorData.errors[field];\n if (Array.isArray(fieldErrors)) {\n errorMessages.push(...fieldErrors);\n } else if (typeof fieldErrors === 'string') {\n errorMessages.push(fieldErrors);\n }\n }\n state.error.message = errorMessages.join(', ') || errorData.message || 'Validation error';\n } else if (error && errorData.errorCode) {\n // state.error.message = i18n.global.t(`errors.${errorData.errorCode}`);\n state.error.message = errorData.errorCode;\n } else {\n state.error.message = errorData.message || error.message || 'Unknown error';\n }\n\n state.error.show = true;\n\n if (typeof window !== 'undefined' && window.requestAnimationFrame) {\n requestAnimationFrame(() => {\n setTimeout(() => (state.error.show = false), 5000);\n });\n } else {\n setTimeout(() => (state.error.show = false), 5000);\n }\n}\n\nexport function setSnack(data) {\n const state = useStore().core.state;\n\n // Handle different input formats\n let type = 'notification'\n let message = ''\n let duration = 3000\n\n if (typeof data === 'string') {\n message = data\n } else if (data instanceof Error) {\n type = 'error'\n message = data.message\n } else if (data?.response?.data) {\n // Handle API errors\n type = 'error'\n const errorData = data.response.data\n message = errorData.errorCode || errorData.message || 'Unknown error'\n } else if (typeof data === 'object') {\n type = data.type || 'notification'\n message = data.message || ''\n duration = data.duration || 3000\n }\n\n // Update state\n state.snack = {\n show: true,\n type,\n message,\n duration\n }\n\n // Auto-hide\n if (typeof window !== 'undefined' && window.requestAnimationFrame) {\n requestAnimationFrame(() => {\n setTimeout(() => {state.snack.show = false }, duration)\n });\n } else {\n setTimeout(() => {state.snack.show = false }, duration)\n }\n}\n\n// ============================================================================\n// GLOBAL STORE FACTORY\n// ============================================================================\n\n// Фабрика для создания store\nexport function createStore() {\n // State создается для каждого store instance (изоляция SSR)\n const state = reactive({\n loading: false,\n\n isOpenLocationPopup: false,\n isOpenSidebar: false,\n\n position: null,\n search: null,\n\n theme: {\n mode: 'system', // 'light' | 'dark' | 'system'\n },\n\n navigation_bar: {\n name: null,\n actions: null,\n },\n\n error: {\n status: '',\n headers: '',\n data: '',\n show: false,\n name: '',\n message: '',\n },\n snack: {\n show: false,\n type: 'notification',\n message: '',\n duration: 3000\n },\n\n // Session state - данные сессии хранятся здесь\n session: {\n token: null,\n userId: null,\n roles: null,\n accesses: []\n },\n });\n\n // Actions с closure на локальный state\n const actions = {\n setLoading(status) {\n state.loading = status;\n },\n\n // Theme: 'light' | 'dark' | 'system'\n async setTheme(mode) {\n state.theme.mode = mode;\n\n // Cookie/Preferences ТОЛЬКО для явного выбора light/dark\n // system — не сохраняем, пусть работает CSS media query\n if (mode === 'light' || mode === 'dark') {\n if (typeof document !== 'undefined') {\n document.cookie = `theme=${mode}; path=/; max-age=31536000; SameSite=Lax`;\n }\n await Preferences.set({ key: 'theme', value: mode });\n } else {\n // system — удаляем cookie чтобы SSR не фиксировал тему\n if (typeof document !== 'undefined') {\n document.cookie = `theme=; path=/; max-age=0`;\n }\n await Preferences.remove({ key: 'theme' });\n }\n\n const root = document.documentElement;\n\n // Убираем старые атрибуты\n root.classList.remove('dark-theme', 'light-theme');\n root.removeAttribute('data-theme');\n\n if (mode === 'dark') {\n root.classList.add('dark-theme');\n root.setAttribute('data-theme', 'dark');\n root.setAttribute('color-scheme', 'dark');\n } else if (mode === 'light') {\n root.classList.add('light-theme');\n root.setAttribute('data-theme', 'light');\n root.setAttribute('color-scheme', 'light');\n } else {\n // system - без классов, CSS media query сработает\n root.setAttribute('color-scheme', 'light dark');\n }\n\n },\n\n toggleTheme() {\n // Прямое переключение между light и dark\n const isDark = state.theme.mode === 'dark' ||\n (state.theme.mode === 'system' && typeof window !== 'undefined' &&\n window.matchMedia('(prefers-color-scheme: dark)').matches);\n this.setTheme(isDark ? 'light' : 'dark');\n },\n\n add(array, item) {\n const existingItemIndex = array.findIndex(i => i._id === item._id);\n\n if (existingItemIndex === -1) {\n array.push(item);\n } else {\n array[existingItemIndex] = item;\n }\n },\n\n update(array, item) {\n const existingItemIndex = array.findIndex(i => i._id === item._id);\n if (existingItemIndex === -1) {\n // If the item doesn't exist, push it to the array\n array.push(item);\n } else {\n // Update the item in the array without creating a new array\n Object.assign(array[existingItemIndex], item);\n }\n },\n\n delete(array, item) {\n const existingItemIndex = array.findIndex(c => c._id === item._id);\n\n if (existingItemIndex !== -1) {\n array.splice(existingItemIndex, 1);\n }\n },\n\n increment(array, item) {\n console.log(array);\n console.log(item);\n const arrayItem = array.find(i => i._id === item._id);\n\n if (arrayItem) {\n arrayItem.quantity++;\n }\n },\n\n decrement(array, item) {\n const arrayItem = array.find(i => i._id === item._id);\n\n const arrayItemIndex = array.indexOf(arrayItem);\n\n if (arrayItemIndex > -1) {\n arrayItem.quantity--;\n\n if (arrayItem.quantity < 1) array.splice(arrayItemIndex, 1);\n }\n },\n\n reset(array) {\n array = [];\n },\n };\n\n // SessionManager создается внутри createStore для правильной изоляции в SSR\n const sessionManager = new SessionManager(state.session);\n\n const store = reactive({\n modules: [],\n\n // Core module registered by default\n core: { state, actions, session: sessionManager },\n\n addStore(name, storage) {\n this[name] = storage;\n this.modules.push(name);\n },\n\n async getInitialState() {\n const initialState = {};\n for (const [moduleName, moduleStore] of Object.entries(this)) {\n if (moduleName !== 'modules' && moduleName !== 'addStore' && moduleName !== 'getInitialState' && moduleName !== 'setInitialState') {\n if (moduleStore.state) {\n initialState[moduleName] = JSON.parse(JSON.stringify(moduleStore.state));\n }\n }\n }\n return initialState;\n },\n\n async setInitialState(initialState, isHydration = false) {\n const modules = Object.entries(initialState);\n\n for (const [moduleName, moduleState] of modules) {\n if (this[moduleName] && this[moduleName].state) {\n // При гидратации просто заменяем state целиком для скорости\n if (isHydration) {\n Object.assign(this[moduleName].state, moduleState);\n } else {\n mergeReactive(this[moduleName].state, moduleState);\n }\n }\n }\n }\n });\n\n function mergeReactive(target, source) {\n // Оптимизированная версия слияния\n const keys = Object.keys(source);\n for (let i = 0; i < keys.length; i++) {\n const key = keys[i];\n const sourceValue = source[key];\n\n if (sourceValue !== null && typeof sourceValue === 'object' && !Array.isArray(sourceValue)) {\n if (isReactive(target[key])) {\n mergeReactive(target[key], sourceValue);\n } else {\n target[key] = sourceValue;\n }\n } else {\n target[key] = sourceValue;\n }\n }\n }\n\n return store;\n}\n\n// ============================================================================\n// SSR AND SINGLETON\n// ============================================================================\n\n// Синглтон для клиента\nlet clientStore = null;\n\n// AsyncLocalStorage для SSR (изоляция per-request)\nexport async function setSSRStore(store) {\n if (typeof window === 'undefined') {\n const als = await getAsyncLocalStorage();\n als?.enterWith(store);\n }\n}\n\nexport async function clearSSRStore() {\n if (typeof window === 'undefined') {\n const als = await getAsyncLocalStorage();\n als?.enterWith(null);\n }\n}\n\nexport function useStore() {\n if (typeof window === 'undefined') {\n // SSR: используем store из AsyncLocalStorage (может быть null если не инициализирован)\n const store = asyncLocalStorage?.getStore();\n if (store) {\n return store;\n }\n // Fallback для обратной совместимости\n console.warn('[WARN] SSR store not in AsyncLocalStorage, creating new store instance');\n return createStore();\n }\n // Client: синглтон\n if (!clientStore) {\n clientStore = createStore();\n }\n return clientStore;\n}\n\n// ============================================================================\n// SESSION ACCESSOR\n// ============================================================================\n\n/**\n * Получить текущий экземпляр SessionManager\n * Использовать вместо прямого импорта session для правильной работы с SSR\n */\nexport function useSession() {\n const store = useStore();\n return store.core.session;\n}\n\n// ============================================================================\n// EXPORTS\n// ============================================================================\n\n// Не экспортируем singleton state/actions - теперь используется useStore()\nexport default useStore();\n"],"names":[],"mappings":";;;AAOA,IAAI,oBAAoB;AAExB,eAAe,uBAAuB;AACpC,MAAI,CAAC,qBAAqB,OAAO,WAAW,aAAa;AACvD,UAAM,EAAE,kBAAiB,IAAK,MAAM,OAAO,aAAa;AACxD,wBAAoB,IAAI,kBAAiB;AAAA,EAC3C;AACA,SAAO;AACT;AAOO,SAAS,SAAS,OAAO;AAC9B,QAAM,QAAQ,WAAW,KAAK;AAC9B,QAAM,MAAM,OAAO;AACnB,MAAI;AAEJ,cAAY;AAGZ,MAAI,OAAO,KAAM,aAAY,MAAM;AAGnC,MAAI,OAAO,UAAU,KAAM,aAAY,MAAM,SAAS;AAGtD,OAAK,WAAW,UAAU,sBAAsB,WAAW,WAAW,WAAW,QAAQ;AAEvF,UAAM,gBAAgB,CAAA;AACtB,eAAW,SAAS,UAAU,QAAQ;AACpC,YAAM,cAAc,UAAU,OAAO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,MAAM,KAAK;AACpB;AAOA,MAAA,aAAe,SAAQ;"}
@@ -1,6 +1,6 @@
1
1
  import { setAuthToken } from "./axios-instance.js";
2
2
  import { renderSSRHead } from "../../../../../../node_modules/.pnpm/@unhead_ssr@1.11.20/node_modules/@unhead/ssr/dist/index.js";
3
- import { renderToString } from "../../../../../../node_modules/.pnpm/@vue_server-renderer@3.5.13_vue@3.5.13_typescript@5.8.3_/node_modules/@vue/server-renderer/dist/server-renderer.esm-bundler.js";
3
+ import { renderToString } from "../../../../../node_modules/@vue/server-renderer/dist/server-renderer.esm-bundler.js";
4
4
  function renderAndMountApp({ createApp, hooks = {} }) {
5
5
  const start = async () => {
6
6
  performance.mark("loading-22-start");
@@ -95,7 +95,7 @@ function renderAndMountApp({ createApp, hooks = {} }) {
95
95
  };
96
96
  return start();
97
97
  }
98
- async function render({ url, cookies, ssrContext, createApp }) {
98
+ async function render({ url, cookies, headers, ssrContext, createApp }) {
99
99
  performance.mark("loading-26-start");
100
100
  console.log("[LOADING 26] SSR render starting...");
101
101
  const { app, router, store, meta } = createApp();
@@ -143,6 +143,25 @@ async function render({ url, cookies, ssrContext, createApp }) {
143
143
  performance.mark("loading-28-start");
144
144
  console.log("[LOADING 28] SSR renderToString starting...");
145
145
  const html = await renderToString(app, ctx);
146
+ let theme = cookies?.theme;
147
+ if (!theme) {
148
+ const prefersColorScheme = headers?.["sec-ch-prefers-color-scheme"];
149
+ theme = prefersColorScheme === "dark" ? "system-dark" : "system";
150
+ }
151
+ const themeAttrs = {};
152
+ if (theme === "dark") {
153
+ themeAttrs.class = "dark-theme";
154
+ themeAttrs["data-theme"] = "dark";
155
+ themeAttrs["color-scheme"] = "dark";
156
+ } else if (theme === "light") {
157
+ themeAttrs.class = "light-theme";
158
+ themeAttrs["data-theme"] = "light";
159
+ themeAttrs["color-scheme"] = "light";
160
+ } else {
161
+ themeAttrs["color-scheme"] = "light dark";
162
+ }
163
+ meta.push({ htmlAttrs: themeAttrs });
164
+ store.core.state.theme.mode = theme === "dark" ? "dark" : theme === "light" ? "light" : "system";
146
165
  const payload = await renderSSRHead(meta, {});
147
166
  const initialState = await store.getInitialState();
148
167
  performance.mark("loading-28-end");
@@ -1 +1 @@
1
- {"version":3,"file":"vue-app-renderer.js","sources":["../../../../../../../src/modules/core/views/utils/vue-app-renderer.js"],"sourcesContent":["import { setAuthToken } from '@martyrs/src/modules/core/views/utils/axios-instance.js';\nimport { renderSSRHead } from '@unhead/ssr';\nimport { renderToString } from '@vue/server-renderer';\n\nexport function renderAndMountApp({ createApp, hooks = {} }) {\n const start = async () => {\n // [LOADING 22] Starting client-side hydration\n performance.mark('loading-22-start');\n console.log('[LOADING 22] Starting client-side hydration...');\n\n const { app, router, store, moduleManager, config } = await createApp();\n \n let serverModules = [];\n \n // Загружаем модули которые были загружены на сервере\n if (typeof window !== 'undefined') {\n try {\n const modulesElement = document.querySelector('[data-loaded-modules]');\n if (modulesElement) {\n serverModules = JSON.parse(modulesElement.innerHTML);\n }\n } catch (e) {\n console.error('Failed to parse loaded modules', e);\n }\n \n const context = { app, store, router, config };\n\n // [LOADING 23] Loading server modules for hydration\n performance.mark('loading-23-start');\n console.log(`[LOADING 23] Loading ${serverModules.length} server modules for hydration...`);\n\n for (const moduleName of serverModules) {\n try {\n await moduleManager.load(moduleName, context);\n await moduleManager.initialize(moduleName, context);\n } catch (error) {\n console.error(`Failed to load module ${moduleName}:`, error);\n }\n }\n\n performance.mark('loading-23-end');\n performance.measure('loading-23', 'loading-23-start', 'loading-23-end');\n const measure23 = performance.getEntriesByName('loading-23')[0];\n console.log(`[LOADING 23] Server modules loaded in ${measure23?.duration?.toFixed(2)}ms`);\n }\n \n // Call beforeHydration hook if provided\n if (hooks.beforeHydration) {\n hooks.beforeHydration({ app, router, store, moduleManager });\n }\n\n // [LOADING 24] Parsing and applying initialState\n performance.mark('loading-24-start');\n console.log('[LOADING 24] Parsing and applying initialState...');\n\n let initialState;\n\n try {\n const initialStateElement = document.querySelector('[data-state]');\n\n if (initialStateElement && initialStateElement.innerHTML.trim() !== '') {\n const stateContent = initialStateElement.innerHTML.trim();\n \n // Validate JSON format before parsing\n if (stateContent.startsWith('{') && stateContent.endsWith('}')) {\n initialState = JSON.parse(stateContent);\n \n // Basic validation of state structure\n if (typeof initialState !== 'object' || initialState === null) {\n throw new Error('Invalid state format');\n }\n } else {\n throw new Error('Invalid JSON format');\n }\n }\n } catch (error) {\n console.error('Failed to parse user state', error);\n initialState = null;\n }\n\n\n\n\n if (initialState) {\n console.log('[AUTH COOKIE DEBUG] Browser initialState.auth:', initialState.auth);\n console.log('[AUTH COOKIE DEBUG] Has token?', !!initialState?.auth?.access?.token);\n console.log('[AUTH COOKIE DEBUG] Has auth but no status?', !!initialState?.auth && !initialState.auth.access?.status);\n\n // Применяем начальное состояние ко всем модулям (true = гидратация)\n store.setInitialState(initialState, true);\n\n if (initialState?.auth?.access?.token) {\n console.log('[AUTH COOKIE DEBUG] Setting auth token from initialState');\n\n setAuthToken(initialState.auth.access.token);\n } else if (initialState?.auth && !initialState.auth.access?.status) {\n // Если SSR сбросил auth (из-за ошибки), удаляем куку в браузере\n console.log('[AUTH COOKIE DEBUG] SSR reset auth, removing cookie in browser');\n if (store.auth && store.auth.removeCookie) {\n await store.auth.removeCookie('user');\n }\n }\n } else {\n // Если нет initialState, сбрасываем авторизацию (если модуль auth загружен)\n if (store.auth && store.auth.actions) {\n store.auth.actions.resetState();\n // await store.auth.removeCookie('user');\n await store.auth.actions.logout();\n }\n }\n\n const savedPosition = localStorage.getItem('position');\n\n if (savedPosition) {\n store.core.state.position = JSON.parse(savedPosition);\n }\n\n // app.config.globalProperties.$i18n.locale = router.currentRoute.value.params.locale\n // app.config.globalProperties.$i18n.locale = router.currentRoute.value.params.locale\n // If user browser locae supported then change locale\n // if (i18n.global.availableLocales.includes(browserLocale)) {\n // app.config.globalProperties.$i18n.locale = browserLocale;\n // }\n\n performance.mark('loading-24-end');\n performance.measure('loading-24', 'loading-24-start', 'loading-24-end');\n const measure24 = performance.getEntriesByName('loading-24')[0];\n console.log(`[LOADING 24] InitialState parsed and applied in ${measure24?.duration?.toFixed(2)}ms`);\n\n await router.isReady();\n\n // [LOADING 25] Mounting the application\n performance.mark('loading-25-start');\n console.log('[LOADING 25] Mounting the application...');\n\n app.mount('#app');\n\n performance.mark('loading-25-end');\n performance.measure('loading-25', 'loading-25-start', 'loading-25-end');\n const measure25 = performance.getEntriesByName('loading-25')[0];\n console.log(`[LOADING 25] Application mounted in ${measure25?.duration?.toFixed(2)}ms`);\n\n // Return the objects for further use\n return { app, router, store, moduleManager };\n };\n return start();\n}\n\nexport async function render({ url, cookies, ssrContext, createApp}) {\n // [LOADING 26] SSR render starting\n performance.mark('loading-26-start');\n console.log('[LOADING 26] SSR render starting...');\n\n const { app, router, store, meta } = createApp();\n\n await router.push(url);\n await router.isReady();\n\n // If user's language is supported, change the locale\n // if (language === 'en' || language === 'ru') {\n // app.config.globalProperties.$i18n.locale = language\n // }\n\n // app.config.globalProperties.$i18n.locale = router.currentRoute.value.params.locale\n\n const ctx = ssrContext || {};\n\n if (router.currentRoute.value.name?.toLowerCase() === 'notfound') {\n ctx.notFound = true;\n }\n\n let user = null;\n\n if (cookies.user) {\n try {\n user = JSON.parse(cookies.user);\n } catch (error) {\n console.error('Failed to parse user cookie', error);\n user = null;\n }\n }\n\n \n\n\n if (user) {\n // [LOADING 27] SSR auth initialization\n performance.mark('loading-27-start');\n console.log('[LOADING 27] SSR auth initialization...');\n\n if (store.auth && store.auth.actions) {\n try {\n await store.auth.actions.initialize(user);\n } catch (error) {\n console.error('[SSR] Auth initialization failed, continuing without auth:', error);\n // Сбрасываем состояние если инициализация упала\n if (store.auth.actions.resetState) {\n store.auth.actions.resetState();\n }\n }\n } else {\n console.warn('[SSR] Auth module not loaded, cannot initialize user');\n }\n\n performance.mark('loading-27-end');\n performance.measure('loading-27', 'loading-27-start', 'loading-27-end');\n const measure27 = performance.getEntriesByName('loading-27')[0];\n console.log(`[LOADING 27] SSR auth initialized in ${measure27?.duration?.toFixed(2)}ms`);\n } else {\n if (store.auth && store.auth.actions) {\n store.auth.actions.resetState();\n } else {\n console.warn('[SSR] Auth module not loaded, cannot reset state');\n }\n }\n\n // [LOADING 28] SSR renderToString\n performance.mark('loading-28-start');\n console.log('[LOADING 28] SSR renderToString starting...');\n\n // After render, ctx.modules will be populated with used module identifiers\n const html = await renderToString(app, ctx);\n const payload = await renderSSRHead(meta, {});\n const initialState = await store.getInitialState();\n\n performance.mark('loading-28-end');\n performance.measure('loading-28', 'loading-28-start', 'loading-28-end');\n const measure28 = performance.getEntriesByName('loading-28')[0];\n console.log(`[LOADING 28] SSR renderToString completed in ${measure28?.duration?.toFixed(2)}ms`);\n\n // Total SSR render time\n performance.measure('loading-26-total', 'loading-26-start', 'loading-28-end');\n const measure26Total = performance.getEntriesByName('loading-26-total')[0];\n console.log(`[LOADING 26] Total SSR render completed in ${measure26Total?.duration?.toFixed(2)}ms`);\n\n return {\n html,\n meta: payload,\n state: initialState,\n statusCode: router.currentRoute?.value?.name?.toLowerCase() === 'notfound' ? 404 : 200,\n usedModules: Array.from(ctx.modules || new Set()), // Return used modules\n };\n}\n"],"names":[],"mappings":";;;AAIO,SAAS,kBAAkB,EAAE,WAAW,QAAQ,CAAA,EAAE,GAAI;AAC3D,QAAM,QAAQ,YAAY;AAExB,gBAAY,KAAK,kBAAkB;AACnC,YAAQ,IAAI,gDAAgD;AAE5D,UAAM,EAAE,KAAK,QAAQ,OAAO,eAAe,OAAM,IAAK,MAAM,UAAS;AAErE,QAAI,gBAAgB,CAAA;AAGpB,QAAI,OAAO,WAAW,aAAa;AACjC,UAAI;AACF,cAAM,iBAAiB,SAAS,cAAc,uBAAuB;AACrE,YAAI,gBAAgB;AAClB,0BAAgB,KAAK,MAAM,eAAe,SAAS;AAAA,QACrD;AAAA,MACF,SAAS,GAAG;AACV,gBAAQ,MAAM,kCAAkC,CAAC;AAAA,MACnD;AAEA,YAAM,UAAU,EAAE,KAAK,OAAO,Q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AAA,IAC/B,OAAO;AACL,cAAQ,KAAK,kDAAkD;AAAA,IACjE;AAAA,EACF;AAGA,cAAY,KAAK,kBAAkB;AACnC,UAAQ,IAAI,6CAA6C;AAGzD,QAAM,OAAO,MAAM,eAAe,KAAK,GAAG;AAC1C,QAAM,UAAU,MAAM,cAAc,MAAM,CAAA,CAAE;AAC5C,QAAM,eAAe,MAAM,MAAM,gBAAe;AAEhD,cAAY,KAAK,gBAAgB;AACjC,cAAY,QAAQ,cAAc,oBAAoB,gBAAgB;AACtE,QAAM,YAAY,YAAY,iBAAiB,YAAY,EAAE,CAAC;AAC9D,UAAQ,IAAI,gDAAgD,WAAW,UAAU,QAAQ,CAAC,CAAC,IAAI;AAG/F,cAAY,QAAQ,oBAAoB,oBAAoB,gBAAgB;AAC5E,QAAM,iBAAiB,YAAY,iBAAiB,kBAAkB,EAAE,CAAC;AACzE,UAAQ,IAAI,8CAA8C,gBAAgB,UAAU,QAAQ,CAAC,CAAC,IAAI;AAElG,SAAO;AAAA,IACL;AAAA,IACA,MAAM;AAAA,IACN,OAAO;AAAA,IACP,YAAY,OAAO,cAAc,OAAO,MAAM,YAAW,MAAO,aAAa,MAAM;AAAA,IACnF,aAAa,MAAM,KAAK,IAAI,WAAW,oBAAI,KAAK;AAAA;AAAA,EACpD;AACA;"}
1
+ {"version":3,"file":"vue-app-renderer.js","sources":["../../../../../../../src/modules/core/views/utils/vue-app-renderer.js"],"sourcesContent":["import { setAuthToken } from '@martyrs/src/modules/core/views/utils/axios-instance.js';\nimport { renderSSRHead } from '@unhead/ssr';\nimport { renderToString } from '@vue/server-renderer';\n\nexport function renderAndMountApp({ createApp, hooks = {} }) {\n const start = async () => {\n // [LOADING 22] Starting client-side hydration\n performance.mark('loading-22-start');\n console.log('[LOADING 22] Starting client-side hydration...');\n\n const { app, router, store, moduleManager, config } = await createApp();\n \n let serverModules = [];\n \n // Загружаем модули которые были загружены на сервере\n if (typeof window !== 'undefined') {\n try {\n const modulesElement = document.querySelector('[data-loaded-modules]');\n if (modulesElement) {\n serverModules = JSON.parse(modulesElement.innerHTML);\n }\n } catch (e) {\n console.error('Failed to parse loaded modules', e);\n }\n \n const context = { app, store, router, config };\n\n // [LOADING 23] Loading server modules for hydration\n performance.mark('loading-23-start');\n console.log(`[LOADING 23] Loading ${serverModules.length} server modules for hydration...`);\n\n for (const moduleName of serverModules) {\n try {\n await moduleManager.load(moduleName, context);\n await moduleManager.initialize(moduleName, context);\n } catch (error) {\n console.error(`Failed to load module ${moduleName}:`, error);\n }\n }\n\n performance.mark('loading-23-end');\n performance.measure('loading-23', 'loading-23-start', 'loading-23-end');\n const measure23 = performance.getEntriesByName('loading-23')[0];\n console.log(`[LOADING 23] Server modules loaded in ${measure23?.duration?.toFixed(2)}ms`);\n }\n \n // Call beforeHydration hook if provided\n if (hooks.beforeHydration) {\n hooks.beforeHydration({ app, router, store, moduleManager });\n }\n\n // [LOADING 24] Parsing and applying initialState\n performance.mark('loading-24-start');\n console.log('[LOADING 24] Parsing and applying initialState...');\n\n let initialState;\n\n try {\n const initialStateElement = document.querySelector('[data-state]');\n\n if (initialStateElement && initialStateElement.innerHTML.trim() !== '') {\n const stateContent = initialStateElement.innerHTML.trim();\n \n // Validate JSON format before parsing\n if (stateContent.startsWith('{') && stateContent.endsWith('}')) {\n initialState = JSON.parse(stateContent);\n \n // Basic validation of state structure\n if (typeof initialState !== 'object' || initialState === null) {\n throw new Error('Invalid state format');\n }\n } else {\n throw new Error('Invalid JSON format');\n }\n }\n } catch (error) {\n console.error('Failed to parse user state', error);\n initialState = null;\n }\n\n\n\n\n if (initialState) {\n console.log('[AUTH COOKIE DEBUG] Browser initialState.auth:', initialState.auth);\n console.log('[AUTH COOKIE DEBUG] Has token?', !!initialState?.auth?.access?.token);\n console.log('[AUTH COOKIE DEBUG] Has auth but no status?', !!initialState?.auth && !initialState.auth.access?.status);\n\n // Применяем начальное состояние ко всем модулям (true = гидратация)\n store.setInitialState(initialState, true);\n\n if (initialState?.auth?.access?.token) {\n console.log('[AUTH COOKIE DEBUG] Setting auth token from initialState');\n\n setAuthToken(initialState.auth.access.token);\n } else if (initialState?.auth && !initialState.auth.access?.status) {\n // Если SSR сбросил auth (из-за ошибки), удаляем куку в браузере\n console.log('[AUTH COOKIE DEBUG] SSR reset auth, removing cookie in browser');\n if (store.auth && store.auth.removeCookie) {\n await store.auth.removeCookie('user');\n }\n }\n } else {\n // Если нет initialState, сбрасываем авторизацию (если модуль auth загружен)\n if (store.auth && store.auth.actions) {\n store.auth.actions.resetState();\n // await store.auth.removeCookie('user');\n await store.auth.actions.logout();\n }\n }\n\n const savedPosition = localStorage.getItem('position');\n\n if (savedPosition) {\n store.core.state.position = JSON.parse(savedPosition);\n }\n\n // app.config.globalProperties.$i18n.locale = router.currentRoute.value.params.locale\n // app.config.globalProperties.$i18n.locale = router.currentRoute.value.params.locale\n // If user browser locae supported then change locale\n // if (i18n.global.availableLocales.includes(browserLocale)) {\n // app.config.globalProperties.$i18n.locale = browserLocale;\n // }\n\n performance.mark('loading-24-end');\n performance.measure('loading-24', 'loading-24-start', 'loading-24-end');\n const measure24 = performance.getEntriesByName('loading-24')[0];\n console.log(`[LOADING 24] InitialState parsed and applied in ${measure24?.duration?.toFixed(2)}ms`);\n\n await router.isReady();\n\n // [LOADING 25] Mounting the application\n performance.mark('loading-25-start');\n console.log('[LOADING 25] Mounting the application...');\n\n app.mount('#app');\n\n performance.mark('loading-25-end');\n performance.measure('loading-25', 'loading-25-start', 'loading-25-end');\n const measure25 = performance.getEntriesByName('loading-25')[0];\n console.log(`[LOADING 25] Application mounted in ${measure25?.duration?.toFixed(2)}ms`);\n\n // Return the objects for further use\n return { app, router, store, moduleManager };\n };\n return start();\n}\n\nexport async function render({ url, cookies, headers, ssrContext, createApp }) {\n // [LOADING 26] SSR render starting\n performance.mark('loading-26-start');\n console.log('[LOADING 26] SSR render starting...');\n\n const { app, router, store, meta } = createApp();\n\n await router.push(url);\n await router.isReady();\n\n // If user's language is supported, change the locale\n // if (language === 'en' || language === 'ru') {\n // app.config.globalProperties.$i18n.locale = language\n // }\n\n // app.config.globalProperties.$i18n.locale = router.currentRoute.value.params.locale\n\n const ctx = ssrContext || {};\n\n if (router.currentRoute.value.name?.toLowerCase() === 'notfound') {\n ctx.notFound = true;\n }\n\n let user = null;\n\n if (cookies.user) {\n try {\n user = JSON.parse(cookies.user);\n } catch (error) {\n console.error('Failed to parse user cookie', error);\n user = null;\n }\n }\n\n \n\n\n if (user) {\n // [LOADING 27] SSR auth initialization\n performance.mark('loading-27-start');\n console.log('[LOADING 27] SSR auth initialization...');\n\n if (store.auth && store.auth.actions) {\n try {\n await store.auth.actions.initialize(user);\n } catch (error) {\n console.error('[SSR] Auth initialization failed, continuing without auth:', error);\n // Сбрасываем состояние если инициализация упала\n if (store.auth.actions.resetState) {\n store.auth.actions.resetState();\n }\n }\n } else {\n console.warn('[SSR] Auth module not loaded, cannot initialize user');\n }\n\n performance.mark('loading-27-end');\n performance.measure('loading-27', 'loading-27-start', 'loading-27-end');\n const measure27 = performance.getEntriesByName('loading-27')[0];\n console.log(`[LOADING 27] SSR auth initialized in ${measure27?.duration?.toFixed(2)}ms`);\n } else {\n if (store.auth && store.auth.actions) {\n store.auth.actions.resetState();\n } else {\n console.warn('[SSR] Auth module not loaded, cannot reset state');\n }\n }\n\n // [LOADING 28] SSR renderToString\n performance.mark('loading-28-start');\n console.log('[LOADING 28] SSR renderToString starting...');\n\n // After render, ctx.modules will be populated with used module identifiers\n const html = await renderToString(app, ctx);\n\n // Добавляем атрибуты темы через meta API перед renderSSRHead\n let theme = cookies?.theme;\n if (!theme) {\n // Fallback на sec-ch-prefers-color-scheme если нет cookie\n const prefersColorScheme = headers?.['sec-ch-prefers-color-scheme'];\n theme = prefersColorScheme === 'dark' ? 'system-dark' : 'system';\n }\n\n const themeAttrs = {};\n if (theme === 'dark') {\n themeAttrs.class = 'dark-theme';\n themeAttrs['data-theme'] = 'dark';\n themeAttrs['color-scheme'] = 'dark';\n } else if (theme === 'light') {\n themeAttrs.class = 'light-theme';\n themeAttrs['data-theme'] = 'light';\n themeAttrs['color-scheme'] = 'light';\n } else {\n // system/system-dark - без класса, CSS media query сработает\n themeAttrs['color-scheme'] = 'light dark';\n }\n\n meta.push({ htmlAttrs: themeAttrs });\n\n // Синхронизируем store state с определённой темой для SSR\n store.core.state.theme.mode = (theme === 'dark') ? 'dark'\n : (theme === 'light') ? 'light'\n : 'system';\n\n const payload = await renderSSRHead(meta, {});\n const initialState = await store.getInitialState();\n\n performance.mark('loading-28-end');\n performance.measure('loading-28', 'loading-28-start', 'loading-28-end');\n const measure28 = performance.getEntriesByName('loading-28')[0];\n console.log(`[LOADING 28] SSR renderToString completed in ${measure28?.duration?.toFixed(2)}ms`);\n\n // Total SSR render time\n performance.measure('loading-26-total', 'loading-26-start', 'loading-28-end');\n const measure26Total = performance.getEntriesByName('loading-26-total')[0];\n console.log(`[LOADING 26] Total SSR render completed in ${measure26Total?.duration?.toFixed(2)}ms`);\n\n return {\n html,\n meta: payload,\n state: initialState,\n statusCode: router.currentRoute?.value?.name?.toLowerCase() === 'notfound' ? 404 : 200,\n usedModules: Array.from(ctx.modules || new Set()), // Return used modules\n };\n}\n"],"names":[],"mappings":";;;AAIO,SAAS,kBAAkB,EAAE,WAAW,QAAQ,CAAA,EAAE,GAAI;AAC3D,QAAM,QAAQ,YAAY;AAExB,gBAAY,KAAK,kBAAkB;AACnC,YAAQ,IAAI,gDAAgD;AAE5D,UAAM,EAAE,KAAK,QAAQ,OAAO,eAAe,OAAM,IAAK,MAAM,UAAS;AAErE,QAAI,gBAAgB,CAAA;AAGpB,QAAI,OAAO,WAAW,aAAa;AACjC,UAAI;AACF,cAAM,iBAAiB,SAAS,cAAc,uBAAuB;AACrE,YAAI,gBAAgB;AAClB,0BAAgB,KAAK,MAAM,eAAe,SAAS;AAAA,QACrD;AAAA,MACF,SAAS,GAAG;AACV,gBAAQ,MAAM,kCAAkC,CAAC;AAAA,MACnD;AAEA,YAAM,UAAU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AAO,cAAc,OAAO,MAAM,YAAW,MAAO,aAAa,MAAM;AAAA,IACnF,aAAa,MAAM,KAAK,IAAI,WAAW,oBAAI,KAAK;AAAA;AAAA,EACpD;AACA;"}
@@ -7,9 +7,9 @@ const _hoisted_2 = { class: "o-hidden flex-child-default pos-relative bg-black-t
7
7
  const _hoisted_3 = ["src"];
8
8
  const _hoisted_4 = ["src"];
9
9
  const _hoisted_5 = { class: "pd-t-small h-100 pd-medium pos-relative w-100" };
10
- const _hoisted_6 = { class: "mn-b-regular t-trim" };
11
- const _hoisted_7 = { class: "mn-b-medium p-regular t-trim-3" };
12
- const _hoisted_8 = { class: "flex-wrap mn-micro-negative flex-child-default gap-thin t-zero justify-start align-center t-trim-2" };
10
+ const _hoisted_6 = { class: "mn-b-regular truncate" };
11
+ const _hoisted_7 = { class: "mn-b-medium p-regular line-clamp-3" };
12
+ const _hoisted_8 = { class: "flex-wrap mn-micro-negative flex-child-default gap-thin t-zero justify-start align-center line-clamp-2" };
13
13
  const _sfc_main = {
14
14
  __name: "CardEvent",
15
15
  props: ["event", "user", "actions"],
@@ -113,12 +113,12 @@ const _sfc_main = {
113
113
  createElementVNode("div", _hoisted_8, [
114
114
  __props.event.date?.start ? (openBlock(), createElementBlock("span", {
115
115
  key: _ctx.index,
116
- class: "d-inline-flex mn-nano pd-thin radius-small p-regular t-medium bg-white"
116
+ class: "d-inline-flex mn-nano pd-thin radius-small p-regular fw-medium bg-white"
117
117
  }, toDisplayString(formattedDate.value) + " | " + toDisplayString(formattedTimeRange.value), 1)) : createCommentVNode("", true),
118
118
  (openBlock(true), createElementBlock(Fragment, null, renderList(__props.event.tags, (chip, index) => {
119
119
  return openBlock(), createElementBlock("span", {
120
120
  key: index,
121
- class: "d-inline-flex mn-nano pd-thin radius-small p-regular t-medium bg-main"
121
+ class: "d-inline-flex mn-nano pd-thin radius-small p-regular fw-medium bg-main"
122
122
  }, toDisplayString(chip), 1);
123
123
  }), 128))
124
124
  ])
@@ -1 +1 @@
1
- {"version":3,"file":"CardEvent.vue.js","sources":["../../../../../../../src/modules/events/components/blocks/CardEvent.vue"],"sourcesContent":["<template>\n <article\n\t class=\"pos-relative\"\n >\n\n <CardHeader\n\t class=\"mn-b-small pd-medium\"\n\t :entity=\"event\"\n\t :entityType=\"'event'\"\n\t :user=\"user\"\n\t :owner=\"event.owner\"\n \t:creator=\"event.creator\"\n \t:members=\"event.numberOfTickets\"\n \t:membersPhotos=\"event.participantsPhotos\"\n \t:type=\"'normal'\"\n \t:dateFormatted=\"daysUntilEvent\"\n \t:actions=\"actions\"\n />\n\n \t\t<div\n \t\t\tclass=\"o-hidden flex-child-default pos-relative bg-black-transp-5 mn-b-small w-100\"\n \t\t>\n\t <img v-if=\"event.cover\" loading=\"lazy\"\n\t \t:src=\"(FILE_SERVER_URL || '') + event.cover\"\n\t \talt=\"Event image\"\n\t \tclass=\"pos-relative z-index-1 d-block mn-auto w-max-100 object-fit-contain h-20r\"\n\t />\n\n\t <img v-if=\"event.cover\" loading=\"lazy\"\n\t \t:src=\"(FILE_SERVER_URL || '') + event.cover\"\n\t \talt=\"Event Background\"\n\t \tclass=\"z-index-0 pos-absolute w-100 h-100 pos-t-0 pos-r-0\"\n\t \tstyle=\"\n\t \t\ttransform: scale(1.5);\n\t \t\tfilter: blur(2rem);\n \t\t\t\t-webkit-filter: blur(2rem);\"\n\t />\n\t <IconEvents\n\t \tv-else\n\t\t\t\tclass=\"pos-relative z-index-1 d-block mn-auto w-max-100 object-fit-contain h-20r\"\n\t\t\t\tfill=\"rgb(var(--black)\"\n\t\t\t/>\n\t </div>\n\n <section\n \tclass=\"pd-t-small h-100 pd-medium pos-relative w-100\"\n >\n \n\t\t\t<h4\n \tclass=\"mn-b-regular t-trim\"\n >\n \t\t{{ event.name }}\n \t</h4>\n\n\n \t<p\n \t\tclass=\"mn-b-medium p-regular t-trim-3\"\n \t>\n \t\t{{ event.description }}\n \t</p>\n\n <slot></slot>\n<!-- \n <div v-if=\"event.status === 'draft'\" class=\"pd-micro t-white uppercase t-semi p-small flex-center flex pd-r-small pd-l-small mn-l-thin w-min bg-second radius-extra\">\n\t\t\t\t{{event.status}}\n\t\t\t</div> -->\n\n <div\n \tclass=\"flex-wrap mn-micro-negative flex-child-default gap-thin t-zero justify-start align-center t-trim-2\"\n >\n \t<span\n \t\tv-if=\"event.date?.start\"\n :key=\"index\"\n class=\"d-inline-flex mn-nano pd-thin radius-small p-regular t-medium bg-white\"\n >\n {{ formattedDate }} | {{ formattedTimeRange }}\n </span>\n\n <span\n v-for=\"(chip, index) in event.tags\"\n :key=\"index\"\n class=\"d-inline-flex mn-nano pd-thin radius-small p-regular t-medium bg-main\"\n >\n {{ chip }}\n </span>\n </div>\n\t\t<!-- <CardFooter\n\t\t\tclass=\"\"\n\t\t\t:entity=\"event\"\n\t\t\t:entityType=\"'event'\"\n\t\t\t:user=\"user\"\n\t\t/> -->\n\n </section>\n\n <!-- <FooterBlogpost class=\"pd-t-zero pd-medium\" :event=\"event\" :owner=\"owner\"/> -->\n </article>\n</template>\n\n<script setup=\"props\">\n\timport Chips from '@martyrs/src/components/Chips/Chips.vue'\n\n\timport IconEdit from '@martyrs/src/modules/icons/navigation/IconEdit.vue'\n\n\n\timport IconEvents from '@martyrs/src/modules/icons/entities/IconEvents.vue';\n\n\timport CardHeader from '@martyrs/src/modules/core/views/components/blocks/CardHeader.vue'\n\timport CardFooter from '@martyrs/src/modules/core/views/components/blocks/CardFooter.vue'\n\timport { ref, computed } from 'vue'\n\timport { useRouter } from 'vue-router'\n\n\tconst date_now = ref(new Date())\n\n\tconst router = useRouter()\n\tconst props = defineProps(['event', 'user', 'actions'])\n\n\tconst firstImage = computed(() => {\n\t\treturn props.event.content.find(block => block.type.name === 'ImageUpload');\n\t});\n\n\tconst firstText = computed(() => {\n\t\treturn props.event.content.find(block => block.type.name === 'Textarea');\n\t});\n\n // Function to calculate days until event\n const daysUntilEvent = computed(() => {\n const now = new Date();\n const nowUTC = Date.UTC(now.getUTCFullYear(), now.getUTCMonth(), now.getUTCDate(), now.getUTCHours(), now.getUTCMinutes(), now.getUTCSeconds());\n\n const start = new Date(props.event.date.start);\n const startUTC = Date.UTC(start.getUTCFullYear(), start.getUTCMonth(), start.getUTCDate(), start.getUTCHours(), start.getUTCMinutes(), start.getUTCSeconds());\n\n const diffInTime = startUTC - nowUTC;\n\n if (diffInTime < 0) {\n return 'Finished';\n }\n else if (diffInTime === 0) {\n return 'Starting Now';\n }\n else {\n const diffInSeconds = Math.floor(diffInTime / 1000);\n const diffInMinutes = Math.floor(diffInSeconds / 60);\n const diffInHours = Math.floor(diffInMinutes / 60);\n const diffInDays = Math.floor(diffInHours / 24);\n\n if (diffInDays > 0) {\n return `${diffInDays} days until event`;\n }\n else if (diffInHours > 0) {\n return `${diffInHours} hours until event`;\n }\n else if (diffInMinutes > 0) {\n return `${diffInMinutes} minutes until event`;\n }\n else {\n return `${diffInSeconds} seconds until event`;\n }\n }\n});\n\n\n /// Computed property for formatted date\n\tconst formattedDate = computed(() => {\n\t const start = new Date(props.event.date.start);\n\t const options = { day: '2-digit', month: '2-digit' };\n\t return start.toLocaleDateString(undefined, options);\n\t});\n\n\t// Computed property for time range\n\tconst formattedTimeRange = computed(() => {\n\n\t\tconsole.log(props.event.date.start)\n\t\tconsole.log(props.event.date.end)\n const start = new Date(props.event.date.start);\n const end = new Date(props.event.date.end);\n\n const startTime = new Intl.DateTimeFormat(undefined, { hour: '2-digit', minute: '2-digit', hourCycle: 'h23' }).format(start);\n const endTime = new Intl.DateTimeFormat(undefined, { hour: '2-digit', minute: '2-digit', hourCycle: 'h23' }).format(end);\n return `${startTime}-${endTime}`;\n\t});\n\n\n\t// Computed property for truncated event name\n\tconst truncatedEventName = computed(() => {\n\t const eventName = props.event.name;\n\t if (eventName.length > 26) {\n\t return `${eventName.substring(0, 22)}…`; // Truncate to 37 characters and append \"...\"\n\t }\n\t return eventName; // If less than or equal to 40 characters, return the full string\n\t});\n\n\n</script>\n\n<style lang=\"scss\">\n</style>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AAQ,IAAI,KAAK,MAAM,MAAM,KAAK,KAAK;AAC7C,YAAM,UAAU,EAAE,KAAK,WAAW,OAAO,UAAS;AAClD,aAAO,MAAM,mBAAmB,QAAW,OAAO;AAAA,IACtD,CAAC;AAGD,UAAM,qBAAqB,SAAS,MAAM;AAEzC,cAAQ,IAAI,MAAM,MAAM,KAAK,KAAK;AAClC,cAAQ,IAAI,MAAM,MAAM,KAAK,GAAG;AAC9B,YAAM,QAAQ,IAAI,KAAK,MAAM,MAAM,KAAK,KAAK;AAC7C,YAAM,MAAM,IAAI,KAAK,MAAM,MAAM,KAAK,GAAG;AAEzC,YAAM,YAAY,IAAI,KAAK,eAAe,QAAW,EAAE,MAAM,WAAW,QAAQ,WAAW,WAAW,MAAK,CAAE,EAAE,OAAO,KAAK;AAC3H,YAAM,UAAU,IAAI,KAAK,eAAe,QAAW,EAAE,MAAM,WAAW,QAAQ,WAAW,WAAW,MAAK,CAAE,EAAE,OAAO,GAAG;AACvH,aAAO,GAAG,SAAS,IAAI,OAAO;AAAA,IACjC,CAAC;AAI0B,aAAS,MAAM;AACxC,YAAM,YAAY,MAAM,MAAM;AAC9B,UAAI,UAAU,SAAS,IAAI;AACzB,eAAO,GAAG,UAAU,UAAU,GAAG,EAAE,CAAC;AAAA,MACtC;AACA,aAAO;AAAA,IACT,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"CardEvent.vue.js","sources":["../../../../../../../src/modules/events/components/blocks/CardEvent.vue"],"sourcesContent":["<template>\n <article\n\t class=\"pos-relative\"\n >\n\n <CardHeader\n\t class=\"mn-b-small pd-medium\"\n\t :entity=\"event\"\n\t :entityType=\"'event'\"\n\t :user=\"user\"\n\t :owner=\"event.owner\"\n \t:creator=\"event.creator\"\n \t:members=\"event.numberOfTickets\"\n \t:membersPhotos=\"event.participantsPhotos\"\n \t:type=\"'normal'\"\n \t:dateFormatted=\"daysUntilEvent\"\n \t:actions=\"actions\"\n />\n\n \t\t<div\n \t\t\tclass=\"o-hidden flex-child-default pos-relative bg-black-transp-5 mn-b-small w-100\"\n \t\t>\n\t <img v-if=\"event.cover\" loading=\"lazy\"\n\t \t:src=\"(FILE_SERVER_URL || '') + event.cover\"\n\t \talt=\"Event image\"\n\t \tclass=\"pos-relative z-index-1 d-block mn-auto w-max-100 object-fit-contain h-20r\"\n\t />\n\n\t <img v-if=\"event.cover\" loading=\"lazy\"\n\t \t:src=\"(FILE_SERVER_URL || '') + event.cover\"\n\t \talt=\"Event Background\"\n\t \tclass=\"z-index-0 pos-absolute w-100 h-100 pos-t-0 pos-r-0\"\n\t \tstyle=\"\n\t \t\ttransform: scale(1.5);\n\t \t\tfilter: blur(2rem);\n \t\t\t\t-webkit-filter: blur(2rem);\"\n\t />\n\t <IconEvents\n\t \tv-else\n\t\t\t\tclass=\"pos-relative z-index-1 d-block mn-auto w-max-100 object-fit-contain h-20r\"\n\t\t\t\tfill=\"rgb(var(--black)\"\n\t\t\t/>\n\t </div>\n\n <section\n \tclass=\"pd-t-small h-100 pd-medium pos-relative w-100\"\n >\n \n\t\t\t<h4\n \tclass=\"mn-b-regular truncate\"\n >\n \t\t{{ event.name }}\n \t</h4>\n\n\n \t<p\n \t\tclass=\"mn-b-medium p-regular line-clamp-3\"\n \t>\n \t\t{{ event.description }}\n \t</p>\n\n <slot></slot>\n<!-- \n <div v-if=\"event.status === 'draft'\" class=\"pd-micro t-white uppercase fw-semi p-small flex-center flex pd-r-small pd-l-small mn-l-thin w-min bg-second radius-extra\">\n\t\t\t\t{{event.status}}\n\t\t\t</div> -->\n\n <div\n \tclass=\"flex-wrap mn-micro-negative flex-child-default gap-thin t-zero justify-start align-center line-clamp-2\"\n >\n \t<span\n \t\tv-if=\"event.date?.start\"\n :key=\"index\"\n class=\"d-inline-flex mn-nano pd-thin radius-small p-regular fw-medium bg-white\"\n >\n {{ formattedDate }} | {{ formattedTimeRange }}\n </span>\n\n <span\n v-for=\"(chip, index) in event.tags\"\n :key=\"index\"\n class=\"d-inline-flex mn-nano pd-thin radius-small p-regular fw-medium bg-main\"\n >\n {{ chip }}\n </span>\n </div>\n\t\t<!-- <CardFooter\n\t\t\tclass=\"\"\n\t\t\t:entity=\"event\"\n\t\t\t:entityType=\"'event'\"\n\t\t\t:user=\"user\"\n\t\t/> -->\n\n </section>\n\n <!-- <FooterBlogpost class=\"pd-t-zero pd-medium\" :event=\"event\" :owner=\"owner\"/> -->\n </article>\n</template>\n\n<script setup=\"props\">\n\timport Chips from '@martyrs/src/components/Chips/Chips.vue'\n\n\timport IconEdit from '@martyrs/src/modules/icons/navigation/IconEdit.vue'\n\n\n\timport IconEvents from '@martyrs/src/modules/icons/entities/IconEvents.vue';\n\n\timport CardHeader from '@martyrs/src/modules/core/views/components/blocks/CardHeader.vue'\n\timport CardFooter from '@martyrs/src/modules/core/views/components/blocks/CardFooter.vue'\n\timport { ref, computed } from 'vue'\n\timport { useRouter } from 'vue-router'\n\n\tconst date_now = ref(new Date())\n\n\tconst router = useRouter()\n\tconst props = defineProps(['event', 'user', 'actions'])\n\n\tconst firstImage = computed(() => {\n\t\treturn props.event.content.find(block => block.type.name === 'ImageUpload');\n\t});\n\n\tconst firstText = computed(() => {\n\t\treturn props.event.content.find(block => block.type.name === 'Textarea');\n\t});\n\n // Function to calculate days until event\n const daysUntilEvent = computed(() => {\n const now = new Date();\n const nowUTC = Date.UTC(now.getUTCFullYear(), now.getUTCMonth(), now.getUTCDate(), now.getUTCHours(), now.getUTCMinutes(), now.getUTCSeconds());\n\n const start = new Date(props.event.date.start);\n const startUTC = Date.UTC(start.getUTCFullYear(), start.getUTCMonth(), start.getUTCDate(), start.getUTCHours(), start.getUTCMinutes(), start.getUTCSeconds());\n\n const diffInTime = startUTC - nowUTC;\n\n if (diffInTime < 0) {\n return 'Finished';\n }\n else if (diffInTime === 0) {\n return 'Starting Now';\n }\n else {\n const diffInSeconds = Math.floor(diffInTime / 1000);\n const diffInMinutes = Math.floor(diffInSeconds / 60);\n const diffInHours = Math.floor(diffInMinutes / 60);\n const diffInDays = Math.floor(diffInHours / 24);\n\n if (diffInDays > 0) {\n return `${diffInDays} days until event`;\n }\n else if (diffInHours > 0) {\n return `${diffInHours} hours until event`;\n }\n else if (diffInMinutes > 0) {\n return `${diffInMinutes} minutes until event`;\n }\n else {\n return `${diffInSeconds} seconds until event`;\n }\n }\n});\n\n\n /// Computed property for formatted date\n\tconst formattedDate = computed(() => {\n\t const start = new Date(props.event.date.start);\n\t const options = { day: '2-digit', month: '2-digit' };\n\t return start.toLocaleDateString(undefined, options);\n\t});\n\n\t// Computed property for time range\n\tconst formattedTimeRange = computed(() => {\n\n\t\tconsole.log(props.event.date.start)\n\t\tconsole.log(props.event.date.end)\n const start = new Date(props.event.date.start);\n const end = new Date(props.event.date.end);\n\n const startTime = new Intl.DateTimeFormat(undefined, { hour: '2-digit', minute: '2-digit', hourCycle: 'h23' }).format(start);\n const endTime = new Intl.DateTimeFormat(undefined, { hour: '2-digit', minute: '2-digit', hourCycle: 'h23' }).format(end);\n return `${startTime}-${endTime}`;\n\t});\n\n\n\t// Computed property for truncated event name\n\tconst truncatedEventName = computed(() => {\n\t const eventName = props.event.name;\n\t if (eventName.length > 26) {\n\t return `${eventName.substring(0, 22)}…`; // Truncate to 37 characters and append \"...\"\n\t }\n\t return eventName; // If less than or equal to 40 characters, return the full string\n\t});\n\n\n</script>\n\n<style lang=\"scss\">\n</style>\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAgHkB,QAAI,oBAAI,KAAI,CAAE;AAEhB,cAAS;AACxB,UAAM,QAAQ;AAEK,aAAS,MAAM;AACjC,aAAO,MAAM,MAAM,QAAQ,KAAK,WAAS,MAAM,KAAK,SAAS,aAAa;AAAA,IAC3E,CAAC;AAEiB,aAAS,MAAM;AAChC,aAAO,MAAM,MAAM,QAAQ,KAAK,WAAS,MAAM,KAAK,SAAS,UAAU;AAAA,IACxE,CAAC;AAGA,UAAM,iBAAi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C,YAAM,MAAM,IAAI,KAAK,MAAM,MAAM,KAAK,GAAG;AAEzC,YAAM,YAAY,IAAI,KAAK,eAAe,QAAW,EAAE,MAAM,WAAW,QAAQ,WAAW,WAAW,MAAK,CAAE,EAAE,OAAO,KAAK;AAC3H,YAAM,UAAU,IAAI,KAAK,eAAe,QAAW,EAAE,MAAM,WAAW,QAAQ,WAAW,WAAW,MAAK,CAAE,EAAE,OAAO,GAAG;AACvH,aAAO,GAAG,SAAS,IAAI,OAAO;AAAA,IACjC,CAAC;AAI0B,aAAS,MAAM;AACxC,YAAM,YAAY,MAAM,MAAM;AAC9B,UAAI,UAAU,SAAS,IAAI;AACzB,eAAO,GAAG,UAAU,UAAU,GAAG,EAAE,CAAC;AAAA,MACtC;AACA,aAAO;AAAA,IACT,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -4,8 +4,8 @@ import { useRouter } from "vue-router";
4
4
  const _hoisted_1 = { class: "flex-nowrap flex-v-center flex pos-relative" };
5
5
  const _hoisted_2 = { class: "flex-nowrap flex flex-v-center pos-relative w-100" };
6
6
  const _hoisted_3 = { class: "order-2 mn-l-thin flex-v-center flex-nowrap flex" };
7
- const _hoisted_4 = { class: "t-semi t-truncate uppercase" };
8
- const _hoisted_5 = { class: "order-1 flex-wrap mn-micro-negative flex-child-default gap-thin t-zero justify-start align-center t-trim-2" };
7
+ const _hoisted_4 = { class: "fw-semi truncate uppercase" };
8
+ const _hoisted_5 = { class: "order-1 flex-wrap mn-micro-negative flex-child-default gap-thin t-zero justify-start align-center line-clamp-2" };
9
9
  const _sfc_main = {
10
10
  __name: "CardEventShort",
11
11
  props: ["event", "user", "actions"],
@@ -66,7 +66,7 @@ const _sfc_main = {
66
66
  createElementVNode("div", _hoisted_5, [
67
67
  __props.event.date?.start ? (openBlock(), createElementBlock("span", {
68
68
  key: _ctx.index,
69
- class: "p-regular d-inline-flex p-medium t-medium mn-nano pd-thin radius-small bg-white"
69
+ class: "p-regular d-inline-flex p-medium fw-medium mn-nano pd-thin radius-small bg-white"
70
70
  }, toDisplayString(formattedDate.value), 1)) : createCommentVNode("", true)
71
71
  ])
72
72
  ])
@@ -1 +1 @@
1
- {"version":3,"file":"CardEventShort.vue.js","sources":["../../../../../../../src/modules/events/components/blocks/CardEventShort.vue"],"sourcesContent":["<template>\n <article\n\t class=\"flex-nowrap flex-v-center flex pos-relative\"\n >\n\n <CardHeader\n\t class=\"flex-child-order-last flex-child mn-l-small\"\n\t :entity=\"event\"\n\t :entityType=\"'event'\"\n\t :user=\"user\"\n\t :owner=\"event.owner\"\n \t:creator=\"event.creator\"\n \t:members=\"event.numberOfTickets\"\n \t:membersPhotos=\"event.participantsPhotos\"\n \t:type=\"'short'\"\n \t:dateFormatted=\"daysUntilEvent\"\n \t:actions=\"actions\"\n />\n\n <section\n \tclass=\"flex-nowrap flex flex-v-center pos-relative w-100\"\n >\n \t<div\n \t\tclass=\"order-2 mn-l-thin flex-v-center flex-nowrap flex\"\n \t>\n\t\t\t<span\n\t\t \tclass=\"t-semi t-truncate uppercase\"\n\t\t >\n \t{{ event.name }}\n\t\t </span>\n\t\t</div>\n\n <div\n \tclass=\"order-1 flex-wrap mn-micro-negative flex-child-default gap-thin t-zero justify-start align-center t-trim-2\"\n >\n \t<span\n \t\tv-if=\"event.date?.start\"\n :key=\"index\"\n class=\"p-regular d-inline-flex p-medium t-medium mn-nano pd-thin radius-small bg-white\"\n >\n {{ formattedDate }}\n </span>\n </div>\n\n </section>\n\n </article>\n</template>\n\n<script setup=\"props\">\n\timport CardHeader from '@martyrs/src/modules/core/views/components/blocks/CardHeader.vue'\n\timport { ref, computed } from 'vue'\n\timport { useRouter } from 'vue-router'\n\n\tconst date_now = ref(new Date())\n\n\tconst router = useRouter()\n\tconst props = defineProps(['event', 'user', 'actions'])\n\n // Function to calculate days until event\n const daysUntilEvent = computed(() => {\n const now = new Date();\n const nowUTC = Date.UTC(now.getUTCFullYear(), now.getUTCMonth(), now.getUTCDate(), now.getUTCHours(), now.getUTCMinutes(), now.getUTCSeconds());\n\n const start = new Date(props.event.date.start);\n const startUTC = Date.UTC(start.getUTCFullYear(), start.getUTCMonth(), start.getUTCDate(), start.getUTCHours(), start.getUTCMinutes(), start.getUTCSeconds());\n\n const diffInTime = startUTC - nowUTC;\n\n if (diffInTime < 0) {\n return 'Finished';\n }\n else if (diffInTime === 0) {\n return 'Starting Now';\n }\n else {\n const diffInSeconds = Math.floor(diffInTime / 1000);\n const diffInMinutes = Math.floor(diffInSeconds / 60);\n const diffInHours = Math.floor(diffInMinutes / 60);\n const diffInDays = Math.floor(diffInHours / 24);\n\n if (diffInDays > 0) {\n return `${diffInDays} days until event`;\n }\n else if (diffInHours > 0) {\n return `${diffInHours} hours until event`;\n }\n else if (diffInMinutes > 0) {\n return `${diffInMinutes} minutes until event`;\n }\n else {\n return `${diffInSeconds} seconds until event`;\n }\n }\n});\n\n\n /// Computed property for formatted date\n\tconst formattedDate = computed(() => {\n\t const start = new Date(props.event.date.start);\n\t const options = { day: '2-digit', month: '2-digit' };\n\t return start.toLocaleDateString(undefined, options);\n\t});\n\n</script>\n\n<style lang=\"scss\">\n</style>\n"],"names":[],"mappings":";;;;;;;;;;;;AAsDkB,QAAI,oBAAI,KAAI,CAAE;AAEhB,cAAS;AACxB,UAAM,QAAQ;AAGb,UAAM,iBAAiB,SAAS,MAAM;AACpC,YAAM,MAAM,oBAAI,KAAI;AACpB,YAAM,SAAS,KAAK,IAAI,IAAI,kBAAkB,IAAI,eAAe,IAAI,cAAc,IAAI,eAAe,IAAI,iBAAiB,IAAI,eAAe;AAE9I,YAAM,QAAQ,IAAI,KAAK,MAAM,MAAM,KAAK,KAAK;AAC7C,YAAM,WAAW,KAAK,IAAI,MAAM,kBAAkB,MAAM,eAAe,MAAM,cAAc,MAAM,eAAe,MAAM,iBAAiB,MAAM,eAAe;AAE5J,YAAM,aAAa,WAAW;AAE9B,UAAI,aAAa,GAAG;AAClB,eAAO;AAAA,MACT,WACS,eAAe,GAAG;AACzB,eAAO;AAAA,MACT,OACK;AACH,cAAM,gBAAgB,KAAK,MAAM,aAAa,GAAI;AAClD,cAAM,gBAAgB,KAAK,MAAM,gBAAgB,EAAE;AACnD,cAAM,cAAc,KAAK,MAAM,gBAAgB,EAAE;AACjD,cAAM,aAAa,KAAK,MAAM,cAAc,EAAE;AAE9C,YAAI,aAAa,GAAG;AAClB,iBAAO,GAAG,UAAU;AAAA,QACtB,WACS,cAAc,GAAG;AACxB,iBAAO,GAAG,WAAW;AAAA,QACvB,WACS,gBAAgB,GAAG;AAC1B,iBAAO,GAAG,aAAa;AAAA,QACzB,OACK;AACH,iBAAO,GAAG,aAAa;AAAA,QACzB;AAAA,MACF;AAAA,IACJ,CAAC;AAIA,UAAM,gBAAgB,SAAS,MAAM;AACjC,YAAM,QAAQ,IAAI,KAAK,MAAM,MAAM,KAAK,KAAK;AAC7C,YAAM,UAAU,EAAE,KAAK,WAAW,OAAO,UAAS;AAClD,aAAO,MAAM,mBAAmB,QAAW,OAAO;AAAA,IACtD,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"CardEventShort.vue.js","sources":["../../../../../../../src/modules/events/components/blocks/CardEventShort.vue"],"sourcesContent":["<template>\n <article\n\t class=\"flex-nowrap flex-v-center flex pos-relative\"\n >\n\n <CardHeader\n\t class=\"flex-child-order-last flex-child mn-l-small\"\n\t :entity=\"event\"\n\t :entityType=\"'event'\"\n\t :user=\"user\"\n\t :owner=\"event.owner\"\n \t:creator=\"event.creator\"\n \t:members=\"event.numberOfTickets\"\n \t:membersPhotos=\"event.participantsPhotos\"\n \t:type=\"'short'\"\n \t:dateFormatted=\"daysUntilEvent\"\n \t:actions=\"actions\"\n />\n\n <section\n \tclass=\"flex-nowrap flex flex-v-center pos-relative w-100\"\n >\n \t<div\n \t\tclass=\"order-2 mn-l-thin flex-v-center flex-nowrap flex\"\n \t>\n\t\t\t<span\n\t\t \tclass=\"fw-semi truncate uppercase\"\n\t\t >\n \t{{ event.name }}\n\t\t </span>\n\t\t</div>\n\n <div\n \tclass=\"order-1 flex-wrap mn-micro-negative flex-child-default gap-thin t-zero justify-start align-center line-clamp-2\"\n >\n \t<span\n \t\tv-if=\"event.date?.start\"\n :key=\"index\"\n class=\"p-regular d-inline-flex p-medium fw-medium mn-nano pd-thin radius-small bg-white\"\n >\n {{ formattedDate }}\n </span>\n </div>\n\n </section>\n\n </article>\n</template>\n\n<script setup=\"props\">\n\timport CardHeader from '@martyrs/src/modules/core/views/components/blocks/CardHeader.vue'\n\timport { ref, computed } from 'vue'\n\timport { useRouter } from 'vue-router'\n\n\tconst date_now = ref(new Date())\n\n\tconst router = useRouter()\n\tconst props = defineProps(['event', 'user', 'actions'])\n\n // Function to calculate days until event\n const daysUntilEvent = computed(() => {\n const now = new Date();\n const nowUTC = Date.UTC(now.getUTCFullYear(), now.getUTCMonth(), now.getUTCDate(), now.getUTCHours(), now.getUTCMinutes(), now.getUTCSeconds());\n\n const start = new Date(props.event.date.start);\n const startUTC = Date.UTC(start.getUTCFullYear(), start.getUTCMonth(), start.getUTCDate(), start.getUTCHours(), start.getUTCMinutes(), start.getUTCSeconds());\n\n const diffInTime = startUTC - nowUTC;\n\n if (diffInTime < 0) {\n return 'Finished';\n }\n else if (diffInTime === 0) {\n return 'Starting Now';\n }\n else {\n const diffInSeconds = Math.floor(diffInTime / 1000);\n const diffInMinutes = Math.floor(diffInSeconds / 60);\n const diffInHours = Math.floor(diffInMinutes / 60);\n const diffInDays = Math.floor(diffInHours / 24);\n\n if (diffInDays > 0) {\n return `${diffInDays} days until event`;\n }\n else if (diffInHours > 0) {\n return `${diffInHours} hours until event`;\n }\n else if (diffInMinutes > 0) {\n return `${diffInMinutes} minutes until event`;\n }\n else {\n return `${diffInSeconds} seconds until event`;\n }\n }\n});\n\n\n /// Computed property for formatted date\n\tconst formattedDate = computed(() => {\n\t const start = new Date(props.event.date.start);\n\t const options = { day: '2-digit', month: '2-digit' };\n\t return start.toLocaleDateString(undefined, options);\n\t});\n\n</script>\n\n<style lang=\"scss\">\n</style>\n"],"names":[],"mappings":";;;;;;;;;;;;AAsDkB,QAAI,oBAAI,KAAI,CAAE;AAEhB,cAAS;AACxB,UAAM,QAAQ;AAGb,UAAM,iBAAiB,SAAS,MAAM;AACpC,YAAM,MAAM,oBAAI,KAAI;AACpB,YAAM,SAAS,KAAK,IAAI,IAAI,kBAAkB,IAAI,eAAe,IAAI,cAAc,IAAI,eAAe,IAAI,iBAAiB,IAAI,eAAe;AAE9I,YAAM,QAAQ,IAAI,KAAK,MAAM,MAAM,KAAK,KAAK;AAC7C,YAAM,WAAW,KAAK,IAAI,MAAM,kBAAkB,MAAM,eAAe,MAAM,cAAc,MAAM,eAAe,MAAM,iBAAiB,MAAM,eAAe;AAE5J,YAAM,aAAa,WAAW;AAE9B,UAAI,aAAa,GAAG;AAClB,eAAO;AAAA,MACT,WACS,eAAe,GAAG;AACzB,eAAO;AAAA,MACT,OACK;AACH,cAAM,gBAAgB,KAAK,MAAM,aAAa,GAAI;AAClD,cAAM,gBAAgB,KAAK,MAAM,gBAAgB,EAAE;AACnD,cAAM,cAAc,KAAK,MAAM,gBAAgB,EAAE;AACjD,cAAM,aAAa,KAAK,MAAM,cAAc,EAAE;AAE9C,YAAI,aAAa,GAAG;AAClB,iBAAO,GAAG,UAAU;AAAA,QACtB,WACS,cAAc,GAAG;AACxB,iBAAO,GAAG,WAAW;AAAA,QACvB,WACS,gBAAgB,GAAG;AAC1B,iBAAO,GAAG,aAAa;AAAA,QACzB,OACK;AACH,iBAAO,GAAG,aAAa;AAAA,QACzB;AAAA,MACF;AAAA,IACJ,CAAC;AAIA,UAAM,gBAAgB,SAAS,MAAM;AACjC,YAAM,QAAQ,IAAI,KAAK,MAAM,MAAM,KAAK,KAAK;AAC7C,YAAM,UAAU,EAAE,KAAK,WAAW,OAAO,UAAS;AAClD,aAAO,MAAM,mBAAmB,QAAW,OAAO;AAAA,IACtD,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -8,12 +8,12 @@ import _sfc_main$5 from "../../../../components/Popup/Popup.vue.js";
8
8
  import Field from "../../../../components/Field/Field.vue.js";
9
9
  import _sfc_main$6 from "../../../../components/FieldTags/BlockTags.vue.js";
10
10
  import _sfc_main$9 from "../../../../components/Checkbox/Checkbox.vue.js";
11
- /* empty css */
11
+ /* empty css */
12
12
  import "axios";
13
13
  /* empty css */
14
14
  import UploadImage from "../../../../components/UploadImage/UploadImage.vue.js";
15
- /* empty css */
16
- /* empty css */
15
+ /* empty css */
16
+ /* empty css */
17
17
  import _sfc_main$8 from "../../../../components/Feed/Feed.vue.js";
18
18
  import _sfc_main$a from "../../../../components/Button/Button.vue2.js";
19
19
  import _sfc_main$7 from "../../../core/views/components/blocks/Card.vue.js";
@@ -51,7 +51,7 @@ const _hoisted_9 = {
51
51
  };
52
52
  const _hoisted_10 = {
53
53
  key: 3,
54
- class: "mn-b-medium br-grey-transp-25 br-2px br-solid pd-small radius-big"
54
+ class: "mn-b-medium br-grey-transp-25 br-2px pd-small radius-big"
55
55
  };
56
56
  const _sfc_main = {
57
57
  __name: "EditEvent",
@@ -1 +1 @@
1
- {"version":3,"file":"EditEvent.vue.js","sources":["../../../../../../../src/modules/events/components/pages/EditEvent.vue"],"sourcesContent":["<template>\n <article v-if=\"event\" class=\"h-min-100 pd-thin\">\n <div class=\"pd-medium radius-medium mn-b-thin bg-light\">\n <h4 class=\"mn-b-small\">Basic Info</h4>\n \t<div class=\"mn-b-thin radius-small w-100 h-10r bg-white flex-center flex-column flex\">\n \t<UploadImage \n v-model:photo=\"event.cover\"\n :uploadPath=\"'specials'\"\n class=\"h-4r w-4r aspect-1x1 o-hidden mn-b-thin radius-extra\" \n />\n <h4>Upload Event Cover</h4>\n </div>\n\n \t<Field \n v-model:field=\"event.name\" \n label=\"Name\"\n placeholder=\"Event name\" \n class=\"mn-b-thin w-100 bg-white pd-medium radius-small\" \n />\n <Field \n v-model:field=\"event.description\" \n type=\"textarea\" \n placeholder=\"Enter short description\" \n class=\"mn-b-thin w-100 bg-white pd-medium radius-small\" \n />\n <Field\n v-model:field=\"event.location\"\n label=\"Location\"\n placeholder=\"Event location\"\n class=\"mn-b-thin w-100 bg-white pd-medium radius-small\"\n />\n </div>\n\n <Block\n title=\"Schedule\"\n placeholder=\"No schedule periods added yet\"\n :actions=\"[{\n label: '+',\n function: addSchedulePeriod\n }]\"\n class=\"cols-1 mn-b-thin t-black gap-thin\"\n >\n <div\n class=\"mn-b-thin gap-small flex-nowrap flex\"\n v-for=\"(period, index) in event.schedule\"\n :key=\"index\"\n >\n <FieldDate\n v-model=\"period.start\"\n :allowRange=\"false\"\n :enableTime=\"true\"\n :disablePastDates=\"!isBackoffice\"\n :disabledRanges=\"getDisabledRangesForPeriod(index)\"\n :showSelected=\"true\"\n :locale=\"$i18n.locale\"\n label=\"Start\"\n placeholder=\"Start time\"\n class=\"w-100 bg-white radius-small pd-medium\"\n />\n <FieldDate\n v-model=\"period.end\"\n :allowRange=\"false\"\n :enableTime=\"true\"\n :disablePastDates=\"!isBackoffice\"\n :disabledRanges=\"getDisabledRangesForPeriod(index)\"\n :showSelected=\"true\"\n :locale=\"$i18n.locale\"\n label=\"End\"\n placeholder=\"End time\"\n class=\"w-100 bg-white radius-small pd-medium\"\n />\n <div v-if=\"index > 0\" @click=\"() => event.schedule.splice(index, 1)\" class=\"radius-small h-100 i-big flex-center flex aspect-1x1 bg-red\">\n <IconDelete class=\"i-medium\" />\n </div>\n </div>\n </Block>\n\n <EditTickets v-model:tickets=\"event.ticketsTypes\" />\n\n\t\t<section v-if=\"event\" class=\"pd-b-extra z-index-1 pos-relative w-100 bg-light pd-big radius-medium\">\n <Constructor \n :content=\"event.content\"\n :autoFocus=\"false\" \n @update=\"update => event.content = update\"\n />\n </section>\n\n <section v-if=\"event\" class=\"pd-small z-index-2 pos-sticky pos-l-0 pos-b-0 w-100 \">\n <div class=\"pd-thin radius-regular bg-main w-100 flex-nowrap flex\">\n <a v-if=\"route.params.url\" @click=\"onDelete()\" class=\"mn-r-auto bg-red t-white t-black button\"><span>Delete</span></a>\n <a @click=\"onDrafts()\" class=\"mn-l-auto bg-white t-black button\"><span>To Drafts</span></a>\n <a @click=\"openPublicationPopup()\" class=\"mn-l-thin bg-black t-white button\"><span>Publish</span></a>\n </div>\n </section>\n\n <Popup \n title=\"Final Touches\" \n @close-popup=\"closePublicationPopup\" \n :isPopupOpen=\"isPublicationPopup\"\n class=\"w-m-33r t-left pd-big bg-white radius-big\"\n > \n <BlockTags\n @tags-changed=\"newTags => event.tags = newTags\"\n :tags=\"event.tags\"\n class=\"mn-b-small\"\n />\n\n <h5 class=\"mn-b-small\">Add to public</h5>\n <Card\n v-if=\"selectedOrganization\"\n :photo=\"selectedOrganization.profile?.photo\"\n :title=\"selectedOrganization.profile?.name\"\n @click=\"() => { \n selectedOrganization = null\n }\"\n class=\"h-4r w-100 bg-light pd-thin radius-medium mn-b-thin\"\n />\n\n <section v-else class=\"mn-b-thin h-25r o-x-hidden o-y-scroll bg-light radius-big pd-small \">\n <Feed\n :showLoadMore=\"false\" \n :search=\"{\n placeholder: 'Search organization...',\n class: 'bg-white mn-b-thin'\n }\"\n :states=\"{\n empty: {\n title: 'No organizations Found',\n description: 'Currently, there are no such organizations available.'\n }\n }\"\n :store=\"{\n read: (options) => organizations.actions.read(options),\n state: null\n }\"\n :options=\"{\n user: auth.state.user._id,\n postable: auth.state.user._id,\n lookup: ['memberships']\n }\"\n v-slot=\"{ \n items \n }\"\n >\n <Card\n v-for=\"(organization, index) in items\" \n v-memo=\"[organization._id, organization.profile.name]\"\n :photo=\"organization.profile?.photo\"\n :title=\"organization.profile?.name\"\n @click=\"() => { \n selectedOrganization = organization\n }\"\n class=\"h-4r bg-white pd-thin radius-medium w-100 mn-b-thin\"\n />\n </Feed>\n </section>\n\n \n <h5 v-if=\"selectedOrganization\" class=\"mn-b-thin\">Options:</h5>\n <div v-if=\"selectedOrganization\" class=\"mn-b-medium br-grey-transp-25 br-2px br-solid pd-small radius-big\">\n <Checkbox \n :label=\"'Hide Author'\"\n :radio=\"event.creator.hidden\"\n @update:radio=\"updateEvent => event.creator.hidden = updateEvent\"\n name=\"prices\"\n class=\"w-100\"\n />\n </div>\n <Button :submit=\"onSubmit\" :callback=\"redirectTo\" class=\"w-100 bg-black t-white\">Publish</Button>\n </Popup>\n </article>\n\n</template>\n\n<script setup>\nimport Textarea from '@martyrs/src/modules/constructor/components/elements/Textarea.vue';\nimport Constructor from '@martyrs/src/modules/constructor/components/sections/Constructor.vue';\n\nimport FieldDate from '@martyrs/src/components/FieldDate/FieldDate.vue'\n\nimport Block from '@martyrs/src/components/Block/Block.vue';\nimport Popup from '@martyrs/src/components/Popup/Popup.vue';\nimport Field from '@martyrs/src/components/Field/Field.vue'\nimport BlockTags from '@martyrs/src/components/FieldTags/BlockTags.vue';\nimport Checkbox from '@martyrs/src/components/Checkbox/Checkbox.vue';\nimport SelectMulti from '@martyrs/src/components/SelectMulti/SelectMulti.vue';\nimport Upload from '@martyrs/src/components/Upload/Upload.vue';\nimport UploadImage from '@martyrs/src/components/UploadImage/UploadImage.vue';\nimport EditImages from '@martyrs/src/components/EditImages/EditImages.vue';\nimport Feed from '@martyrs/src/components/Feed/Feed.vue'\nimport Button from '@martyrs/src/components/Button/Button.vue'; \n\nimport Card from '@martyrs/src/modules/core/views/components/blocks/Card.vue';\n\nimport EditTickets from '@martyrs/src/modules/events/components/sections/EditTickets.vue';\n\nimport IconDelete from '@martyrs/src/modules/icons/navigation/IconDelete.vue';\n\nimport { ref, computed, onMounted } from 'vue';\nimport { useRoute, useRouter } from 'vue-router';\n\nimport { useGlobalMixins } from \"@martyrs/src/modules/core/views/mixins/mixins.js\"\n\nimport * as events from '@martyrs/src/modules/events/store/events.js';\nimport * as auth from '@martyrs/src/modules/auth/views/store/auth.js';\nimport * as organizations from '@martyrs/src/modules/organizations/store/organizations.js';\n\nconst route = useRoute();\nconst router = useRouter();\n\nconst { hasAccess } = useGlobalMixins()\n\nconst isBackoffice = computed(() => route.meta?.context === 'backoffice')\n\nlet event = ref(null);\nlet publics = ref(null);\n\nconst selectedTags = ref([]);\nconst selectedOrganization = ref(null);\n\nonMounted(async () =>{\n\n if (route.params.url) {\n const data = await events.read({ user: auth.state.user._id, url: route.params.url });\n\n event.value = data.pop();\n\n if (!event.value) {\n router.push({name: 'notfound'})\n }\n\n if (event.value.owner.type === 'organization') {\n // Если пост принадлежит организации, проверяем права на редактирование через `hasAccess`\n const isAccess = hasAccess(event.value.owner.target._id, 'events', 'edit', auth.state.accesses, auth.state.access.roles);\n\n if (!isAccess) {\n router.push({name: 'unauthorized'})\n }\n }\n\n if (event.value.owner.type === 'user' && event.value.creator.target._id !== auth.state.user._id) {\n console.log(event.value.creator.target)\n console.log(auth.state.user._id)\n router.push({name: 'unauthorized'})\n }\n\n } else {\n events.clean();\n event.value = events.state.current;\n }\n\n if (!event.value.owner) event.value.owner = {\n target: auth.state.user._id,\n type: 'user'\n }\n\n if (!event.value.creator) event.value.creator = {\n target: auth.state.user._id,\n type: 'user',\n hidden: false\n }\n\n if (!event.value.schedule || event.value.schedule.length === 0) {\n event.value.schedule = [{\n start: new Date(),\n end: new Date()\n }]\n }\n\n if (event.value.owner.type === 'organization') selectedOrganization.value = {\n _id: event.value.owner.target._id,\n profile: {\n name: event.value.owner.target.profile.name,\n photo: event.value.owner.target.profile.photo\n }\n }\n})\n\nconst isPublicationPopup = ref(false)\n\nfunction openPublicationPopup() {\n isPublicationPopup.value = true;\n}\nfunction closePublicationPopup() {\n isPublicationPopup.value = false;\n}\n\nfunction addSchedulePeriod() {\n event.value.schedule.push({\n start: new Date(),\n end: new Date()\n })\n}\n\nfunction getDisabledRangesForPeriod(currentIndex) {\n if (!event.value.schedule) return []\n\n return event.value.schedule\n .map((period, index) => {\n if (index === currentIndex) return null\n if (!period.start || !period.end) return null\n return {\n start: new Date(period.start),\n end: new Date(period.end)\n }\n })\n .filter(range => range !== null)\n}\n\nfunction onDrafts() {\n if (selectedTags.value.length > 0) selectedTags.value.map(tag => (tag.text))\n\n // Auto-select organization in organization context\n if (route.params._id && !selectedOrganization.value) {\n event.value.owner = {\n target: route.params._id,\n type: 'organization'\n }\n }\n\n event.value.status = \"draft\"\n\n // Calculate event.date from schedule\n if (event.value.schedule && event.value.schedule.length > 0) {\n const allDates = event.value.schedule\n .flatMap(period => [period.start, period.end])\n .filter(date => date !== null && date !== undefined)\n .map(date => new Date(date))\n\n event.value.date = {\n start: new Date(Math.min(...allDates)),\n end: new Date(Math.max(...allDates))\n }\n }\n\n if (route.params.url) {\n events.update(event.value)\n .then(response => {\n router.push({ name: 'Event', params: { url: response.url } });\n })\n .catch(error => {\n console.error(error);\n })\n } else {\n events.create(event.value)\n .then(response => {\n router.push({ name: 'Event', params: { url: response.url } });\n })\n .catch(error => {\n console.error(error);\n })\n }\n}\n\nfunction onSubmit() {\n if (selectedOrganization.value) event.value.owner = {\n target: selectedOrganization.value._id,\n type: 'organization'\n }\n\n if (!selectedOrganization.value) event.value.creator.hidden = false\n if (!selectedOrganization.value) event.value.organization = event.value.creator\n\n event.value.status = \"published\"\n\n // Calculate event.date from schedule\n if (event.value.schedule && event.value.schedule.length > 0) {\n const allDates = event.value.schedule\n .flatMap(period => [period.start, period.end])\n .filter(date => date !== null && date !== undefined)\n .map(date => new Date(date))\n\n event.value.date = {\n start: new Date(Math.min(...allDates)),\n end: new Date(Math.max(...allDates))\n }\n }\n if (route.params.url) {\n console.log(event.value)\n events.update(event.value)\n .then(response => {\n router.push({ name: 'Event', params: { url: response.url } });\n })\n .catch(error => {\n console.log(error);\n });\n } else {\n events.create(event.value)\n .then(response => {\n router.push({ name: 'Event', params: { url: response.url } });\n })\n .catch(error => {\n console.log(error);\n });\n }\n}\n\nfunction onDelete() {\n if (confirm('Are you sure you want to delete this event?')) {\n events.remove(event.value._id)\n .then(response => {\n router.push({ name: 'User Events', params: { user: event.value.creator.target._id } });\n })\n .catch(error => {\n console.error(error);\n })\n }\n}\n</script>\n\n<style lang=\"scss\">\n .dp__input {\n border: 0;\n padding: var(--medium);\n padding-left: 3rem;\n background: rgb(var(--white)) !important;\n border-radius: var(--small);\n }\n</style>"],"names":["events.read","auth.state","events.clean","events.state","events.update","events.create","events.remove"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA+MA,UAAM,QAAQ,SAAQ;AACtB,UAAM,SAAS,UAAS;AAExB,UAAM,EAAE,UAAS,IAAK,gBAAe;AAErC,UAAM,eAAe,SAAS,MAAM,MAAM,MAAM,YAAY,YAAY;AAExE,QAAI,QAAQ,IAAI,IAAI;AACN,QAAI,IAAI;AAEtB,UAAM,eAAe,IAAI,EAAE;AAC3B,UAAM,uBAAuB,IAAI,IAAI;AAErC,cAAU,YAAW;AAEnB,UAAI,MAAM,OAAO,KAAK;AACpB,cAAM,OAAO,MAAMA,KAAY,EAAE,MAAMC,MAAW,KAAK,KAAK,KAAK,MAAM,OAAO,IAAG,CAAE;AAEnF,cAAM,QAAQ,KAAK,IAAG;AAEtB,YAAI,CAAC,MAAM,OAAO;AACjB,iBAAO,KAAK,EAAC,MAAM,WAAU,CAAC;AAAA,QAC/B;AAEA,YAAI,MAAM,MAAM,MAAM,SAAS,gBAAgB;AAE7C,gBAAM,WAAW,UAAU,MAAM,MAAM,MAAM,OAAO,KAAK,UAAU,QAAQA,MAAW,UAAUA,MAAW,OAAO,KAAK;AAEvH,cAAI,CAAC,UAAU;AACb,mBAAO,KAAK,EAAC,MAAM,eAAc,CAAC;AAAA,UACpC;AAAA,QACF;AAEC,YAAI,MAAM,MAAM,MAAM,SAAS,UAAU,MAAM,MAAM,QAAQ,OAAO,QAAQA,MAAW,KAAK,KAAK;AAChG,kBAAQ,IAAI,MAAM,MAAM,QAAQ,MAAM;AACtC,kBAAQ,IAAIA,MAAW,KAAK,GAAG;AAC/B,iBAAO,KAAK,EAAC,MAAM,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,WAAS;AACd,kBAAQ,IAAI,KAAK;AAAA,QACnB,CAAC;AAAA,MACL;AAAA,IACF;AAEA,aAAS,WAAW;AAClB,UAAI,QAAQ,6CAA6C,GAAG;AAC1DC,eAAc,MAAM,MAAM,GAAG,EAC1B,KAAK,cAAY;AAChB,iBAAO,KAAK,EAAE,MAAM,eAAe,QAAQ,EAAE,MAAM,MAAM,MAAM,QAAQ,OAAO,IAAG,EAAE,CAAE;AAAA,QACvF,CAAC,EACA,MAAM,WAAS;AACd,kBAAQ,MAAM,KAAK;AAAA,QACrB,CAAC;AAAA,MACL;AAAA,IACF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"EditEvent.vue.js","sources":["../../../../../../../src/modules/events/components/pages/EditEvent.vue"],"sourcesContent":["<template>\n <article v-if=\"event\" class=\"h-min-100 pd-thin\">\n <div class=\"pd-medium radius-medium mn-b-thin bg-light\">\n <h4 class=\"mn-b-small\">Basic Info</h4>\n \t<div class=\"mn-b-thin radius-small w-100 h-10r bg-white flex-center flex-column flex\">\n \t<UploadImage \n v-model:photo=\"event.cover\"\n :uploadPath=\"'specials'\"\n class=\"h-4r w-4r aspect-1x1 o-hidden mn-b-thin radius-extra\" \n />\n <h4>Upload Event Cover</h4>\n </div>\n\n \t<Field \n v-model:field=\"event.name\" \n label=\"Name\"\n placeholder=\"Event name\" \n class=\"mn-b-thin w-100 bg-white pd-medium radius-small\" \n />\n <Field \n v-model:field=\"event.description\" \n type=\"textarea\" \n placeholder=\"Enter short description\" \n class=\"mn-b-thin w-100 bg-white pd-medium radius-small\" \n />\n <Field\n v-model:field=\"event.location\"\n label=\"Location\"\n placeholder=\"Event location\"\n class=\"mn-b-thin w-100 bg-white pd-medium radius-small\"\n />\n </div>\n\n <Block\n title=\"Schedule\"\n placeholder=\"No schedule periods added yet\"\n :actions=\"[{\n label: '+',\n function: addSchedulePeriod\n }]\"\n class=\"cols-1 mn-b-thin t-black gap-thin\"\n >\n <div\n class=\"mn-b-thin gap-small flex-nowrap flex\"\n v-for=\"(period, index) in event.schedule\"\n :key=\"index\"\n >\n <FieldDate\n v-model=\"period.start\"\n :allowRange=\"false\"\n :enableTime=\"true\"\n :disablePastDates=\"!isBackoffice\"\n :disabledRanges=\"getDisabledRangesForPeriod(index)\"\n :showSelected=\"true\"\n :locale=\"$i18n.locale\"\n label=\"Start\"\n placeholder=\"Start time\"\n class=\"w-100 bg-white radius-small pd-medium\"\n />\n <FieldDate\n v-model=\"period.end\"\n :allowRange=\"false\"\n :enableTime=\"true\"\n :disablePastDates=\"!isBackoffice\"\n :disabledRanges=\"getDisabledRangesForPeriod(index)\"\n :showSelected=\"true\"\n :locale=\"$i18n.locale\"\n label=\"End\"\n placeholder=\"End time\"\n class=\"w-100 bg-white radius-small pd-medium\"\n />\n <div v-if=\"index > 0\" @click=\"() => event.schedule.splice(index, 1)\" class=\"radius-small h-100 i-big flex-center flex aspect-1x1 bg-red\">\n <IconDelete class=\"i-medium\" />\n </div>\n </div>\n </Block>\n\n <EditTickets v-model:tickets=\"event.ticketsTypes\" />\n\n\t\t<section v-if=\"event\" class=\"pd-b-extra z-index-1 pos-relative w-100 bg-light pd-big radius-medium\">\n <Constructor \n :content=\"event.content\"\n :autoFocus=\"false\" \n @update=\"update => event.content = update\"\n />\n </section>\n\n <section v-if=\"event\" class=\"pd-small z-index-2 pos-sticky pos-l-0 pos-b-0 w-100 \">\n <div class=\"pd-thin radius-regular bg-main w-100 flex-nowrap flex\">\n <a v-if=\"route.params.url\" @click=\"onDelete()\" class=\"mn-r-auto bg-red t-white t-black button\"><span>Delete</span></a>\n <a @click=\"onDrafts()\" class=\"mn-l-auto bg-white t-black button\"><span>To Drafts</span></a>\n <a @click=\"openPublicationPopup()\" class=\"mn-l-thin bg-black t-white button\"><span>Publish</span></a>\n </div>\n </section>\n\n <Popup \n title=\"Final Touches\" \n @close-popup=\"closePublicationPopup\" \n :isPopupOpen=\"isPublicationPopup\"\n class=\"w-m-33r t-left pd-big bg-white radius-big\"\n > \n <BlockTags\n @tags-changed=\"newTags => event.tags = newTags\"\n :tags=\"event.tags\"\n class=\"mn-b-small\"\n />\n\n <h5 class=\"mn-b-small\">Add to public</h5>\n <Card\n v-if=\"selectedOrganization\"\n :photo=\"selectedOrganization.profile?.photo\"\n :title=\"selectedOrganization.profile?.name\"\n @click=\"() => { \n selectedOrganization = null\n }\"\n class=\"h-4r w-100 bg-light pd-thin radius-medium mn-b-thin\"\n />\n\n <section v-else class=\"mn-b-thin h-25r o-x-hidden o-y-scroll bg-light radius-big pd-small \">\n <Feed\n :showLoadMore=\"false\" \n :search=\"{\n placeholder: 'Search organization...',\n class: 'bg-white mn-b-thin'\n }\"\n :states=\"{\n empty: {\n title: 'No organizations Found',\n description: 'Currently, there are no such organizations available.'\n }\n }\"\n :store=\"{\n read: (options) => organizations.actions.read(options),\n state: null\n }\"\n :options=\"{\n user: auth.state.user._id,\n postable: auth.state.user._id,\n lookup: ['memberships']\n }\"\n v-slot=\"{ \n items \n }\"\n >\n <Card\n v-for=\"(organization, index) in items\" \n v-memo=\"[organization._id, organization.profile.name]\"\n :photo=\"organization.profile?.photo\"\n :title=\"organization.profile?.name\"\n @click=\"() => { \n selectedOrganization = organization\n }\"\n class=\"h-4r bg-white pd-thin radius-medium w-100 mn-b-thin\"\n />\n </Feed>\n </section>\n\n \n <h5 v-if=\"selectedOrganization\" class=\"mn-b-thin\">Options:</h5>\n <div v-if=\"selectedOrganization\" class=\"mn-b-medium br-grey-transp-25 br-2px pd-small radius-big\">\n <Checkbox \n :label=\"'Hide Author'\"\n :radio=\"event.creator.hidden\"\n @update:radio=\"updateEvent => event.creator.hidden = updateEvent\"\n name=\"prices\"\n class=\"w-100\"\n />\n </div>\n <Button :submit=\"onSubmit\" :callback=\"redirectTo\" class=\"w-100 bg-black t-white\">Publish</Button>\n </Popup>\n </article>\n\n</template>\n\n<script setup>\nimport Textarea from '@martyrs/src/modules/constructor/components/elements/Textarea.vue';\nimport Constructor from '@martyrs/src/modules/constructor/components/sections/Constructor.vue';\n\nimport FieldDate from '@martyrs/src/components/FieldDate/FieldDate.vue'\n\nimport Block from '@martyrs/src/components/Block/Block.vue';\nimport Popup from '@martyrs/src/components/Popup/Popup.vue';\nimport Field from '@martyrs/src/components/Field/Field.vue'\nimport BlockTags from '@martyrs/src/components/FieldTags/BlockTags.vue';\nimport Checkbox from '@martyrs/src/components/Checkbox/Checkbox.vue';\nimport SelectMulti from '@martyrs/src/components/SelectMulti/SelectMulti.vue';\nimport Upload from '@martyrs/src/components/Upload/Upload.vue';\nimport UploadImage from '@martyrs/src/components/UploadImage/UploadImage.vue';\nimport EditImages from '@martyrs/src/components/EditImages/EditImages.vue';\nimport Feed from '@martyrs/src/components/Feed/Feed.vue'\nimport Button from '@martyrs/src/components/Button/Button.vue'; \n\nimport Card from '@martyrs/src/modules/core/views/components/blocks/Card.vue';\n\nimport EditTickets from '@martyrs/src/modules/events/components/sections/EditTickets.vue';\n\nimport IconDelete from '@martyrs/src/modules/icons/navigation/IconDelete.vue';\n\nimport { ref, computed, onMounted } from 'vue';\nimport { useRoute, useRouter } from 'vue-router';\n\nimport { useGlobalMixins } from \"@martyrs/src/modules/core/views/mixins/mixins.js\"\n\nimport * as events from '@martyrs/src/modules/events/store/events.js';\nimport * as auth from '@martyrs/src/modules/auth/views/store/auth.js';\nimport * as organizations from '@martyrs/src/modules/organizations/store/organizations.js';\n\nconst route = useRoute();\nconst router = useRouter();\n\nconst { hasAccess } = useGlobalMixins()\n\nconst isBackoffice = computed(() => route.meta?.context === 'backoffice')\n\nlet event = ref(null);\nlet publics = ref(null);\n\nconst selectedTags = ref([]);\nconst selectedOrganization = ref(null);\n\nonMounted(async () =>{\n\n if (route.params.url) {\n const data = await events.read({ user: auth.state.user._id, url: route.params.url });\n\n event.value = data.pop();\n\n if (!event.value) {\n router.push({name: 'notfound'})\n }\n\n if (event.value.owner.type === 'organization') {\n // Если пост принадлежит организации, проверяем права на редактирование через `hasAccess`\n const isAccess = hasAccess(event.value.owner.target._id, 'events', 'edit', auth.state.accesses, auth.state.access.roles);\n\n if (!isAccess) {\n router.push({name: 'unauthorized'})\n }\n }\n\n if (event.value.owner.type === 'user' && event.value.creator.target._id !== auth.state.user._id) {\n console.log(event.value.creator.target)\n console.log(auth.state.user._id)\n router.push({name: 'unauthorized'})\n }\n\n } else {\n events.clean();\n event.value = events.state.current;\n }\n\n if (!event.value.owner) event.value.owner = {\n target: auth.state.user._id,\n type: 'user'\n }\n\n if (!event.value.creator) event.value.creator = {\n target: auth.state.user._id,\n type: 'user',\n hidden: false\n }\n\n if (!event.value.schedule || event.value.schedule.length === 0) {\n event.value.schedule = [{\n start: new Date(),\n end: new Date()\n }]\n }\n\n if (event.value.owner.type === 'organization') selectedOrganization.value = {\n _id: event.value.owner.target._id,\n profile: {\n name: event.value.owner.target.profile.name,\n photo: event.value.owner.target.profile.photo\n }\n }\n})\n\nconst isPublicationPopup = ref(false)\n\nfunction openPublicationPopup() {\n isPublicationPopup.value = true;\n}\nfunction closePublicationPopup() {\n isPublicationPopup.value = false;\n}\n\nfunction addSchedulePeriod() {\n event.value.schedule.push({\n start: new Date(),\n end: new Date()\n })\n}\n\nfunction getDisabledRangesForPeriod(currentIndex) {\n if (!event.value.schedule) return []\n\n return event.value.schedule\n .map((period, index) => {\n if (index === currentIndex) return null\n if (!period.start || !period.end) return null\n return {\n start: new Date(period.start),\n end: new Date(period.end)\n }\n })\n .filter(range => range !== null)\n}\n\nfunction onDrafts() {\n if (selectedTags.value.length > 0) selectedTags.value.map(tag => (tag.text))\n\n // Auto-select organization in organization context\n if (route.params._id && !selectedOrganization.value) {\n event.value.owner = {\n target: route.params._id,\n type: 'organization'\n }\n }\n\n event.value.status = \"draft\"\n\n // Calculate event.date from schedule\n if (event.value.schedule && event.value.schedule.length > 0) {\n const allDates = event.value.schedule\n .flatMap(period => [period.start, period.end])\n .filter(date => date !== null && date !== undefined)\n .map(date => new Date(date))\n\n event.value.date = {\n start: new Date(Math.min(...allDates)),\n end: new Date(Math.max(...allDates))\n }\n }\n\n if (route.params.url) {\n events.update(event.value)\n .then(response => {\n router.push({ name: 'Event', params: { url: response.url } });\n })\n .catch(error => {\n console.error(error);\n })\n } else {\n events.create(event.value)\n .then(response => {\n router.push({ name: 'Event', params: { url: response.url } });\n })\n .catch(error => {\n console.error(error);\n })\n }\n}\n\nfunction onSubmit() {\n if (selectedOrganization.value) event.value.owner = {\n target: selectedOrganization.value._id,\n type: 'organization'\n }\n\n if (!selectedOrganization.value) event.value.creator.hidden = false\n if (!selectedOrganization.value) event.value.organization = event.value.creator\n\n event.value.status = \"published\"\n\n // Calculate event.date from schedule\n if (event.value.schedule && event.value.schedule.length > 0) {\n const allDates = event.value.schedule\n .flatMap(period => [period.start, period.end])\n .filter(date => date !== null && date !== undefined)\n .map(date => new Date(date))\n\n event.value.date = {\n start: new Date(Math.min(...allDates)),\n end: new Date(Math.max(...allDates))\n }\n }\n if (route.params.url) {\n console.log(event.value)\n events.update(event.value)\n .then(response => {\n router.push({ name: 'Event', params: { url: response.url } });\n })\n .catch(error => {\n console.log(error);\n });\n } else {\n events.create(event.value)\n .then(response => {\n router.push({ name: 'Event', params: { url: response.url } });\n })\n .catch(error => {\n console.log(error);\n });\n }\n}\n\nfunction onDelete() {\n if (confirm('Are you sure you want to delete this event?')) {\n events.remove(event.value._id)\n .then(response => {\n router.push({ name: 'User Events', params: { user: event.value.creator.target._id } });\n })\n .catch(error => {\n console.error(error);\n })\n }\n}\n</script>\n\n<style lang=\"scss\">\n .dp__input {\n border: 0;\n padding: var(--medium);\n padding-left: 3rem;\n background: rgb(var(--white)) !important;\n border-radius: var(--small);\n }\n</style>"],"names":["events.read","auth.state","events.clean","events.state","events.update","events.create","events.remove"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA+MA,UAAM,QAAQ,SAAQ;AACtB,UAAM,SAAS,UAAS;AAExB,UAAM,EAAE,UAAS,IAAK,gBAAe;AAErC,UAAM,eAAe,SAAS,MAAM,MAAM,MAAM,YAAY,YAAY;AAExE,QAAI,QAAQ,IAAI,IAAI;AACN,QAAI,IAAI;AAEtB,UAAM,eAAe,IAAI,EAAE;AAC3B,UAAM,uBAAuB,IAAI,IAAI;AAErC,cAAU,YAAW;AAEnB,UAAI,MAAM,OAAO,KAAK;AACpB,cAAM,OAAO,MAAMA,KAAY,EAAE,MAAMC,MAAW,KAAK,KAAK,KAAK,MAAM,OAAO,IAAG,CAAE;AAEnF,cAAM,QAAQ,KAAK,IAAG;AAEtB,YAAI,CAAC,MAAM,OAAO;AACjB,iBAAO,KAAK,EAAC,MAAM,WAAU,CAAC;AAAA,QAC/B;AAEA,YAAI,MAAM,MAAM,MAAM,SAAS,gBAAgB;AAE7C,gBAAM,WAAW,UAAU,MAAM,MAAM,MAAM,OAAO,KAAK,UAAU,QAAQA,MAAW,UAAUA,MAAW,OAAO,KAAK;AAEvH,cAAI,CAAC,UAAU;AACb,mBAAO,KAAK,EAAC,MAAM,eAAc,CAAC;AAAA,UACpC;AAAA,QACF;AAEC,YAAI,MAAM,MAAM,MAAM,SAAS,UAAU,MAAM,MAAM,QAAQ,OAAO,QAAQA,MAAW,KAAK,KAAK;AAChG,kBAAQ,IAAI,MAAM,MAAM,QAAQ,MAAM;AACtC,kBAAQ,IAAIA,MAAW,KAAK,GAAG;AAC/B,iBAAO,KAAK,EAAC,MAAM,eAAc,CAAC;AAAA,QACpC;AAAA,MAEF,OAAO;AACLC,cAAY;AACZ,cAAM,QAAQC,QAAa;AAAA,MAC7B;AAEA,UAAI,CAAC,MAAM,MAAM,MAA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