@ozdao/martyrs 0.2.584 → 0.2.586
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.
- package/dist/auth.server.js +161 -96
- package/dist/{authJwt-J1csaMWA.js → authJwt-DKbMMjw0.js} +33 -0
- package/dist/builder.js +2 -0
- package/dist/chats.server.js +2 -2
- package/dist/community.server.js +1 -1
- package/dist/core.server.js +191 -2
- package/dist/{core.websocket-C2FxNmZ1.js → core.websocket-Cl76z2wT.js} +41 -5
- package/dist/{crud-q1ye5IhV.js → crud-DpOXTZep.js} +1 -1
- package/dist/events.server.js +2 -2
- package/dist/files.server.js +1 -1
- package/dist/gallery.server.js +1 -1
- package/dist/index-kvBwwb0w.js +427 -0
- package/dist/inventory.server.js +2 -2
- package/dist/{mailing-DuEFRsa3.js → mailing-DT7nbNjZ.js} +16 -3
- package/dist/{main-fmp55tJF.js → main-BIf-WirR.js} +864 -865
- package/dist/marketplace.server.js +1 -1
- package/dist/martyrs/dist/{main-fmp55tJF.js → main-BIf-WirR.js} +193 -38
- package/dist/martyrs/dist/main-BIf-WirR.js.map +1 -0
- package/dist/martyrs/dist/{web-BDuQSQKS.js → web-O7lXcjg0.js} +2 -2
- package/dist/martyrs/dist/{web-BDuQSQKS.js.map → web-O7lXcjg0.js.map} +1 -1
- package/dist/martyrs/src/components/Button/{Button.vue2.js → Button.vue.js} +8 -7
- package/dist/martyrs/src/components/Button/Button.vue.js.map +1 -0
- package/dist/martyrs/src/components/EditImages/{EditImages.vue2.js → EditImages.vue.js} +2 -2
- package/dist/martyrs/src/components/EditImages/EditImages.vue.js.map +1 -0
- package/dist/martyrs/src/components/Feed/Feed.vue.js +1 -1
- package/dist/martyrs/src/components/FieldBig/FieldBig.vue.js +1 -1
- package/dist/martyrs/src/components/Loader/Loader.vue.js +1 -1
- package/dist/martyrs/src/components/Loader/Loader.vue.js.map +1 -1
- package/dist/martyrs/src/components/Spoiler/{Spoiler.vue2.js → Spoiler.vue.js} +2 -2
- package/dist/martyrs/src/components/Spoiler/Spoiler.vue.js.map +1 -0
- package/dist/martyrs/src/components/Tab/{Tab.vue.js → Tab.vue2.js} +2 -2
- package/dist/martyrs/src/components/Tab/Tab.vue2.js.map +1 -0
- package/dist/martyrs/src/components/Tooltip/Tooltip.vue2.js +17 -22
- package/dist/martyrs/src/components/Tooltip/Tooltip.vue2.js.map +1 -1
- package/dist/martyrs/src/modules/auth/auth.client.js +18 -24
- package/dist/martyrs/src/modules/auth/auth.client.js.map +1 -1
- package/dist/martyrs/src/modules/auth/views/components/blocks/OtpDialog.vue.js +178 -0
- package/dist/martyrs/src/modules/auth/views/components/blocks/OtpDialog.vue.js.map +1 -0
- package/dist/martyrs/src/modules/auth/views/components/pages/Invite.vue.js +2 -2
- package/dist/martyrs/src/modules/auth/views/components/pages/Profile.vue.js +104 -77
- package/dist/martyrs/src/modules/auth/views/components/pages/Profile.vue.js.map +1 -1
- package/dist/martyrs/src/modules/auth/views/components/pages/ProfileBlogposts.vue.js +1 -1
- package/dist/martyrs/src/modules/auth/views/components/pages/ProfileEditAccount.vue.js +198 -14
- package/dist/martyrs/src/modules/auth/views/components/pages/ProfileEditAccount.vue.js.map +1 -1
- package/dist/martyrs/src/modules/auth/views/components/pages/ProfileEditProfile.vue.js +1 -1
- package/dist/martyrs/src/modules/auth/views/components/pages/ResetPassword.vue.js +71 -30
- package/dist/martyrs/src/modules/auth/views/components/pages/ResetPassword.vue.js.map +1 -1
- package/dist/martyrs/src/modules/auth/views/components/pages/SignIn.vue.js +3 -3
- package/dist/martyrs/src/modules/auth/views/components/pages/SignIn.vue.js.map +1 -1
- package/dist/martyrs/src/modules/auth/views/components/pages/SignUp.vue.js +87 -31
- package/dist/martyrs/src/modules/auth/views/components/pages/SignUp.vue.js.map +1 -1
- package/dist/martyrs/src/modules/auth/views/plugins/otp.plugin.js +100 -0
- package/dist/martyrs/src/modules/auth/views/plugins/otp.plugin.js.map +1 -0
- package/dist/martyrs/src/modules/auth/views/router/auth.router.js +2 -31
- package/dist/martyrs/src/modules/auth/views/router/auth.router.js.map +1 -1
- package/dist/martyrs/src/modules/auth/views/router/users.router.js +0 -14
- package/dist/martyrs/src/modules/auth/views/router/users.router.js.map +1 -1
- package/dist/martyrs/src/modules/auth/views/store/auth.js +1 -56
- package/dist/martyrs/src/modules/auth/views/store/auth.js.map +1 -1
- package/dist/martyrs/src/modules/auth/views/store/users.js +5 -1
- package/dist/martyrs/src/modules/auth/views/store/users.js.map +1 -1
- package/dist/martyrs/src/modules/backoffice/backoffice.client.js +3 -15
- package/dist/martyrs/src/modules/backoffice/backoffice.client.js.map +1 -1
- package/dist/martyrs/src/modules/backoffice/configs/navigation.backoffice.config.js +99 -0
- package/dist/martyrs/src/modules/backoffice/configs/navigation.backoffice.config.js.map +1 -0
- package/dist/martyrs/src/modules/backoffice/{backoffice.router.js → router/backoffice.router.js} +9 -7
- package/dist/martyrs/src/modules/backoffice/router/backoffice.router.js.map +1 -0
- package/dist/martyrs/src/modules/community/components/pages/BlogPost.vue.js +7 -1
- package/dist/martyrs/src/modules/community/components/pages/BlogPost.vue.js.map +1 -1
- package/dist/martyrs/src/modules/community/components/pages/CreateBlogPost.vue.js +1 -1
- package/dist/martyrs/src/modules/core/core.client.js.map +1 -1
- package/dist/martyrs/src/modules/core/views/classes/core.app.js +5 -1
- package/dist/martyrs/src/modules/core/views/classes/core.app.js.map +1 -1
- package/dist/martyrs/src/modules/core/views/components/blocks/CardHeader.vue.js +0 -1
- package/dist/martyrs/src/modules/core/views/components/blocks/CardHeader.vue.js.map +1 -1
- package/dist/martyrs/src/modules/core/views/components/blocks/PopupAuth.vue.js +1 -1
- package/dist/martyrs/src/modules/core/views/components/blocks/PopupDateSelector.vue.js +1 -1
- package/dist/martyrs/src/modules/core/views/components/elements/OnlineIndicator.vue.js +74 -0
- package/dist/martyrs/src/modules/core/views/components/elements/OnlineIndicator.vue.js.map +1 -0
- package/dist/martyrs/src/modules/core/views/components/layouts/App.vue.js.map +1 -1
- package/dist/martyrs/src/modules/core/views/components/layouts/Client.vue.js +77 -67
- package/dist/martyrs/src/modules/core/views/components/layouts/Client.vue.js.map +1 -1
- package/dist/martyrs/src/modules/core/views/components/pages/404.vue.js +76 -7
- package/dist/martyrs/src/modules/core/views/components/pages/404.vue.js.map +1 -1
- package/dist/martyrs/src/modules/core/views/components/partials/Header.vue.js +1 -1
- package/dist/martyrs/src/modules/core/views/components/partials/Navigation.vue.js +1 -1
- package/dist/martyrs/src/modules/core/views/components/partials/NavigationBar.vue.js +1 -1
- package/dist/martyrs/src/modules/core/views/components/sections/{Filters.vue2.js → Filters.vue.js} +2 -2
- package/dist/martyrs/src/modules/core/views/components/sections/Filters.vue.js.map +1 -0
- package/dist/martyrs/src/modules/core/views/components/sections/SectionPageTitle.vue.js +1 -1
- package/dist/martyrs/src/modules/core/views/store/core.store.js +1 -0
- package/dist/martyrs/src/modules/core/views/store/core.store.js.map +1 -1
- package/dist/martyrs/src/modules/core/views/utils/vue-app-renderer.js +2 -1
- package/dist/martyrs/src/modules/core/views/utils/vue-app-renderer.js.map +1 -1
- package/dist/martyrs/src/modules/events/components/elements/ButtonCheck.vue.js +1 -1
- package/dist/martyrs/src/modules/events/components/elements/ButtonJoin.vue.js +1 -1
- package/dist/martyrs/src/modules/events/components/pages/EditEvent.vue.js +2 -2
- package/dist/martyrs/src/modules/events/components/pages/EditEventTickets.vue.js +1 -1
- package/dist/martyrs/src/modules/events/components/pages/Event.vue.js +2 -1
- package/dist/martyrs/src/modules/events/components/pages/Event.vue.js.map +1 -1
- package/dist/martyrs/src/modules/events/components/pages/EventsBackoffice.vue.js +1 -1
- package/dist/martyrs/src/modules/events/components/sections/EditTickets.vue.js +1 -1
- package/dist/martyrs/src/modules/gallery/components/sections/BackofficeGallery.vue.js +2 -2
- package/dist/martyrs/src/modules/inventory/components/forms/AdjustmentForm.vue.js +1 -1
- package/dist/martyrs/src/modules/inventory/components/forms/ColumnSettingsMenu.vue.js +1 -1
- package/dist/martyrs/src/modules/inventory/components/forms/HistoryView.vue.js +1 -1
- package/dist/martyrs/src/modules/inventory/components/forms/StockAlertsForm.vue.js +1 -1
- package/dist/martyrs/src/modules/inventory/components/pages/InventoryEdit.vue.js +1 -1
- package/dist/martyrs/src/modules/landing/components/sections/SectionGuide.vue.js +1 -1
- package/dist/martyrs/src/modules/marketplace/views/components/pages/Marketplace.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/blocks/ActionButtons.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/cards/AlbumCard.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/cards/ArtistCardSmall.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/cards/PlaylistCard.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/cards/TrackListCard.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/forms/AlbumForm.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/forms/ArtistForm.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/forms/PlaylistForm.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/forms/SearchForm.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/forms/TrackForm.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/pages/Album.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/pages/Artist.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/pages/MusicLibrary.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/pages/Playlist.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/pages/SearchResults.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/pages/Track.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/pages/TrackCreate.vue.js +0 -1
- package/dist/martyrs/src/modules/music/components/pages/TrackCreate.vue.js.map +1 -1
- package/dist/martyrs/src/modules/music/components/player/FullscreenPlayer.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/player/MusicPlayer.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/player/PlayerControls.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/player/VolumeControl.vue.js +1 -1
- package/dist/martyrs/src/modules/notifications/components/sections/NotificationPreferences.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/forms/FormApplicationDetails.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/forms/FormCustomerDetails.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/forms/FormSelectCustomer.vue.js +1 -2
- package/dist/martyrs/src/modules/orders/components/forms/FormSelectCustomer.vue.js.map +1 -1
- package/dist/martyrs/src/modules/orders/components/pages/OrderBackoffice.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/pages/OrderCreate.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js +2 -2
- package/dist/martyrs/src/modules/orders/components/pages/Orders.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/sections/ApplicationDetails.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/sections/CustomerDetails.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/sections/FormDelivery.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/blocks/CardDepartment.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/elements/ButtonToggleMembership.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/forms/AddExistingMembersForm.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/forms/DepartmentForm.vue.js +2 -2
- package/dist/martyrs/src/modules/organizations/components/forms/InviteForm.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/pages/Department.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/pages/OrganizationEdit.vue.js +4 -3
- package/dist/martyrs/src/modules/organizations/components/pages/OrganizationEdit.vue.js.map +1 -1
- package/dist/martyrs/src/modules/organizations/components/pages/Organizations.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.js +1 -2
- package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.js.map +1 -1
- package/dist/martyrs/src/modules/organizations/components/sections/MembersAdd.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/sections/Organizations.vue.js +1 -2
- package/dist/martyrs/src/modules/organizations/components/sections/Organizations.vue.js.map +1 -1
- package/dist/martyrs/src/modules/pages/pages.router.js +7 -5
- package/dist/martyrs/src/modules/pages/pages.router.js.map +1 -1
- package/dist/martyrs/src/modules/pages/views/components/blocks/CardPage.vue.js +0 -1
- package/dist/martyrs/src/modules/pages/views/components/blocks/CardPage.vue.js.map +1 -1
- package/dist/martyrs/src/modules/pages/views/components/pages/PageEdit.vue.js +1 -1
- package/dist/martyrs/src/modules/pages/views/components/partials/SidebarPages.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/pages/Categories.vue.js +0 -1
- package/dist/martyrs/src/modules/products/components/pages/Categories.vue.js.map +1 -1
- package/dist/martyrs/src/modules/products/components/pages/CategoryEdit.vue.js +2 -2
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.js +1 -2
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.js.map +1 -1
- package/dist/martyrs/src/modules/products/components/pages/ProductEdit.vue.js +3 -3
- package/dist/martyrs/src/modules/products/components/pages/Products.vue.js +4 -4
- package/dist/martyrs/src/modules/products/components/pages/Products.vue.js.map +1 -1
- package/dist/martyrs/src/modules/products/components/sections/EditAttributes.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/sections/EditDiscounts.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/sections/EditVariants.vue.js +2 -2
- package/dist/martyrs/src/modules/products/components/sections/FilterProducts.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/sections/ProductConfigurator.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/sections/ProductsRecommended.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/sections/SectionProduct.vue.js +2 -2
- package/dist/martyrs/src/modules/rents/views/components/pages/Gant/GanttToolbar.vue.js +2 -2
- package/dist/martyrs/src/modules/rents/views/components/pages/Rents.vue.js +1 -1
- package/dist/martyrs/src/modules/rents/views/components/pages/RentsEdit.vue.js +1 -1
- package/dist/martyrs/src/modules/reports/components/sections/FormReport.vue.js +1 -1
- package/dist/martyrs/src/modules/spots/components/layouts/Spots.vue.js +1 -1
- package/dist/martyrs/src/modules/spots/components/pages/Map.vue.js +1 -1
- package/dist/martyrs/src/modules/spots/components/pages/Spot.vue.js +1 -1
- package/dist/martyrs/src/modules/spots/components/pages/SpotEdit.vue.js +2 -2
- package/dist/martyrs/src/modules/spots/components/sections/WorktimeEdit.vue.js +1 -1
- package/dist/martyrs.css +1 -1
- package/dist/martyrs.es.js +1 -1
- package/dist/music.server.js +1 -1
- package/dist/notifications.server.js +1 -1
- package/dist/orders.server.js +7 -6
- package/dist/organizations.server.js +2 -2
- package/dist/products.server.js +2 -2
- package/dist/profile.schema-C31Lynn3.js +21 -0
- package/dist/rents.server.js +1 -1
- package/dist/sessions.service-COcwjd0f.js +86 -0
- package/dist/style.css +183 -108
- package/dist/{tickets.controller-B7r0mK-5.js → tickets.controller-DdF85W-i.js} +1 -1
- package/dist/visitors.service-B1dhhuSo.js +83 -0
- package/dist/wallet.server.js +2 -2
- package/dist/{web-BDuQSQKS.js → web-O7lXcjg0.js} +1 -1
- package/package.json +5 -1
- package/src/builder/modes/ssr.rspack.dev.js +2 -0
- package/src/cli/commands/create.js +106 -0
- package/src/cli/index.js +25 -0
- package/src/cli/templates/app/.env.development.mustache +14 -0
- package/src/cli/templates/app/.env.production.mustache +14 -0
- package/src/cli/templates/app/Dockerfile +36 -0
- package/src/cli/templates/app/babel.config.js +14 -0
- package/src/cli/templates/app/env.js +3 -0
- package/src/cli/templates/app/index.js +46 -0
- package/src/cli/templates/app/mongodb.config.js +18 -0
- package/src/cli/templates/app/package.json.mustache +65 -0
- package/src/cli/templates/app/src/client.js +22 -0
- package/src/cli/templates/app/src/components/pages/Index.vue +11 -0
- package/src/cli/templates/app/src/configs/global.config.js.mustache +40 -0
- package/src/cli/templates/app/src/localization/extensions.js +2 -0
- package/src/cli/templates/app/src/localization/index.js +44 -0
- package/src/cli/templates/app/src/localization/overrides.js +2 -0
- package/src/cli/templates/app/src/localization/translations.js +10 -0
- package/src/cli/templates/app/src/models/index.js +9 -0
- package/src/cli/templates/app/src/router/index.js +48 -0
- package/src/cli/templates/app/src/scss/theme.scss +18 -0
- package/src/cli/templates/app/src/server.js +68 -0
- package/src/cli/templates/app/src/store/index.js +9 -0
- package/src/cli/templates/docker-compose.yaml.mustache +47 -0
- package/src/cli/templates/nginx/Dockerfile +5 -0
- package/src/cli/templates/nginx/default.conf.mustache +55 -0
- package/src/cli/templates/public/favicon/.gitkeep +0 -0
- package/src/cli/templates/start-dev.sh.mustache +131 -0
- package/src/cli/templates/start-prod.sh.mustache +12 -0
- package/src/components/Button/Button.vue +61 -15
- package/src/components/Loader/Loader.vue +1 -1
- package/src/components/Tooltip/Tooltip.vue +31 -23
- package/src/modules/TASKS.MD +30 -1
- package/src/modules/auth/CLAUDE.md +381 -0
- package/src/modules/auth/FIXES.md +0 -38
- package/src/modules/auth/auth.client.js +4 -6
- package/src/modules/auth/auth.server.js +4 -15
- package/src/modules/auth/controllers/middlewares/authJwt.js +59 -17
- package/src/modules/auth/controllers/middlewares/index.js +4 -1
- package/src/modules/auth/controllers/middlewares/otp.middleware.js +166 -0
- package/src/modules/auth/controllers/middlewares/verifySignUp.js +0 -1
- package/src/modules/auth/controllers/middlewares/verifyUser.js +58 -11
- package/src/modules/auth/controllers/routes/auth.routes.js +48 -6
- package/src/modules/auth/controllers/routes/users.routes.js +29 -8
- package/src/modules/auth/controllers/services/auth.service.js +62 -12
- package/src/modules/auth/controllers/services/otp.service.js +109 -0
- package/src/modules/auth/controllers/services/users.service.js +46 -6
- package/src/modules/auth/models/otp.model.js +20 -0
- package/src/modules/auth/views/components/blocks/OtpDialog.vue +168 -0
- package/src/modules/auth/views/components/pages/Profile.vue +51 -18
- package/src/modules/auth/views/components/pages/ProfileEditAccount.vue +199 -45
- package/src/modules/auth/views/components/pages/ResetPassword.vue +170 -132
- package/src/modules/auth/views/components/pages/SignIn.vue +2 -1
- package/src/modules/auth/views/components/pages/SignUp.vue +203 -147
- package/src/modules/auth/views/plugins/otp.plugin.js +104 -0
- package/src/modules/auth/views/router/auth.router.js +1 -24
- package/src/modules/auth/views/router/users.router.js +1 -12
- package/src/modules/auth/views/store/auth.js +0 -68
- package/src/modules/auth/views/store/users.js +6 -2
- package/src/modules/backoffice/backoffice.client.js +1 -25
- package/src/modules/backoffice/configs/navigation.backoffice.config.js +99 -0
- package/src/modules/backoffice/router/backoffice.router.js +8 -7
- package/src/modules/community/components/pages/BlogPost.vue +9 -1
- package/src/modules/core/controllers/classes/core.websocket.js +57 -6
- package/src/modules/core/controllers/middlewares/visitor.logger.js +49 -0
- package/src/modules/core/controllers/services/requests.service.js +53 -0
- package/src/modules/core/controllers/services/sessions.service.js +98 -0
- package/src/modules/core/controllers/services/visitors.service.js +102 -0
- package/src/modules/core/controllers/utils/mailing.js +16 -3
- package/src/modules/core/core.client.js +1 -0
- package/src/modules/core/core.server.js +45 -3
- package/src/modules/core/models/request.model.js +30 -0
- package/src/modules/core/models/session.model.js +43 -0
- package/src/modules/core/models/visitor.model.js +28 -0
- package/src/modules/core/views/classes/core.app.js +8 -3
- package/src/modules/core/views/components/elements/OnlineIndicator.vue +115 -0
- package/src/modules/core/views/components/layouts/App.vue +2 -2
- package/src/modules/core/views/components/layouts/Client.vue +444 -479
- package/src/modules/core/views/components/pages/404.vue +55 -3
- package/src/modules/core/views/store/core.store.js +1 -0
- package/src/modules/core/views/utils/vue-app-renderer.js +9 -1
- package/src/modules/orders/controllers/orders.controller.js +3 -3
- package/src/modules/pages/pages.router.js +4 -2
- package/src/modules/pages/views/router/pages.backoffice.router.js +4 -3
- package/src/modules/products/components/pages/Products.vue +1 -1
- package/dist/_virtual/alignment-pattern.js +0 -5
- package/dist/_virtual/alignment-pattern.js.map +0 -1
- package/dist/_virtual/browser.js +0 -8
- package/dist/_virtual/browser.js.map +0 -1
- package/dist/_virtual/browser2.js +0 -5
- package/dist/_virtual/browser2.js.map +0 -1
- package/dist/_virtual/canvas.js +0 -5
- package/dist/_virtual/canvas.js.map +0 -1
- package/dist/_virtual/dijkstra.js +0 -5
- package/dist/_virtual/dijkstra.js.map +0 -1
- package/dist/_virtual/error-correction-code.js +0 -5
- package/dist/_virtual/error-correction-code.js.map +0 -1
- package/dist/_virtual/error-correction-level.js +0 -5
- package/dist/_virtual/error-correction-level.js.map +0 -1
- package/dist/_virtual/finder-pattern.js +0 -5
- package/dist/_virtual/finder-pattern.js.map +0 -1
- package/dist/_virtual/format-info.js +0 -5
- package/dist/_virtual/format-info.js.map +0 -1
- package/dist/_virtual/galois-field.js +0 -5
- package/dist/_virtual/galois-field.js.map +0 -1
- package/dist/_virtual/mask-pattern.js +0 -5
- package/dist/_virtual/mask-pattern.js.map +0 -1
- package/dist/_virtual/mode.js +0 -5
- package/dist/_virtual/mode.js.map +0 -1
- package/dist/_virtual/polynomial.js +0 -5
- package/dist/_virtual/polynomial.js.map +0 -1
- package/dist/_virtual/qrcode.js +0 -5
- package/dist/_virtual/qrcode.js.map +0 -1
- package/dist/_virtual/regex.js +0 -5
- package/dist/_virtual/regex.js.map +0 -1
- package/dist/_virtual/segments.js +0 -5
- package/dist/_virtual/segments.js.map +0 -1
- package/dist/_virtual/svg-tag.js +0 -5
- package/dist/_virtual/svg-tag.js.map +0 -1
- package/dist/_virtual/utils.js +0 -5
- package/dist/_virtual/utils.js.map +0 -1
- package/dist/_virtual/utils2.js +0 -5
- package/dist/_virtual/utils2.js.map +0 -1
- package/dist/_virtual/version-check.js +0 -5
- package/dist/_virtual/version-check.js.map +0 -1
- package/dist/_virtual/version.js +0 -5
- package/dist/_virtual/version.js.map +0 -1
- package/dist/index-_Edcmck_.js +0 -170
- package/dist/martyrs/dist/main-fmp55tJF.js.map +0 -1
- package/dist/martyrs/node_modules/.pnpm/bignumber.js@9.1.2/node_modules/bignumber.js/bignumber.js +0 -1336
- package/dist/martyrs/node_modules/.pnpm/bignumber.js@9.1.2/node_modules/bignumber.js/bignumber.js.map +0 -1
- package/dist/martyrs/src/components/Button/Button.vue2.js.map +0 -1
- package/dist/martyrs/src/components/EditImages/EditImages.vue2.js.map +0 -1
- package/dist/martyrs/src/components/Spoiler/Spoiler.vue2.js.map +0 -1
- package/dist/martyrs/src/components/Tab/Tab.vue.js.map +0 -1
- package/dist/martyrs/src/modules/auth/views/components/pages/EnterCode.vue.js +0 -166
- package/dist/martyrs/src/modules/auth/views/components/pages/EnterCode.vue.js.map +0 -1
- package/dist/martyrs/src/modules/auth/views/components/pages/EnterPassword.vue.js +0 -118
- package/dist/martyrs/src/modules/auth/views/components/pages/EnterPassword.vue.js.map +0 -1
- package/dist/martyrs/src/modules/auth/views/components/sections/ProfileEditCredentials.vue.js +0 -360
- package/dist/martyrs/src/modules/auth/views/components/sections/ProfileEditCredentials.vue.js.map +0 -1
- package/dist/martyrs/src/modules/auth/views/store/twofa.js +0 -40
- package/dist/martyrs/src/modules/auth/views/store/twofa.js.map +0 -1
- package/dist/martyrs/src/modules/backoffice/backoffice.router.js.map +0 -1
- package/dist/martyrs/src/modules/backoffice/components/partials/Sidebar.vue.js +0 -150
- package/dist/martyrs/src/modules/backoffice/components/partials/Sidebar.vue.js.map +0 -1
- package/dist/martyrs/src/modules/core/views/components/sections/Filters.vue2.js.map +0 -1
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CardBalanceReplenished.vue.js +0 -43
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CardBalanceReplenished.vue.js.map +0 -1
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CardDeposit.vue.js +0 -47
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CardDeposit.vue.js.map +0 -1
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CashDeposit.vue.js +0 -29
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CashDeposit.vue.js.map +0 -1
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CryptoDeposit.vue.js +0 -89
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CryptoDeposit.vue.js.map +0 -1
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CryptoDepositProcessing.vue.js +0 -136
- package/dist/martyrs/src/modules/wallet/views/components/blocks/CryptoDepositProcessing.vue.js.map +0 -1
- package/dist/martyrs/src/modules/wallet/views/components/pages/Wallet.vue.js +0 -238
- package/dist/martyrs/src/modules/wallet/views/components/pages/Wallet.vue.js.map +0 -1
- package/dist/martyrs/src/modules/wallet/views/localization/wallet.json.js +0 -9
- package/dist/martyrs/src/modules/wallet/views/localization/wallet.json.js.map +0 -1
- package/dist/martyrs/src/modules/wallet/views/store/wallet.store.js +0 -134
- package/dist/martyrs/src/modules/wallet/views/store/wallet.store.js.map +0 -1
- package/dist/node_modules/.pnpm/dijkstrajs@1.0.3/node_modules/dijkstrajs/dijkstra.js +0 -106
- package/dist/node_modules/.pnpm/dijkstrajs@1.0.3/node_modules/dijkstrajs/dijkstra.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/browser.js +0 -79
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/browser.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/can-promise.js +0 -14
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/can-promise.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/alignment-pattern.js +0 -43
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/alignment-pattern.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/alphanumeric-data.js +0 -85
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/alphanumeric-data.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/bit-buffer.js +0 -40
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/bit-buffer.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/bit-matrix.js +0 -34
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/bit-matrix.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/byte-data.js +0 -36
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/byte-data.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/error-correction-code.js +0 -367
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/error-correction-code.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/error-correction-level.js +0 -52
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/error-correction-level.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/finder-pattern.js +0 -25
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/finder-pattern.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/format-info.js +0 -24
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/format-info.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/galois-field.js +0 -38
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/galois-field.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/kanji-data.js +0 -46
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/kanji-data.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/mask-pattern.js +0 -149
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/mask-pattern.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/mode.js +0 -90
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/mode.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/numeric-data.js +0 -41
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/numeric-data.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/polynomial.js +0 -44
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/polynomial.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/qrcode.js +0 -279
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/qrcode.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/reed-solomon-encoder.js +0 -38
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/reed-solomon-encoder.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/regex.js +0 -33
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/regex.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/segments.js +0 -201
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/segments.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/utils.js +0 -84
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/utils.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/version-check.js +0 -14
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/version-check.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/version.js +0 -107
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/core/version.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/renderer/canvas.js +0 -61
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/renderer/canvas.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/renderer/svg-tag.js +0 -64
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/renderer/svg-tag.js.map +0 -1
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/renderer/utils.js +0 -87
- package/dist/node_modules/.pnpm/qrcode@1.5.4/node_modules/qrcode/lib/renderer/utils.js.map +0 -1
- package/dist/profile.schema-CjLOfG7b.js +0 -92
- package/src/modules/auth/controllers/middlewares/visitor.logger.js +0 -75
- package/src/modules/auth/controllers/routes/twofa.routes.js +0 -8
- package/src/modules/auth/controllers/services/twofa.service.js +0 -30
- package/src/modules/auth/models/request.model.js +0 -14
- package/src/modules/auth/models/visitor.model.js +0 -11
- package/src/modules/auth/views/components/pages/EnterCode.vue +0 -204
- package/src/modules/auth/views/components/pages/EnterPassword.vue +0 -123
- package/src/modules/auth/views/components/sections/ProfileEditCredentials.vue +0 -329
- package/src/modules/auth/views/store/twofa.js +0 -70
- package/src/modules/auth//320/220/320/240/320/245/320/230/320/242/320/225/320/232/320/242/320/243/320/240/320/220.md +0 -445
- package/src/modules/backoffice/backoffice.router.js +0 -69
- package/src/modules/backoffice/components/partials/Sidebar.vue +0 -165
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CardHeader.vue.js","sources":["../../../../../../../../src/modules/core/views/components/blocks/CardHeader.vue"],"sourcesContent":["<template>\n\t<header \n\t\tv-if=\"owner\" \n\t\tclass=\"pd-b-zero \"\n\t>\n\t\t<div \n\t\t\tclass=\"w-100 flex-v-center flex-justify-start flex\"\n\t\t>\n\n\t\t\t<div\n\t\t\t\tclass=\"w-100 gap-thin p-regular ws-nowrap flex-nowrap flex-v-center flex\"\n\t\t\t>\n\t\t\t\t<img loading=\"lazy\" \n\t\t\t\t\tv-if=\"owner.target?.profile?.photo?.length > 0 && type !== 'short'\" \n\t\t\t\t\t:src=\"(FILE_SERVER_URL || '') + owner.target.profile.photo\" \n\t\t\t\t\tclass=\"radius-medium bg-white flex-child-default object-fit-cover i-medium\" \n\n\t\t\t\t\t@click.stop=\"$router.push({\n\t\t\t\t\t\tname: owner.type === 'user' ? 'User Profile' : 'Organization', \n\t\t\t\t\t\tparams: {\n\t\t\t\t\t\t\t_id: owner.target._id\n\t\t\t\t\t\t}\n\t\t\t\t\t})\" \n\t\t\t\t/>\n\t\t\t\t<component\n\t\t\t\t\tv-if=\"!owner.target?.profile?.photo && type !== 'short'\"\n\t\t\t\t\t:is=\"owner.type === 'user' ? PlaceholderUserpic : PlaceholderOrganizationPic\"\n\t\t\t\t\tclass=\"radius-medium flex-child-default cursor-pointer i-medium\"\n\n\t\t\t\t\t@click.stop=\"$router.push({\n\t\t\t\t\t\tname: owner.type === 'user' ? 'User Profile' : 'Organization', \n\t\t\t\t\t\tparams: {\n\t\t\t\t\t\t\t_id: owner.target._id\n\t\t\t\t\t\t}\n\t\t\t\t\t})\" \n\t\t\t\t/>\n\n\t\t\t\t<div \n\t\t\t\t\tv-if=\"type !== 'short'\"\n\t\t\t\t\tclass=\"gap-thin flex flex-nowrap fw-medium w-100 pos-relative\"\n\t\t\t\t>\n\t\t\t\t\t<span \n\t\t\t\t\t\t@click.stop=\"$router.push({\n\t\t\t\t\t\t\tname: owner.type === 'user' ? 'User Profile' : 'Organization', \n\t\t\t\t\t\t\tparams: {\n\t\t\t\t\t\t\t\t_id: owner.target._id\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t})\" \n\t\t\t\t\t\tclass=\"cursor-pointer w-max truncate\"\n\t\t\t\t\t>\n\t\t\t\t\t\t{{owner.target?.profile?.name || creator.target?.username || 'Anonymous'}}\n\t\t\t\t\t</span>\n\n\t\t\t\t\t<span v-if=\"!creator.hidden && owner.target?.profile?.name !== creator.target?.profile?.name\">·</span> \n\n\t\t\t\t\t<span\n\t\t\t\t\t\tv-if=\"!creator.hidden && owner.target?.profile?.name !== creator.target?.profile?.name\"\n\t\t\t\t\t\t@click.stop=\"$router.push({\n\t\t\t\t\t\t\tname: 'User Profile', \n\t\t\t\t\t\t\tparams: {\n\t\t\t\t\t\t\t\t_id: creator.target?._id\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t})\" \n\t\t\t\t\t\tclass=\"cursor-pointer w-max truncate\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<div>by {{creator.target?.profile?.name || creator.target?.username || 'Anonymous'}}</div>\n\t\t\t\t\t</span>\n\n\t\t\t\t\t<span v-if=\"date\">·</span> \n\n\t\t\t\t\t<span v-if=\"date\" class=\"pos-relative w-max\">\n\t\t\t\t\t\t<Tooltip v-if=\"date\" :text=\"formatDate(date)\">\n\t\t\t\t\t \t\t{{getTimeElapsed(date)}}\n\t\t\t\t\t \t</Tooltip>\n\t\t\t\t\t</span>\n\n\t\t\t\t\t<span v-if=\"dateFormatted\">·</span>\n\n\t\t\t\t\t<span v-if=\"dateFormatted\"> {{dateFormatted}}</span>\n\t\t\t\t</div>\n\t\t\t\t\n\n\t\t\t\t<!-- Participaters avatar -->\n\t\t\t\t<div class=\"d-block mn-l-auto flex-nowrap flex flex-v-center\">\n\t\t\t\t\t<PhotoStack\n\t\t\t\t\t\tv-if=\"members\"\n\t\t\t\t\t\t:number=\"members\"\n\t\t\t \t:photos=\"membersPhotos\" \n\t\t\t />\n\t\t\t\t</div>\n\n\t\t\t\t<!-- Report -->\n\t\t\t\t<Dropdown \n\t\t\t\t\tv-if=\"type !== 'short' && user && (user !== creator.target?._id || (actions && actions.length > 0))\"\n\t\t\t\t\t:label=\"{ component: IconEllipsis, class: 't-transp i-regular' }\"\n\t\t\t\t\t:align=\"'right'\"\n\t\t\t\t\tclass=\"cursor-pointer z-index-2\"\n\t\t\t\t>\n\t\t\t\t\t<section \n\t\t\t\t\t\tclass=\"bg-black flex-column flex gap-thin pd-thin radius-small\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<FormReport \n\t\t\t\t\t\t\tv-if=\"user !== creator.target?._id\"\n\t\t\t\t\t\t\t:user=\"user\"\n\t\t\t\t\t\t\t:type=\"entityType\" \n\t\t\t\t\t\t\t:target=\"entity._id\" \n\t\t\t\t\t\t\t:text=\"'Report'\" \n\t\t\t\t\t\t\tclass=\"w-100\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<button \n\t\t\t\t\t\t\t\tclass=\"w-100 bg-black br-1px br-white-transp-20 t-white button-small button\"\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\tReport\n\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t</FormReport>\n\n\t\t\t\t\t\t<template \n\t\t\t v-for=\"action in actions\" \n\t\t\t v-if=\"actions && actions.length > 0\"\n\t\t\t >\n\t\t\t <router-link\n\t\t\t v-if=\"action.to\"\n\t\t\t :key=\"action.to\"\n\t\t\t :to=\"action.to\"\n\t\t\t :class=\"action.class || 'w-100 bg-black br-1px br-white-transp-20 t-white button-small button'\"\n\t\t\t >\n\t\t\t {{ action.label }}\n\t\t\t </router-link>\n\n\t\t\t <button\n\t\t\t v-if=\"action.method\"\n\t\t\t @click=\"action.method\"\n\t\t\t :class=\"action.class || 'w-100 bg-black br-1px br-white-transp-20 t-white button-small button'\"\n\t\t\t >\n\t\t\t {{ action.label }}\n\t\t\t </button>\n\t\t\t </template>\n\t\t\t\t\t</section>\n\t\t </Dropdown>\t\n\t\t\t</div>\n\t\t</div>\n\t</header>\n</template>\n\n\n<script setup=\"props\">\n\timport { computed,ref } from 'vue'\n\n\timport { useRouter } from 'vue-router'\n\n\timport Tooltip from '@martyrs/src/components/Tooltip/Tooltip.vue'\n\timport Dropdown from \"@martyrs/src/components/Dropdown/Dropdown.vue\";\n\n\timport PlaceholderUserpic from '@martyrs/src/modules/icons/placeholders/PlaceholderUserpic.vue'\n\timport PlaceholderOrganizationPic from '@martyrs/src/modules/icons/placeholders/PlaceholderOrganizationPic.vue'\n\timport IconEllipsis from '@martyrs/src/modules/icons/navigation/IconEllipsis.vue'\n\n\timport FormReport from '@martyrs/src/modules/reports/components/sections/FormReport.vue' \n\timport ButtonToggleMembership from '@martyrs/src/modules/organizations/components/elements/ButtonToggleMembership.vue'\n\n\timport PhotoStack from \"@martyrs/src/modules/core/views/components/elements/PhotoStack.vue\"\n\n\n\tconst props = defineProps([\n\t\t'user',\n\t\t'entity',\n\t\t'entityType',\n\t\t'date',\n\t\t'dateFormatted',\n\t\t'owner',\n\t\t'creator',\n\t\t'members',\n\t\t'membersPhotos',\n\t\t'type',\n\t\t'actions'\n\t])\n\n\tconst router = useRouter()\n\n\tfunction getTimeElapsed(timestamp) {\n\t const now = new Date();\n\t const createdAt = new Date(timestamp);\n\t const timeDiff = Math.abs(now - createdAt);\n\t const seconds = Math.floor(timeDiff / 1000);\n\t const minutes = Math.floor(seconds / 60);\n\t const hours = Math.floor(minutes / 60);\n\t const days = Math.floor(hours / 24);\n\t const weeks = Math.floor(days / 7);\n\t \n\t if (weeks > 0) {\n\t return `${weeks} week${weeks > 1 ? 's' : ''} ago`;\n\t } else if (days > 0) {\n\t return `${days} day${days > 1 ? 's' : ''} ago`;\n\t } else if (hours > 0) {\n\t return `${hours} hour${hours > 1 ? 's' : ''} ago`;\n\t } else if (minutes > 0) {\n\t return `${minutes} minute${minutes > 1 ? 's' : ''} ago`;\n\t } else {\n\t return 'Just now';\n\t }\n\t}\n\n</script>\n\n<style lang=\"scss\">\n</style>\n\n\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CardHeader.vue.js","sources":["../../../../../../../../src/modules/core/views/components/blocks/CardHeader.vue"],"sourcesContent":["<template>\n\t<header \n\t\tv-if=\"owner\" \n\t\tclass=\"pd-b-zero \"\n\t>\n\t\t<div \n\t\t\tclass=\"w-100 flex-v-center flex-justify-start flex\"\n\t\t>\n\n\t\t\t<div\n\t\t\t\tclass=\"w-100 gap-thin p-regular ws-nowrap flex-nowrap flex-v-center flex\"\n\t\t\t>\n\t\t\t\t<img loading=\"lazy\" \n\t\t\t\t\tv-if=\"owner.target?.profile?.photo?.length > 0 && type !== 'short'\" \n\t\t\t\t\t:src=\"(FILE_SERVER_URL || '') + owner.target.profile.photo\" \n\t\t\t\t\tclass=\"radius-medium bg-white flex-child-default object-fit-cover i-medium\" \n\n\t\t\t\t\t@click.stop=\"$router.push({\n\t\t\t\t\t\tname: owner.type === 'user' ? 'User Profile' : 'Organization', \n\t\t\t\t\t\tparams: {\n\t\t\t\t\t\t\t_id: owner.target._id\n\t\t\t\t\t\t}\n\t\t\t\t\t})\" \n\t\t\t\t/>\n\t\t\t\t<component\n\t\t\t\t\tv-if=\"!owner.target?.profile?.photo && type !== 'short'\"\n\t\t\t\t\t:is=\"owner.type === 'user' ? PlaceholderUserpic : PlaceholderOrganizationPic\"\n\t\t\t\t\tclass=\"radius-medium flex-child-default cursor-pointer i-medium\"\n\n\t\t\t\t\t@click.stop=\"$router.push({\n\t\t\t\t\t\tname: owner.type === 'user' ? 'User Profile' : 'Organization', \n\t\t\t\t\t\tparams: {\n\t\t\t\t\t\t\t_id: owner.target._id\n\t\t\t\t\t\t}\n\t\t\t\t\t})\" \n\t\t\t\t/>\n\n\t\t\t\t<div \n\t\t\t\t\tv-if=\"type !== 'short'\"\n\t\t\t\t\tclass=\"gap-thin flex flex-nowrap fw-medium w-100 pos-relative\"\n\t\t\t\t>\n\t\t\t\t\t<span \n\t\t\t\t\t\t@click.stop=\"$router.push({\n\t\t\t\t\t\t\tname: owner.type === 'user' ? 'User Profile' : 'Organization', \n\t\t\t\t\t\t\tparams: {\n\t\t\t\t\t\t\t\t_id: owner.target._id\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t})\" \n\t\t\t\t\t\tclass=\"cursor-pointer w-max truncate\"\n\t\t\t\t\t>\n\t\t\t\t\t\t{{owner.target?.profile?.name || creator.target?.username || 'Anonymous'}}\n\t\t\t\t\t</span>\n\n\t\t\t\t\t<span v-if=\"!creator.hidden && owner.target?.profile?.name !== creator.target?.profile?.name\">·</span> \n\n\t\t\t\t\t<span\n\t\t\t\t\t\tv-if=\"!creator.hidden && owner.target?.profile?.name !== creator.target?.profile?.name\"\n\t\t\t\t\t\t@click.stop=\"$router.push({\n\t\t\t\t\t\t\tname: 'User Profile', \n\t\t\t\t\t\t\tparams: {\n\t\t\t\t\t\t\t\t_id: creator.target?._id\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t})\" \n\t\t\t\t\t\tclass=\"cursor-pointer w-max truncate\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<div>by {{creator.target?.profile?.name || creator.target?.username || 'Anonymous'}}</div>\n\t\t\t\t\t</span>\n\n\t\t\t\t\t<span v-if=\"date\">·</span> \n\n\t\t\t\t\t<span v-if=\"date\" class=\"pos-relative w-max\">\n\t\t\t\t\t\t<Tooltip v-if=\"date\" :text=\"formatDate(date)\">\n\t\t\t\t\t \t\t{{getTimeElapsed(date)}}\n\t\t\t\t\t \t</Tooltip>\n\t\t\t\t\t</span>\n\n\t\t\t\t\t<span v-if=\"dateFormatted\">·</span>\n\n\t\t\t\t\t<span v-if=\"dateFormatted\"> {{dateFormatted}}</span>\n\t\t\t\t</div>\n\t\t\t\t\n\n\t\t\t\t<!-- Participaters avatar -->\n\t\t\t\t<div class=\"d-block mn-l-auto flex-nowrap flex flex-v-center\">\n\t\t\t\t\t<PhotoStack\n\t\t\t\t\t\tv-if=\"members\"\n\t\t\t\t\t\t:number=\"members\"\n\t\t\t \t:photos=\"membersPhotos\" \n\t\t\t />\n\t\t\t\t</div>\n\n\t\t\t\t<!-- Report -->\n\t\t\t\t<Dropdown \n\t\t\t\t\tv-if=\"type !== 'short' && user && (user !== creator.target?._id || (actions && actions.length > 0))\"\n\t\t\t\t\t:label=\"{ component: IconEllipsis, class: 't-transp i-regular' }\"\n\t\t\t\t\t:align=\"'right'\"\n\t\t\t\t\tclass=\"cursor-pointer z-index-2\"\n\t\t\t\t>\n\t\t\t\t\t<section \n\t\t\t\t\t\tclass=\"bg-black flex-column flex gap-thin pd-thin radius-small\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<FormReport \n\t\t\t\t\t\t\tv-if=\"user !== creator.target?._id\"\n\t\t\t\t\t\t\t:user=\"user\"\n\t\t\t\t\t\t\t:type=\"entityType\" \n\t\t\t\t\t\t\t:target=\"entity._id\" \n\t\t\t\t\t\t\t:text=\"'Report'\" \n\t\t\t\t\t\t\tclass=\"w-100\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<button \n\t\t\t\t\t\t\t\tclass=\"w-100 bg-black br-1px br-white-transp-20 t-white button-small button\"\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\tReport\n\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t</FormReport>\n\n\t\t\t\t\t\t<template \n\t\t\t v-for=\"action in actions\" \n\t\t\t v-if=\"actions && actions.length > 0\"\n\t\t\t >\n\t\t\t <router-link\n\t\t\t v-if=\"action.to\"\n\t\t\t :key=\"action.to\"\n\t\t\t :to=\"action.to\"\n\t\t\t :class=\"action.class || 'w-100 bg-black br-1px br-white-transp-20 t-white button-small button'\"\n\t\t\t >\n\t\t\t {{ action.label }}\n\t\t\t </router-link>\n\n\t\t\t <button\n\t\t\t v-if=\"action.method\"\n\t\t\t @click=\"action.method\"\n\t\t\t :class=\"action.class || 'w-100 bg-black br-1px br-white-transp-20 t-white button-small button'\"\n\t\t\t >\n\t\t\t {{ action.label }}\n\t\t\t </button>\n\t\t\t </template>\n\t\t\t\t\t</section>\n\t\t </Dropdown>\t\n\t\t\t</div>\n\t\t</div>\n\t</header>\n</template>\n\n\n<script setup=\"props\">\n\timport { computed,ref } from 'vue'\n\n\timport { useRouter } from 'vue-router'\n\n\timport Tooltip from '@martyrs/src/components/Tooltip/Tooltip.vue'\n\timport Dropdown from \"@martyrs/src/components/Dropdown/Dropdown.vue\";\n\n\timport PlaceholderUserpic from '@martyrs/src/modules/icons/placeholders/PlaceholderUserpic.vue'\n\timport PlaceholderOrganizationPic from '@martyrs/src/modules/icons/placeholders/PlaceholderOrganizationPic.vue'\n\timport IconEllipsis from '@martyrs/src/modules/icons/navigation/IconEllipsis.vue'\n\n\timport FormReport from '@martyrs/src/modules/reports/components/sections/FormReport.vue' \n\timport ButtonToggleMembership from '@martyrs/src/modules/organizations/components/elements/ButtonToggleMembership.vue'\n\n\timport PhotoStack from \"@martyrs/src/modules/core/views/components/elements/PhotoStack.vue\"\n\n\n\tconst props = defineProps([\n\t\t'user',\n\t\t'entity',\n\t\t'entityType',\n\t\t'date',\n\t\t'dateFormatted',\n\t\t'owner',\n\t\t'creator',\n\t\t'members',\n\t\t'membersPhotos',\n\t\t'type',\n\t\t'actions'\n\t])\n\n\tconst router = useRouter()\n\n\tfunction getTimeElapsed(timestamp) {\n\t const now = new Date();\n\t const createdAt = new Date(timestamp);\n\t const timeDiff = Math.abs(now - createdAt);\n\t const seconds = Math.floor(timeDiff / 1000);\n\t const minutes = Math.floor(seconds / 60);\n\t const hours = Math.floor(minutes / 60);\n\t const days = Math.floor(hours / 24);\n\t const weeks = Math.floor(days / 7);\n\t \n\t if (weeks > 0) {\n\t return `${weeks} week${weeks > 1 ? 's' : ''} ago`;\n\t } else if (days > 0) {\n\t return `${days} day${days > 1 ? 's' : ''} ago`;\n\t } else if (hours > 0) {\n\t return `${hours} hour${hours > 1 ? 's' : ''} ago`;\n\t } else if (minutes > 0) {\n\t return `${minutes} minute${minutes > 1 ? 's' : ''} ago`;\n\t } else {\n\t return 'Just now';\n\t }\n\t}\n\n</script>\n\n<style lang=\"scss\">\n</style>\n\n\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiLgB,cAAS;AAExB,aAAS,eAAe,WAAW;AACjC,YAAM,MAAM,oBAAI,KAAI;AACpB,YAAM,YAAY,IAAI,KAAK,SAAS;AACpC,YAAM,WAAW,KAAK,IAAI,MAAM,SAAS;AACzC,YAAM,UAAU,KAAK,MAAM,WAAW,GAAI;AAC1C,YAAM,UAAU,KAAK,MAAM,UAAU,EAAE;AACvC,YAAM,QAAQ,KAAK,MAAM,UAAU,EAAE;AACrC,YAAM,OAAO,KAAK,MAAM,QAAQ,EAAE;AAClC,YAAM,QAAQ,KAAK,MAAM,OAAO,CAAC;AAEjC,UAAI,QAAQ,GAAG;AACb,eAAO,GAAG,KAAK,QAAQ,QAAQ,IAAI,MAAM,EAAE;AAAA,MAC7C,WAAW,OAAO,GAAG;AACnB,eAAO,GAAG,IAAI,OAAO,OAAO,IAAI,MAAM,EAAE;AAAA,MAC1C,WAAW,QAAQ,GAAG;AACpB,eAAO,GAAG,KAAK,QAAQ,QAAQ,IAAI,MAAM,EAAE;AAAA,MAC7C,WAAW,UAAU,GAAG;AACtB,eAAO,GAAG,OAAO,UAAU,UAAU,IAAI,MAAM,EAAE;AAAA,MACnD,OAAO;AACL,eAAO;AAAA,MACT;AAAA,IACF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createBlock, openBlock, withCtx, createElementVNode, toDisplayString, createVNode, createTextVNode } from "vue";
|
|
2
2
|
import { useRouter, useRoute } from "vue-router";
|
|
3
3
|
import _sfc_main$1 from "../../../../../components/Popup/Popup.vue.js";
|
|
4
|
-
import _sfc_main$2 from "../../../../../components/Button/Button.
|
|
4
|
+
import _sfc_main$2 from "../../../../../components/Button/Button.vue.js";
|
|
5
5
|
const _hoisted_1 = { class: "t-center" };
|
|
6
6
|
const _hoisted_2 = { class: "mn-b-medium" };
|
|
7
7
|
const _hoisted_3 = { class: "mn-b-semi t-transp" };
|
|
@@ -3,7 +3,7 @@ import { useI18n } from "vue-i18n";
|
|
|
3
3
|
import _sfc_main$1 from "../../../../../components/Popup/Popup.vue.js";
|
|
4
4
|
import Loader from "../../../../../components/Loader/Loader.vue.js";
|
|
5
5
|
import Calendar from "../../../../../components/Calendar/Calendar.vue2.js";
|
|
6
|
-
import _sfc_main$3 from "../../../../../components/Button/Button.
|
|
6
|
+
import _sfc_main$3 from "../../../../../components/Button/Button.vue.js";
|
|
7
7
|
import _sfc_main$4 from "../../../../icons/actions/IconShopcartAdd.vue.js";
|
|
8
8
|
import _sfc_main$2 from "../../../../orders/components/elements/PriceTotal.vue.js";
|
|
9
9
|
import { loadAvailability } from "../../../../rents/views/store/rents.store.js";
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { ref, onMounted, onUnmounted, watch, createBlock, openBlock, withCtx, createElementVNode, normalizeClass } from "vue";
|
|
2
|
+
import _sfc_main$1 from "../../../../../components/Tooltip/Tooltip.vue2.js";
|
|
3
|
+
import { wsManager } from "../../classes/ws.manager.js";
|
|
4
|
+
/* empty css */
|
|
5
|
+
const _sfc_main = {
|
|
6
|
+
__name: "OnlineIndicator",
|
|
7
|
+
props: {
|
|
8
|
+
userId: {
|
|
9
|
+
type: String,
|
|
10
|
+
required: true
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
setup(__props) {
|
|
14
|
+
const props = __props;
|
|
15
|
+
const isOnline = ref(false);
|
|
16
|
+
const lastSeenAt = ref(null);
|
|
17
|
+
let pollInterval = null;
|
|
18
|
+
async function fetchStatus() {
|
|
19
|
+
if (!props.userId) return;
|
|
20
|
+
if (!wsManager.isConnected) {
|
|
21
|
+
await new Promise((resolve) => setTimeout(resolve, 1e3));
|
|
22
|
+
if (!wsManager.isConnected) return;
|
|
23
|
+
}
|
|
24
|
+
try {
|
|
25
|
+
const result = await wsManager.rpc("core", "getOnlineStatus", { userId: props.userId });
|
|
26
|
+
console.log("[OnlineIndicator] status:", result);
|
|
27
|
+
isOnline.value = result.isOnline;
|
|
28
|
+
lastSeenAt.value = result.lastSeenAt;
|
|
29
|
+
} catch (err) {
|
|
30
|
+
console.error("Failed to fetch online status:", err);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
function formatLastSeen(date) {
|
|
34
|
+
if (!date) return "";
|
|
35
|
+
const d = new Date(date);
|
|
36
|
+
const now = /* @__PURE__ */ new Date();
|
|
37
|
+
const diff = now - d;
|
|
38
|
+
const minutes = Math.floor(diff / 6e4);
|
|
39
|
+
const hours = Math.floor(diff / 36e5);
|
|
40
|
+
const days = Math.floor(diff / 864e5);
|
|
41
|
+
if (minutes < 1) return "Just now";
|
|
42
|
+
if (minutes < 60) return `${minutes}m ago`;
|
|
43
|
+
if (hours < 24) return `${hours}h ago`;
|
|
44
|
+
if (days < 7) return `${days}d ago`;
|
|
45
|
+
return d.toLocaleDateString();
|
|
46
|
+
}
|
|
47
|
+
onMounted(() => {
|
|
48
|
+
fetchStatus();
|
|
49
|
+
pollInterval = setInterval(fetchStatus, 6e4);
|
|
50
|
+
});
|
|
51
|
+
onUnmounted(() => {
|
|
52
|
+
if (pollInterval) clearInterval(pollInterval);
|
|
53
|
+
});
|
|
54
|
+
watch(() => props.userId, () => {
|
|
55
|
+
fetchStatus();
|
|
56
|
+
});
|
|
57
|
+
return (_ctx, _cache) => {
|
|
58
|
+
return openBlock(), createBlock(_sfc_main$1, {
|
|
59
|
+
text: isOnline.value ? "Online" : lastSeenAt.value ? formatLastSeen(lastSeenAt.value) : "Offline"
|
|
60
|
+
}, {
|
|
61
|
+
default: withCtx(() => [
|
|
62
|
+
createElementVNode("div", {
|
|
63
|
+
class: normalizeClass(["i-medium online-indicator", { "is-online": isOnline.value }])
|
|
64
|
+
}, null, 2)
|
|
65
|
+
]),
|
|
66
|
+
_: 1
|
|
67
|
+
}, 8, ["text"]);
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
};
|
|
71
|
+
export {
|
|
72
|
+
_sfc_main as default
|
|
73
|
+
};
|
|
74
|
+
//# sourceMappingURL=OnlineIndicator.vue.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OnlineIndicator.vue.js","sources":["../../../../../../../../src/modules/core/views/components/elements/OnlineIndicator.vue"],"sourcesContent":["<template>\n <Tooltip :text=\"isOnline ? 'Online' : (lastSeenAt ? formatLastSeen(lastSeenAt) : 'Offline')\">\n <div\n class=\"i-medium online-indicator\"\n :class=\"{ 'is-online': isOnline }\"\n />\n </Tooltip>\n</template>\n\n<script setup>\nimport { ref, onMounted, onUnmounted, watch } from 'vue';\nimport Tooltip from '@martyrs/src/components/Tooltip/Tooltip.vue';\nimport wsManager from '@martyrs/src/modules/core/views/classes/ws.manager.js';\n\nconst props = defineProps({\n userId: {\n type: String,\n required: true,\n },\n});\n\nconst isOnline = ref(false);\nconst lastSeenAt = ref(null);\nlet pollInterval = null;\n\nasync function fetchStatus() {\n if (!props.userId) return;\n // Ждем подключения если еще не подключен\n if (!wsManager.isConnected) {\n await new Promise(resolve => setTimeout(resolve, 1000));\n if (!wsManager.isConnected) return;\n }\n try {\n const result = await wsManager.rpc('core', 'getOnlineStatus', { userId: props.userId });\n console.log('[OnlineIndicator] status:', result);\n isOnline.value = result.isOnline;\n lastSeenAt.value = result.lastSeenAt;\n } catch (err) {\n console.error('Failed to fetch online status:', err);\n }\n}\n\nfunction formatLastSeen(date) {\n if (!date) return '';\n const d = new Date(date);\n const now = new Date();\n const diff = now - d;\n const minutes = Math.floor(diff / 60000);\n const hours = Math.floor(diff / 3600000);\n const days = Math.floor(diff / 86400000);\n\n if (minutes < 1) return 'Just now';\n if (minutes < 60) return `${minutes}m ago`;\n if (hours < 24) return `${hours}h ago`;\n if (days < 7) return `${days}d ago`;\n return d.toLocaleDateString();\n}\n\nonMounted(() => {\n fetchStatus();\n pollInterval = setInterval(fetchStatus, 60000);\n});\n\nonUnmounted(() => {\n if (pollInterval) clearInterval(pollInterval);\n});\n\nwatch(() => props.userId, () => {\n fetchStatus();\n});\n</script>\n\n<style lang=\"scss\">\n.online-indicator {\n position: relative;\n border-radius: 50%;\n background: rgb(var(--grey));\n border: 3px solid rgb(var(--light));\n flex-shrink: 0;\n\n &.is-online {\n background: rgb(var(--green));\n\n &::before,\n &::after {\n content: \"\";\n position: absolute;\n top: 50%;\n left: 50%;\n width: 100%;\n height: 100%;\n background: inherit;\n border-radius: 50%;\n transform: translate(-50%, -50%);\n animation: indicator-pulse 2s infinite ease-out;\n }\n\n &::after {\n animation-delay: 1s;\n }\n }\n\n}\n\n@keyframes indicator-pulse {\n 0% {\n transform: translate(-50%, -50%) scale(1);\n opacity: 0.5;\n }\n 100% {\n transform: translate(-50%, -50%) scale(1.8);\n opacity: 0;\n }\n}\n</style>\n"],"names":[],"mappings":";;;;;;;;;;;;;AAcA,UAAM,QAAQ;AAOd,UAAM,WAAW,IAAI,KAAK;AAC1B,UAAM,aAAa,IAAI,IAAI;AAC3B,QAAI,eAAe;AAEnB,mBAAe,cAAc;AAC3B,UAAI,CAAC,MAAM,OAAQ;AAEnB,UAAI,CAAC,UAAU,aAAa;AAC1B,cAAM,IAAI,QAAQ,aAAW,WAAW,SAAS,GAAI,CAAC;AACtD,YAAI,CAAC,UAAU,YAAa;AAAA,MAC9B;AACA,UAAI;AACF,cAAM,SAAS,MAAM,UAAU,IAAI,QAAQ,mBAAmB,EAAE,QAAQ,MAAM,QAAQ;AACtF,gBAAQ,IAAI,6BAA6B,MAAM;AAC/C,iBAAS,QAAQ,OAAO;AACxB,mBAAW,QAAQ,OAAO;AAAA,MAC5B,SAAS,KAAK;AACZ,gBAAQ,MAAM,kCAAkC,GAAG;AAAA,MACrD;AAAA,IACF;AAEA,aAAS,eAAe,MAAM;AAC5B,UAAI,CAAC,KAAM,QAAO;AAClB,YAAM,IAAI,IAAI,KAAK,IAAI;AACvB,YAAM,MAAM,oBAAI,KAAI;AACpB,YAAM,OAAO,MAAM;AACnB,YAAM,UAAU,KAAK,MAAM,OAAO,GAAK;AACvC,YAAM,QAAQ,KAAK,MAAM,OAAO,IAAO;AACvC,YAAM,OAAO,KAAK,MAAM,OAAO,KAAQ;AAEvC,UAAI,UAAU,EAAG,QAAO;AACxB,UAAI,UAAU,GAAI,QAAO,GAAG,OAAO;AACnC,UAAI,QAAQ,GAAI,QAAO,GAAG,KAAK;AAC/B,UAAI,OAAO,EAAG,QAAO,GAAG,IAAI;AAC5B,aAAO,EAAE,mBAAkB;AAAA,IAC7B;AAEA,cAAU,MAAM;AACd,kBAAW;AACX,qBAAe,YAAY,aAAa,GAAK;AAAA,IAC/C,CAAC;AAED,gBAAY,MAAM;AAChB,UAAI,aAAc,eAAc,YAAY;AAAA,IAC9C,CAAC;AAED,UAAM,MAAM,MAAM,QAAQ,MAAM;AAC9B,kBAAW;AAAA,IACb,CAAC;;;;;;;;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"App.vue.js","sources":["../../../../../../../../src/modules/core/views/components/layouts/App.vue"],"sourcesContent":["<template>\n <router-view \n v-slot=\"{ Component }\"\n >\n <component \n ref=\"page\" \n :env=\"env\"\n :app=\"app\"\n :modules=\"modules\"\n :is=\"Component\"\n />\n </router-view>\n</template>\n\n<script setup>\n import { computed, ref, onMounted,
|
|
1
|
+
{"version":3,"file":"App.vue.js","sources":["../../../../../../../../src/modules/core/views/components/layouts/App.vue"],"sourcesContent":["<template>\n <router-view \n v-slot=\"{ Component }\"\n >\n <component \n ref=\"page\" \n :env=\"env\"\n :app=\"app\"\n :modules=\"modules\"\n :is=\"Component\"\n />\n </router-view>\n</template>\n\n<script setup>\n import { computed, ref, onMounted, onBeforeMount } from 'vue'\n import { Preferences } from '@capacitor/preferences';\n import { Keyboard } from '@capacitor/keyboard';\n\n import { useHead } from '@unhead/vue'\n import { useI18n } from 'vue-i18n'\n import { useRoute } from 'vue-router'\n\n import { useStore } from '@martyrs/src/modules/core/views/store/core.store.js'\n\n const store = useStore()\n\n const props = defineProps({\n env: {\n type: Object,\n required: true\n },\n app: {\n type: Object,\n required: true\n },\n modules: {\n type: Object,\n required: true\n }\n })\n /////////////////////////////\n // LOADING\n /////////////////////////////\n // State\n let show = ref(false)\n // Preloader\n const page = ref(null)\n /////////////////////////////\n // META\n /////////////////////////////\n const { t, locale, availableLocales } = useI18n({\n messages: props.app.messages\n })\n\n const route = useRoute();\n\n const languages = availableLocales;\n const base_url = process.env.FILE_SERVER_URL;\n\n function removeTrailingSlash(url) {\n return url.endsWith('/') ? url.slice(0, -1) : url;\n }\n // Используйте эту функцию, чтобы удалить слэш в конце URL\n const metadata = computed(() => {return {\n title: t('meta.title'),\n description: t('meta.description'),\n meta: [\n { charset: 'utf-8' },\n { name: 'viewport', content: 'width=device-width, initial-scale=1, shrink-to-fit=no' },\n { hid: 'description', name: 'description', content: t('meta.description') },\n { hid: 'keywords', name: 'keywords', content: t('meta.keywords') },\n { hid: 'og:title', property: 'og:title', content: t('meta.og.title') },\n { hid: 'og:description', property: 'og:description', content: t('meta.og.description') },\n { hid: 'og:image', property: 'og:image', content: base_url + '/favicon/cover.jpg' },\n { hid: 'og:url', property: 'og:url', content: removeTrailingSlash(`${base_url}${route.path}`) },\n { hid: 'twitter:title', name: 'twitter:title', content: t('meta.twitter.title') },\n { hid: 'twitter:description', name: 'twitter:description', content: t('meta.twitter.description') },\n { hid: 'twitter:image', name: 'twitter:image', content: base_url + '/favicon/cover.jpg' },\n { hid: 'twitter:card', name: 'twitter:card', content: t('meta.twitter.card') },\n ],\n link: [\n { hid: 'canonical', rel: 'canonical', href: removeTrailingSlash(`${base_url}${route.path}`) },\n ...generateAlternateLinks.value,\n ],\n htmlAttrs: { lang: t('meta.htmlAttrs.lang') }\n }});\n\n const generateAlternateLinks = computed(() => {\n return languages.map(lang => {\n let newPath = route.path;\n\n if (route.params.locale) {\n newPath = newPath.replace(`/${route.params.locale}`, `/${lang}`);\n } else {\n newPath = `/${lang}${newPath}`;\n }\n const href = removeTrailingSlash(`${base_url}${newPath}`);\n return { \n hid: 'alternate', \n rel: 'alternate', \n hreflang: lang, \n href: href\n };\n });\n });\n\n useHead(metadata)\n\n onBeforeMount(async () => {\n if (process.env.MOBILE_APP === 'ios') Keyboard.setAccessoryBarVisible({ isVisible: false })\n\n // Для Mobile (Capacitor) - читаем из Preferences\n if (process.env.MOBILE_APP) {\n const { value } = await Preferences.get({ key: 'theme' });\n const mode = value || 'system';\n store.core.actions.setTheme(mode);\n } else {\n // Для SSR/SPA - инициализируем state из уже проставленного SSR атрибута\n const root = document.documentElement;\n const dataTheme = root.getAttribute('data-theme');\n\n if (dataTheme === 'dark') {\n store.core.state.theme.mode = 'dark';\n } else if (dataTheme === 'light') {\n store.core.state.theme.mode = 'light';\n } else {\n store.core.state.theme.mode = 'system';\n }\n }\n })\n\n onMounted(() => {\n // Слушаем изменения системной темы\n const mediaQuery = window.matchMedia('(prefers-color-scheme: dark)');\n \n mediaQuery.addEventListener('change', (e) => {\n // При изменении системной темы, если режим 'system' - обновляем CSS\n if (store.core.state.theme.mode === 'system') {\n store.core.actions.setTheme('system');\n }\n });\n })\n</script>"],"names":[],"mappings":"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"}
|
|
@@ -2,16 +2,16 @@ import { ref, computed, onMounted, resolveComponent, createElementBlock, openBlo
|
|
|
2
2
|
import { useRoute } from "vue-router";
|
|
3
3
|
import { useStore } from "../../store/core.store.js";
|
|
4
4
|
import { useGlobalMixins } from "../../mixins/mixins.js";
|
|
5
|
-
import _sfc_main$
|
|
6
|
-
import _sfc_main$
|
|
7
|
-
import _sfc_main$
|
|
5
|
+
import _sfc_main$1 from "../../../../../components/Status/Status.vue.js";
|
|
6
|
+
import _sfc_main$2 from "../../../../../components/Status/Snack.vue.js";
|
|
7
|
+
import _sfc_main$3 from "../../../../../components/Popup/Popup.vue.js";
|
|
8
8
|
import "vue-i18n";
|
|
9
9
|
/* empty css */
|
|
10
10
|
import Loader from "../../../../../components/Loader/Loader.vue.js";
|
|
11
|
-
/* empty css
|
|
11
|
+
/* empty css */
|
|
12
12
|
/* empty css */
|
|
13
|
-
import _sfc_main$
|
|
14
|
-
import _sfc_main$
|
|
13
|
+
import _sfc_main$4 from "../partials/LocationSelection.vue.js";
|
|
14
|
+
import _sfc_main$5 from "../../../../orders/components/partials/ShopCart.vue.js";
|
|
15
15
|
import { Preferences } from "../../../../../../node_modules/.pnpm/@capacitor_preferences@7.0.2_@capacitor_core@7.4.4/node_modules/@capacitor/preferences/dist/esm/index.js";
|
|
16
16
|
/* empty css */
|
|
17
17
|
const _hoisted_1 = {
|
|
@@ -108,18 +108,18 @@ const _sfc_main = {
|
|
|
108
108
|
});
|
|
109
109
|
const componentKey = computed(() => {
|
|
110
110
|
const significantParams = ["_id", "product", "organization", "categoryPath", "country", "state", "city"].map((param) => route.params[param]).filter(Boolean).join("-");
|
|
111
|
-
return significantParams || route.name;
|
|
111
|
+
return significantParams || route.meta.layoutKey || route.name;
|
|
112
112
|
});
|
|
113
113
|
return (_ctx, _cache) => {
|
|
114
114
|
const _component_router_view = resolveComponent("router-view");
|
|
115
115
|
return openBlock(), createElementBlock("div", {
|
|
116
|
-
id: "app-wrapper",
|
|
117
116
|
class: normalizeClass(["flex flex-column h-100 w-100 pos-relative o-hidden", {
|
|
118
117
|
[(unref(route).name ? unref(route).name.replace(/\s+/g, "_") : unref(route).path.replace(/\W+/g, "_")).toLowerCase()]: true,
|
|
119
118
|
"pd-t-big": _ctx.MOBILE_APP === "ios",
|
|
120
119
|
"bg-white": headerTheme.value === "light",
|
|
121
120
|
"bg-black": headerTheme.value === "dark"
|
|
122
|
-
}])
|
|
121
|
+
}]),
|
|
122
|
+
id: "app-wrapper"
|
|
123
123
|
}, [
|
|
124
124
|
createVNode(Transition, {
|
|
125
125
|
name: "moveFromTop",
|
|
@@ -128,8 +128,8 @@ const _sfc_main = {
|
|
|
128
128
|
default: withCtx(() => [
|
|
129
129
|
!page.value || unref(store).core.state.loading ? (openBlock(), createBlock(Loader, {
|
|
130
130
|
key: 0,
|
|
131
|
-
|
|
132
|
-
|
|
131
|
+
class: "pos-fixed z-index-10",
|
|
132
|
+
centered: true
|
|
133
133
|
})) : createCommentVNode("", true)
|
|
134
134
|
]),
|
|
135
135
|
_: 1
|
|
@@ -141,15 +141,45 @@ const _sfc_main = {
|
|
|
141
141
|
default: withCtx(() => [
|
|
142
142
|
FirstUse.value && unref(route).meta.walkthrough ? (openBlock(), createElementBlock("section", _hoisted_1, [
|
|
143
143
|
(openBlock(), createBlock(resolveDynamicComponent(unref(route).meta.walkthrough), {
|
|
144
|
+
class: "tab",
|
|
144
145
|
name: "Walkthrough",
|
|
145
146
|
onUpdateFirstUse: updateFirstUse,
|
|
146
|
-
slides: [1, 2, 3]
|
|
147
|
-
class: "tab"
|
|
147
|
+
slides: [1, 2, 3]
|
|
148
148
|
}, null, 32))
|
|
149
149
|
])) : createCommentVNode("", true)
|
|
150
150
|
]),
|
|
151
151
|
_: 1
|
|
152
152
|
}),
|
|
153
|
+
createVNode(Transition, {
|
|
154
|
+
name: "moveFromTop",
|
|
155
|
+
mode: "out-in"
|
|
156
|
+
}, {
|
|
157
|
+
default: withCtx(() => [
|
|
158
|
+
unref(store).core.state.error.show ? (openBlock(), createBlock(_sfc_main$1, {
|
|
159
|
+
key: 0,
|
|
160
|
+
class: "z-index-10",
|
|
161
|
+
data: unref(store).core.state.error,
|
|
162
|
+
onClose: _cache[0] || (_cache[0] = ($event) => unref(store).core.state.error.show = false)
|
|
163
|
+
}, null, 8, ["data"])) : createCommentVNode("", true)
|
|
164
|
+
]),
|
|
165
|
+
_: 1
|
|
166
|
+
}),
|
|
167
|
+
createVNode(Transition, {
|
|
168
|
+
name: "moveFromTop",
|
|
169
|
+
mode: "out-in"
|
|
170
|
+
}, {
|
|
171
|
+
default: withCtx(() => [
|
|
172
|
+
unref(store).core.state.snack.show ? (openBlock(), createBlock(_sfc_main$2, {
|
|
173
|
+
key: 0,
|
|
174
|
+
class: "z-index-10",
|
|
175
|
+
type: unref(store).core.state.snack.type,
|
|
176
|
+
message: unref(store).core.state.snack.message,
|
|
177
|
+
show: unref(store).core.state.snack.show,
|
|
178
|
+
onClose: _cache[1] || (_cache[1] = ($event) => unref(store).core.state.snack.show = false)
|
|
179
|
+
}, null, 8, ["type", "message", "show"])) : createCommentVNode("", true)
|
|
180
|
+
]),
|
|
181
|
+
_: 1
|
|
182
|
+
}),
|
|
153
183
|
!_ctx.MOBILE_APP && unref(route).meta.header ? (openBlock(), createBlock(resolveDynamicComponent(unref(route).meta.header), {
|
|
154
184
|
key: 0,
|
|
155
185
|
ref_key: "header",
|
|
@@ -187,24 +217,24 @@ const _sfc_main = {
|
|
|
187
217
|
]),
|
|
188
218
|
_: 1
|
|
189
219
|
}),
|
|
190
|
-
createVNode(_sfc_main$
|
|
220
|
+
createVNode(_sfc_main$3, {
|
|
221
|
+
class: "bg-white pd-semi w-m-33r radius-big",
|
|
191
222
|
onClosePopup: closeLocationPopup,
|
|
192
|
-
isPopupOpen: unref(store).core.state.isOpenLocationPopup
|
|
193
|
-
class: "bg-white pd-semi w-m-33r radius-big"
|
|
223
|
+
isPopupOpen: unref(store).core.state.isOpenLocationPopup
|
|
194
224
|
}, {
|
|
195
225
|
default: withCtx(() => [
|
|
196
|
-
createVNode(_sfc_main$
|
|
226
|
+
createVNode(_sfc_main$4)
|
|
197
227
|
]),
|
|
198
228
|
_: 1
|
|
199
229
|
}, 8, ["isPopupOpen"]),
|
|
200
230
|
createElementVNode("section", {
|
|
201
|
-
id: "screen",
|
|
202
|
-
ref: "screen",
|
|
203
231
|
class: normalizeClass(["flex flex-nowrap h-100 pos-relative o-hidden ease-in-out", {
|
|
204
232
|
"": _ctx.MOBILE_APP === "ios"
|
|
205
|
-
}])
|
|
233
|
+
}]),
|
|
234
|
+
id: "screen",
|
|
235
|
+
ref: "screen"
|
|
206
236
|
}, [
|
|
207
|
-
createVNode(_sfc_main$
|
|
237
|
+
createVNode(_sfc_main$5, {
|
|
208
238
|
class: normalizeClass({
|
|
209
239
|
"mobile:pd-t-extra": _ctx.MOBILE_APP === "ios"
|
|
210
240
|
})
|
|
@@ -215,7 +245,7 @@ const _sfc_main = {
|
|
|
215
245
|
widthHidden: unref(route).meta?.sidebar_width_hidden,
|
|
216
246
|
width: unref(route).meta?.sidebar_width,
|
|
217
247
|
theme: headerTheme.value,
|
|
218
|
-
onCloseSidebar: _cache[
|
|
248
|
+
onCloseSidebar: _cache[2] || (_cache[2] = () => unref(store).core.state.isOpenSidebar = false)
|
|
219
249
|
}, {
|
|
220
250
|
header: withCtx(() => [
|
|
221
251
|
unref(route).meta?.sidebar_header_component ? (openBlock(), createBlock(resolveDynamicComponent(unref(route).meta.sidebar_header_component), {
|
|
@@ -249,34 +279,20 @@ const _sfc_main = {
|
|
|
249
279
|
}, 40, ["stateSidebar", "widthHidden", "width", "theme"])) : createCommentVNode("", true),
|
|
250
280
|
createElementVNode("div", _hoisted_2, [
|
|
251
281
|
createElementVNode("div", {
|
|
282
|
+
class: "o-y-scroll o-x-hidden h-100",
|
|
252
283
|
id: "scrollview",
|
|
253
284
|
ref_key: "scrollview",
|
|
254
285
|
ref: scrollview,
|
|
255
|
-
onScroll: handleScroll
|
|
256
|
-
class: "o-y-scroll o-x-hidden h-100"
|
|
286
|
+
onScroll: handleScroll
|
|
257
287
|
}, [
|
|
258
|
-
unref(store).core.state.error.show ? (openBlock(), createBlock(_sfc_main$4, {
|
|
259
|
-
key: 0,
|
|
260
|
-
data: unref(store).core.state.error,
|
|
261
|
-
onClose: _cache[1] || (_cache[1] = ($event) => unref(store).core.state.error.show = false),
|
|
262
|
-
class: "z-index-7"
|
|
263
|
-
}, null, 8, ["data"])) : createCommentVNode("", true),
|
|
264
|
-
unref(store).core.state.snack.show ? (openBlock(), createBlock(_sfc_main$5, {
|
|
265
|
-
key: 1,
|
|
266
|
-
type: unref(store).core.state.snack.type,
|
|
267
|
-
message: unref(store).core.state.snack.message,
|
|
268
|
-
show: unref(store).core.state.snack.show,
|
|
269
|
-
onClose: _cache[2] || (_cache[2] = ($event) => unref(store).core.state.snack.show = false),
|
|
270
|
-
class: "z-index-7"
|
|
271
|
-
}, null, 8, ["type", "message", "show"])) : createCommentVNode("", true),
|
|
272
288
|
createElementVNode("div", _hoisted_3, [
|
|
273
289
|
(openBlock(), createBlock(Suspense, { onResolve: onSuspenseResolved }, {
|
|
274
290
|
default: withCtx(() => [
|
|
275
291
|
createVNode(_component_router_view, {
|
|
276
|
-
|
|
277
|
-
class: normalizeClass([{
|
|
292
|
+
class: normalizeClass(["h-min-100 pos-relative w-100", {
|
|
278
293
|
"scroll-hide": _ctx.MOBILE_APP
|
|
279
|
-
}
|
|
294
|
+
}]),
|
|
295
|
+
id: "view"
|
|
280
296
|
}, {
|
|
281
297
|
default: withCtx(({ Component, route: route2 }) => [
|
|
282
298
|
createVNode(Transition, {
|
|
@@ -286,14 +302,25 @@ const _sfc_main = {
|
|
|
286
302
|
appear: ""
|
|
287
303
|
}, {
|
|
288
304
|
default: withCtx(() => [
|
|
289
|
-
(openBlock(),
|
|
290
|
-
ref_key: "page",
|
|
291
|
-
ref: page,
|
|
305
|
+
(openBlock(), createElementBlock("div", {
|
|
292
306
|
class: "w-100 h-min-100",
|
|
293
|
-
onPageLoading: handlePageLoading,
|
|
294
|
-
onPageLoaded: handlePageLoaded,
|
|
295
307
|
key: componentKey.value
|
|
296
|
-
},
|
|
308
|
+
}, [
|
|
309
|
+
(openBlock(), createBlock(resolveDynamicComponent(Component), {
|
|
310
|
+
class: "w-100 h-min-100",
|
|
311
|
+
ref_key: "page",
|
|
312
|
+
ref: page,
|
|
313
|
+
onPageLoading: handlePageLoading,
|
|
314
|
+
onPageLoaded: handlePageLoaded
|
|
315
|
+
}, null, 544)),
|
|
316
|
+
!_ctx.MOBILE_APP && route2.meta.footer && !route2.meta.hideFooter ? (openBlock(), createBlock(resolveDynamicComponent(route2.meta.footer), {
|
|
317
|
+
key: 0,
|
|
318
|
+
ref: "footer",
|
|
319
|
+
theme: route2.meta.footer_theme || "light",
|
|
320
|
+
logotype: route2.meta.logotype,
|
|
321
|
+
location: route2.meta.location
|
|
322
|
+
}, null, 8, ["theme", "logotype", "location"])) : createCommentVNode("", true)
|
|
323
|
+
]))
|
|
297
324
|
]),
|
|
298
325
|
_: 2
|
|
299
326
|
}, 1024)
|
|
@@ -304,27 +331,10 @@ const _sfc_main = {
|
|
|
304
331
|
_: 1
|
|
305
332
|
}))
|
|
306
333
|
]),
|
|
307
|
-
createVNode(Transition, {
|
|
308
|
-
onBeforeEnter: scrollTop,
|
|
309
|
-
name: "scaleTransition",
|
|
310
|
-
mode: "out-in",
|
|
311
|
-
appear: ""
|
|
312
|
-
}, {
|
|
313
|
-
default: withCtx(() => [
|
|
314
|
-
!_ctx.MOBILE_APP && unref(route).meta.footer && !unref(route).meta.hideFooter && page.value && !unref(store).core.state.loading ? (openBlock(), createBlock(resolveDynamicComponent(unref(route).meta.footer), {
|
|
315
|
-
key: 0,
|
|
316
|
-
ref: "footer",
|
|
317
|
-
theme: unref(route).meta.footer_theme || "light",
|
|
318
|
-
logotype: unref(route).meta.logotype,
|
|
319
|
-
location: unref(route).meta.location
|
|
320
|
-
}, null, 8, ["theme", "logotype", "location"])) : createCommentVNode("", true)
|
|
321
|
-
]),
|
|
322
|
-
_: 1
|
|
323
|
-
}),
|
|
324
334
|
unref(route).meta.player ? (openBlock(), createBlock(resolveDynamicComponent(unref(route).meta.player), {
|
|
325
|
-
key:
|
|
326
|
-
|
|
327
|
-
|
|
335
|
+
key: 0,
|
|
336
|
+
class: "z-index-2",
|
|
337
|
+
id: "player-wrapper"
|
|
328
338
|
})) : createCommentVNode("", true)
|
|
329
339
|
], 544)
|
|
330
340
|
])
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Client.vue.js","sources":["../../../../../../../../src/modules/core/views/components/layouts/Client.vue"],"sourcesContent":["<template>\n\t<div \n\t\tid=\"app-wrapper\"\n\t\tclass=\"flex flex-column h-100 w-100 pos-relative o-hidden\"\n\t\t:class=\"{\n\t\t\t[(route.name \n ? route.name.replace(/\\s+/g, '_') \n : route.path.replace(/\\W+/g, '_')\n ).toLowerCase()]: true,\n \t\t'pd-t-big': MOBILE_APP === 'ios', \n\t\t\t'bg-white': headerTheme === 'light',\n\t\t\t'bg-black': headerTheme === 'dark',\n \t}\"\n\t>\n\t\t<transition name=\"moveFromTop\" appear>\n\t\t\t<Loader v-if=\"!page || store.core.state.loading\" :centered=\"true\" class=\"pos-fixed\"/>\n\t\t</transition>\n\n\t <transition \n\t name=\"moveFromTop\" \n\t mode=\"out-in\"\n\t >\n\t <section \n\t v-if=\"FirstUse && route.meta.walkthrough\"\n\t class=\"w-100 h-100\" \n\t >\n\t <component \n\t :is=\"route.meta.walkthrough\"\n\t name=\"Walkthrough\"\n\t @updateFirstUse=\"updateFirstUse\" \n\t :slides=\"[1,2,3]\" \n\t class=\"tab\"\n\t >\n\t </component>\n\t </section>\n\t </transition>\n\n <component\n\t\t\tv-if=\"!MOBILE_APP && route.meta.header\"\n ref=\"header\" \n :is=\"route.meta.header\"\n :theme=\"headerTheme\"\n :logotype=\"route.meta.logotype\"\n :location=\"route.meta.location\"\n :class=\"{\n \t'header-scrolled': scrollOffset > 50 \n }\"\n >\n \t<component\n\t\t v-if=\"route.meta?.header_navigation\"\n\t\t :is=\"route.meta.header_navigation\"\n\t\t :horizontal=\"true\"\n\t\t\t\t:navigationItems=\"route.meta.header_navigation_items\"\n\t\t\t\t:stateSidebar=\"store.core.state.isOpenSidebar\"\n\t\t\t\t:theme=\"headerTheme\"\n\t\t />\n \t</component>\n\n\t\t<transition name=\"moveFromTop\" mode=\"out-in\" appear>\n\t\t\t<component\n \tv-if=\"MOBILE_APP && !route.meta.hideNavigationBar\"\n :is=\"route.meta.navigationbar\"\n :logotype=\"route.meta.logotype\"\n :navigationItems=\"route.meta.sidebar_navigation_items\"\n\t :stateSidebar=\"store.core.state.isOpenSidebar\"\n />\n\t\t</transition>\n\n\t <Popup\n\t \t@close-popup=\"closeLocationPopup\"\n\t \t:isPopupOpen=\"store.core.state.isOpenLocationPopup\"\n\t \tclass=\"bg-white pd-semi w-m-33r radius-big\"\n\t >\n\t \t<LocationSelection />\n\t </Popup>\n\n\t <!-- class=\"flex flex-nowrap ease-in-out o-hidden pos-relative\" -->\n\t\t<section \n\t\t\tid=\"screen\" \n\t\t\tref=\"screen\"\n\t\t\tclass=\"flex flex-nowrap h-100 pos-relative o-hidden ease-in-out\"\n\t\t\t:class=\"{\n\t\t\t\t'': MOBILE_APP === 'ios',\n }\"\n\t\t>\n\t\t\t<ShopCart \n\t\t\t\t:class=\"{\n\t\t\t\t\t'mobile:pd-t-extra': MOBILE_APP === 'ios', \n\t\t\t\t}\"\n\t\t\t/>\n\t <component\n\t v-if=\"route.meta?.sidebar\"\n\t :is=\"route.meta.sidebar\"\n\t :stateSidebar=\"store.core.state.isOpenSidebar\"\n\t :widthHidden='route.meta?.sidebar_width_hidden'\n\t :width=\"route.meta?.sidebar_width\"\n\t :theme=\"headerTheme\"\n\t @closeSidebar=\"() => store.core.state.isOpenSidebar = false\"\n\t >\n\t \t<!-- Header slot -->\n\t \t<template #header>\n\t \t\t<component\n\t \t\t\tv-if=\"route.meta?.sidebar_header_component\"\n\t \t\t\t:is=\"route.meta.sidebar_header_component\"\n\t \t\t\t:theme=\"headerTheme\"\n\t \t\t/>\n\t \t</template>\n\n\t \t<!-- Navigation (default slot) -->\n\t \t<transition name=\"moveFromTop\" mode=\"out-in\">\n\t\t <component\n\t\t v-if=\"route.meta?.sidebar_navigation\"\n\t\t :is=\"route.meta.sidebar_navigation\"\n\t\t :key=\"route.meta.sidebar_navigation\"\n\t\t :navigationItems=\"route.meta.sidebar_navigation_items\"\n\t\t\t :stateSidebar=\"store.core.state.isOpenSidebar\"\n\t\t\t\t\t\t:theme=\"headerTheme\"\n\t\t />\n\t </transition>\n\n\t <!-- Footer slot -->\n\t \t<template #footer>\n\t \t\t<component\n\t \t\t\tv-if=\"route.meta?.sidebar_footer_component\"\n\t \t\t\t:is=\"route.meta.sidebar_footer_component\"\n\t \t\t\t:theme=\"headerTheme\"\n\t \t\t/>\n\t \t</template>\n\t </component>\n\t\t <!-- rows-[minmax(0,1fr)] z-index-1 pos-relative w-100 h-100 -->\n\t\t <div class=\"rows-[minmax(0,1fr)] z-index-1 pos-relative w-100 h-100\">\n\t\t \t<div id=\"scrollview\" ref=\"scrollview\" @scroll=\"handleScroll\" class=\"o-y-scroll o-x-hidden h-100\">\n\t \t\t\t<Status\n\t \t\t\t\tv-if=\"store.core.state.error.show\"\n\t\t\t\t\t\t:data=\"store.core.state.error\"\n\t\t\t\t\t\t@close=\"store.core.state.error.show = false\"\n\t\t\t\t\t\tclass=\"z-index-7\"\n\t\t\t\t\t/>\n\t\t\t\t\t<Snack\n\t \t\t\t\tv-if=\"store.core.state.snack.show\"\n\t\t\t\t\t\t:type=\"store.core.state.snack.type\"\n\t\t\t\t\t\t:message=\"store.core.state.snack.message\"\n\t\t\t\t\t\t:show=\"store.core.state.snack.show\"\n\t\t\t\t\t\t@close=\"store.core.state.snack.show = false\"\n\t\t\t\t\t\tclass=\"z-index-7\"\n\t\t\t\t\t/>\n\t\t\t\t\t<div class=\"h-min-100 pos-relative w-100\">\n\t\t\t\t\t\t<!-- <section v-if=\"!route.meta?.breadcrumbs?.hide\" class=\"pd-thin pd-b-zero\">\n\t\t\t\t\t\t\t<Breadcrumbs \n\t\t\t\t\t\t\t\tv-if=\"!MOBILE_APP\"\n\t\t\t\t\t\t\t\tclass=\"bg-light pd-small radius-small\"\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</section> -->\n\n\t\t\t\t \t\t<Suspense @resolve=\"onSuspenseResolved\">\n\t\t\t\t\t\t\t<router-view \n\t\t\t\t\t\t\t\tid=\"view\"\n\t\t\t\t\t\t\t\tv-slot=\"{ Component, route }\" \n\t\t\t\t\t\t\t\t:class=\"{\n\t\t\t\t\t\t\t\t\t'scroll-hide': MOBILE_APP,\n\t\t\t\t\t\t\t\t}\"\n\t\t\t\t\t\t\t\tclass=\"h-min-100 pos-relative w-100\"\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<transition @before-enter=\"scrollTop\" name=\"scaleTransition\" mode=\"out-in\" appear>\n\t\t\t\t\t \t<component \n\t\t\t\t\t \t\tref=\"page\" \n\t\t\t\t\t \t\t:is=\"Component\" \n\t\t\t\t\t \t\tclass=\"w-100 h-min-100\"\n\t\t\t\t \t\t \t@page-loading=\"handlePageLoading\"\n\t\t\t @page-loaded=\"handlePageLoaded\"\n\t\t\t :key=\"componentKey\"\n\t\t\t\t\t \t/>\n\t\t\t\t\t \t<!-- Key пока выключил непонятно какие проблемы это вызовет -->\n\t\t\t\t\t \t<!-- :key=\"route.path\" -->\n\t\t\t\t\t </transition>\n\t\t\t\t\t\t </router-view>\n\t\t\t\t\t\t</Suspense>\n\t\t\t\t </div>\n\t\t\t \n\t\t\t \t<transition @before-enter=\"scrollTop\" name=\"scaleTransition\" mode=\"out-in\" appear>\n\t\t <component\n\t\t\t\t\t\t\tv-if=\"!MOBILE_APP && route.meta.footer && !route.meta.hideFooter && page && !store.core.state.loading\"\n\t\t\t\t ref=\"footer\"\n\t\t\t\t :is=\"route.meta.footer\"\n\t\t\t\t :theme=\"route.meta.footer_theme || 'light'\"\n\t\t\t\t :logotype=\"route.meta.logotype\"\n\t\t\t\t :location=\"route.meta.location\"\n\t\t\t\t />\n\t\t\t \t</transition>\n\n\t\t\t\t\t<component\n\t\t\t v-if=\"route.meta.player\"\n\t\t\t id=\"player-wrapper\"\n\t\t\t class=\"z-index-2 \"\n\t\t\t \t:is=\"route.meta.player\"\n\t\t\t />\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</section>\n\n\n\t\t<router-view \n\t\t\tname=\"defaultBottom\"\n\t\t\tv-slot=\"{ Component, route }\" \n\t\t>\n\t\t\t<component \n \t\t:is=\"Component\" \n \t/>\n\t\t</router-view>\n\n <component \n v-if=\"MOBILE_APP && route.meta.title_hide\"\n class=\"z-index-2\"\n \t:is=\"route.meta.bottombar\"\n />\n\n\n\t</div>\n</template>\n\n\n\n<script setup>\n\timport { computed, ref, onMounted } from 'vue';\n\t// Router\n\timport { useRoute } from 'vue-router';\n\t// Store\n\timport { useStore } from '@martyrs/src/modules/core/views/store/core.store.js';\n\timport { useGlobalMixins } from '@martyrs/src/modules/core/views/mixins/mixins.js';\n\t// Partials\n\timport Status from '@martyrs/src/components/Status/Status.vue';\n\timport Snack from '@martyrs/src/components/Status/Snack.vue';\n\timport Popup from '@martyrs/src/components/Popup/Popup.vue';\n\timport Breadcrumbs from '@martyrs/src/components/Breadcrumbs/Breadcrumbs.vue'\n\timport Loader from '@martyrs/src/components/Loader/Loader.vue';\n\n\timport NavigationBar from '@martyrs/src/modules/core/views/components/partials/NavigationBar.vue';\n\timport LocationSelection from '@martyrs/src/modules/core/views/components/partials/LocationSelection.vue';\n\n\timport ShopCart from '@martyrs/src/modules/orders/components/partials/ShopCart.vue';\n\t// PROPS\n\tconst props = defineProps({\n env: {\n type: Object,\n required: true\n },\n app: {\n type: Object,\n required: true\n },\n modules: {\n type: Object,\n required: true\n }\n })\n\n\tconst store = useStore()\n\n\t/////////////////////////////\n // LOADING\n /////////////////////////////\n // State\n let show = ref(false)\n // Preloader\n const page = ref(null)\n const scrollview = ref(null)\n\n // isPageLoading убран - используем core.state.loading\n \n // Обработчики событий загрузки\n function handlePageLoading() {\n store.core.state.loading = true;\n }\n\n function handlePageLoaded() {\n store.core.state.loading = false;\n }\n\n // Обработка события разрешения Suspense (когда async setup компонента завершается)\n function onSuspenseResolved() {\n // Если страница не отправляет событие page-loaded, этот обработчик\n // может служить запасным вариантом для отключения лоадера\n // Можно оставить закомментированным, если все страницы будут явно вызывать handlePageLoaded\n store.core.state.loading = false;\n }\n\t/////////////////////////////\n\t// CREATED\n\t/////////////////////////////\n\tconst route = useRoute()\n\t// const router = useRouter()\n\n\t// Инициализация sidebar для SSR + первая загрузка\n\tif (route.meta?.sidebarOpenOnEnter === true) {\n\t\tstore.core.state.isOpenSidebar = true\n\t}\n\n\t// Ref Code\n\tconst referalCode = ref(route.query.referalCode);\n\t/////////////////////////////\n\t// Methods\n\t/////////////////////////////\n\tfunction closeLocationPopup() {\n\t store.core.state.isOpenLocationPopup = false;\n\t}\n\tfunction scrollTop(){\n\t\tif (scrollview.value) scrollview.value.scrollTop = 0;\n\t}\n\t// Scrolling header\n\tconst scrollOffset = ref(0)\n\tlet isScrolled = false\n\tconst header = ref(null)\n\n\tconst headerTheme = computed(() => {\n\t\tif (scrollOffset.value > 50) {\n\t\t\treturn route.meta.header_theme || 'light'\n\t\t} else {\n\t\t\treturn route.meta.header_theme || 'light'\n\t\t}\n\t})\n\n\tconst handleScroll = () => {\n\t scrollOffset.value = event.target.scrollTop\n\t};\n/////////////////////////////\n // FIRST USE\n /////////////////////////////\n const FirstUse = ref(false);\n\n import { Preferences } from '@capacitor/preferences';\n\n async function getFirstUse() {\n const ret = await Preferences.get({ key: 'first-use' });\n FirstUse.value = ret.value ? JSON.parse(ret.value) : true;\n }\n\n const updateFirstUse = (value) => {\n FirstUse.value = value;\n }\n\n\tconst { isPhone, isTablet } = useGlobalMixins();\n\n\tonMounted(async () => {\n\t await getFirstUse()\n\n\t\t// Закрываем sidebar на mobile (CSS уже скрыл визуально)\n\t\tif ((isPhone() || isTablet()) && store.core.state.isOpenSidebar) {\n\t\t\tstore.core.state.isOpenSidebar = false\n\t\t}\n\n\t\t// Регистрация единого Service Worker (PWA + push notifications)\n\t\tif ('serviceWorker' in navigator && !window.__MOBILE_APP__) {\n\t \twindow.addEventListener('load', () => {\n\t \tnavigator.serviceWorker.register('/sw.js').then(registration => {\n\t \tconsole.log('Unified SW registered: ', registration);\n\t \t}).catch(registrationError => {\n\t \tconsole.log('SW registration failed: ', registrationError);\n\t \t});\n\t });\n\t \t}\n\n\t\tif (!store.core.state.position && route.meta.location) {\n store.core.state.isOpenLocationPopup = true;\n } else {\n store.core.state.isOpenLocationPopup = false;\n }\n\n\t\tif (referalCode.value) {\n\t\t localStorage.setItem('referalCode', referalCode.value);\n\t\t}\n\n\t\tif (page.value) show.value = true\n\t});\n\n\tconst componentKey = computed(() => {\n\t // Собираем только значимые параметры (ID сущностей)\n\t const significantParams = ['_id', 'product', 'organization', 'categoryPath', 'country', 'state', 'city']\n\t .map(param => route.params[param])\n\t .filter(Boolean)\n\t .join('-');\n\n\t return significantParams || route.name;\n\t});\n</script>\n\n<style lang=\"scss\">\n\t.fade-enter-active, .fade-leave-active {\n\t transition: opacity .5s;\n\t}\n\t.fade-enter, .fade-leave-to /* .fade-leave-active в версии 2.1.8+ */ {\n\t opacity: 0;\n\t}\n\n\t\n .fade-move,\n .fade-enter-active,\n .fade-leave-active {\n transition: all 0.5s cubic-bezier(0.55, 0, 0.1, 1);\n }\n\n /* 2. declare enter from and leave to state */\n .fade-enter-from,\n .fade-leave-to {\n opacity: 0;\n transform: translate(30px, 0);\n }\n\n /* 3. ensure leaving items are taken out of layout flow so that moving\n animations can be calculated correctly. */\n .fade-leave-active {\n position: absolute;\n }\n\n.moveFromTop-enter-active,\n.moveFromTop-leave-active {\n transition: all 0.3s ease, max-height 0.2s ease;\n overflow: hidden;\n}\n\n.moveFromTop-enter-from,\n.moveFromTop-leave-to {\n transform: translateY(-1rem);\n opacity: 0;\n // max-height: 0;\n}\n\n.moveFromTop-enter-to,\n.moveFromTop-leave-from {\n // max-height: 100vh; \n}\n\n\t.moveFromTopAbsolute-enter-active,\n\t.moveFromTopAbsolute-leave-active {\n\t\ttransform: translateY(0);\n\t\topacity: 1;\n\t\ttransition: all 0.5s ease; \n\t\t\n\t}\n\t.moveFromTopAbsolute-enter-from,\n\t.moveFromTopAbsolute-leave-to {\n\t\tposition: absolute;\n\t\ttransform: translateY(-1rem);\n\t\topacity: 0;\n\t\ttransition: all 0.5s ease;\n\t}\n\t.ScaleOut-enter-active,\n\t.ScaleOut-leave-active {\n\t\topacity: 1;\n\t\ttransform: scale(1);\n\t\ttransition: all 0.3s ease; \n\t\t\n\t}\n\t.ScaleOut-enter-from,\n\t.ScaleOut-leave-to {\n\t\topacity: 0;\n\t\ttransform: scale(0.9);\n\t\ttransition: all 0.3s ease;\n\t}\n\t.slide-fade-enter-active {\n\t\t// min-height: 100vh;\n\t transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);\n\t}\n\n\t.slide-fade-leave-active {\n\t\t// min-height: 100vh;\n\t transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);\n\t}\n\n\t.slide-fade-enter-from,\n\t.slide-fade-leave-to {\n\t\tmin-height: 0;\n\t transform: translateX(20px);\n\t opacity: 0;\n\t left: 0;\n\t top: 0;\n\t}\n\n\t.scaleTransition-5px-enter-active,\n .scaleTransition-5px-leave-active {\n transform: translateY(0px); \n opacity: 1;\n z-index: 1;\n transition: all 0.2s ease;\n }\n\n .scaleTransition-5px-enter-from,\n .scaleTransition-5px-leave-to {\n opacity: 0;\n z-index: 0;\n position: absolute;\n transform: translateY(-30px); \n transition: all 0.2s ease;\n }\n\n .scaleTransition-enter-from,\n .scaleTransition-leave-to {\n opacity: 0;\n z-index: 0;\n position: absolute;\n width: inherit;\n height: inherit;\n display: block;\n transform: translateY(30px); \n transition: all 0.5s ease;\n }\n\n .scaleTransition-enter-active,\n .scaleTransition-leave-active {\n transform: translateY(0px); \n opacity: 1;\n z-index: 1;\n transition: all 0.5s ease;\n }\n .scaleTransition-enter-from,\n .scaleTransition-leave-to {\n opacity: 0;\n z-index: 0;\n position: absolute;\n width: inherit;\n height: inherit;\n display: block;\n transform: translateY(30px); \n transition: all 0.5s ease;\n }\n\n .scaleIn-enter-active,\n .scaleIn-leave-active {\n // background: red;\n transition: all 0.5s ease;\n > section,div { transform-origin: 0 0; transform: translateZ(0px); transition: all 0.5s ease; }\n }\n .scaleIn-enter-from,\n .scaleIn-leave-to {\n opacity: 0;\n transform: scale(0.95);\n > section,div { transform: translateZ(-30px); transition: all 0.5s ease; }\n }\n\n\n</style>"],"names":[],"mappings":"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"}
|
|
1
|
+
{"version":3,"file":"Client.vue.js","sources":["../../../../../../../../src/modules/core/views/components/layouts/Client.vue"],"sourcesContent":["<template>\n <div\n class=\"flex flex-column h-100 w-100 pos-relative o-hidden\"\n id=\"app-wrapper\"\n :class=\"{\n [(route.name ? route.name.replace(/\\s+/g, '_') : route.path.replace(/\\W+/g, '_')).toLowerCase()]: true,\n 'pd-t-big': MOBILE_APP === 'ios',\n 'bg-white': headerTheme === 'light',\n 'bg-black': headerTheme === 'dark',\n }\"\n >\n <transition name=\"moveFromTop\" appear>\n <Loader class=\"pos-fixed z-index-10\" v-if=\"!page || store.core.state.loading\" :centered=\"true\" />\n </transition>\n\n <transition name=\"moveFromTop\" mode=\"out-in\">\n <section class=\"w-100 h-100\" v-if=\"FirstUse && route.meta.walkthrough\">\n <component class=\"tab\" :is=\"route.meta.walkthrough\" name=\"Walkthrough\" @updateFirstUse=\"updateFirstUse\" :slides=\"[1, 2, 3]\"> </component>\n </section>\n </transition>\n <transition name=\"moveFromTop\" mode=\"out-in\">\n <Status class=\"z-index-10\" v-if=\"store.core.state.error.show\" :data=\"store.core.state.error\" @close=\"store.core.state.error.show = false\" />\n </transition>\n\n <transition name=\"moveFromTop\" mode=\"out-in\">\n <Snack\n class=\"z-index-10\"\n v-if=\"store.core.state.snack.show\"\n :type=\"store.core.state.snack.type\"\n :message=\"store.core.state.snack.message\"\n :show=\"store.core.state.snack.show\"\n @close=\"store.core.state.snack.show = false\"\n />\n </transition>\n\n <component\n v-if=\"!MOBILE_APP && route.meta.header\"\n ref=\"header\"\n :is=\"route.meta.header\"\n :theme=\"headerTheme\"\n :logotype=\"route.meta.logotype\"\n :location=\"route.meta.location\"\n :class=\"{\n 'header-scrolled': scrollOffset > 50,\n }\"\n >\n <component\n v-if=\"route.meta?.header_navigation\"\n :is=\"route.meta.header_navigation\"\n :horizontal=\"true\"\n :navigationItems=\"route.meta.header_navigation_items\"\n :stateSidebar=\"store.core.state.isOpenSidebar\"\n :theme=\"headerTheme\"\n />\n </component>\n\n <transition name=\"moveFromTop\" mode=\"out-in\" appear>\n <component\n v-if=\"MOBILE_APP && !route.meta.hideNavigationBar\"\n :is=\"route.meta.navigationbar\"\n :logotype=\"route.meta.logotype\"\n :navigationItems=\"route.meta.sidebar_navigation_items\"\n :stateSidebar=\"store.core.state.isOpenSidebar\"\n />\n </transition>\n\n <Popup class=\"bg-white pd-semi w-m-33r radius-big\" @close-popup=\"closeLocationPopup\" :isPopupOpen=\"store.core.state.isOpenLocationPopup\">\n <LocationSelection />\n </Popup>\n\n <!-- class=\"flex flex-nowrap ease-in-out o-hidden pos-relative\" -->\n <section\n class=\"flex flex-nowrap h-100 pos-relative o-hidden ease-in-out\"\n id=\"screen\"\n ref=\"screen\"\n :class=\"{\n '': MOBILE_APP === 'ios',\n }\"\n >\n <ShopCart\n :class=\"{\n 'mobile:pd-t-extra': MOBILE_APP === 'ios',\n }\"\n />\n <component\n v-if=\"route.meta?.sidebar\"\n :is=\"route.meta.sidebar\"\n :stateSidebar=\"store.core.state.isOpenSidebar\"\n :widthHidden=\"route.meta?.sidebar_width_hidden\"\n :width=\"route.meta?.sidebar_width\"\n :theme=\"headerTheme\"\n @closeSidebar=\"() => (store.core.state.isOpenSidebar = false)\"\n >\n <!-- Header slot -->\n <template #header>\n <component v-if=\"route.meta?.sidebar_header_component\" :is=\"route.meta.sidebar_header_component\" :theme=\"headerTheme\" />\n </template>\n\n <!-- Navigation (default slot) -->\n <transition name=\"moveFromTop\" mode=\"out-in\">\n <component\n v-if=\"route.meta?.sidebar_navigation\"\n :is=\"route.meta.sidebar_navigation\"\n :key=\"route.meta.sidebar_navigation\"\n :navigationItems=\"route.meta.sidebar_navigation_items\"\n :stateSidebar=\"store.core.state.isOpenSidebar\"\n :theme=\"headerTheme\"\n />\n </transition>\n\n <!-- Footer slot -->\n <template #footer>\n <component v-if=\"route.meta?.sidebar_footer_component\" :is=\"route.meta.sidebar_footer_component\" :theme=\"headerTheme\" />\n </template>\n </component>\n\t \n <div class=\"rows-[minmax(0,1fr)] z-index-1 pos-relative w-100 h-100\">\n <div class=\"o-y-scroll o-x-hidden h-100\" id=\"scrollview\" ref=\"scrollview\" @scroll=\"handleScroll\">\n <div class=\"h-min-100 pos-relative w-100\">\n <!-- <section v-if=\"!route.meta?.breadcrumbs?.hide\" class=\"pd-thin pd-b-zero\">\n\t\t\t\t<Breadcrumbs \n\t\t\t\t\tv-if=\"!MOBILE_APP\"\n\t\t\t\t\tclass=\"bg-light pd-small radius-small\"\n\t\t\t\t/>\n\t\t\t</section> -->\n\n <Suspense @resolve=\"onSuspenseResolved\">\n <router-view\n class=\"h-min-100 pos-relative w-100\"\n id=\"view\"\n v-slot=\"{ Component, route }\"\n :class=\"{\n 'scroll-hide': MOBILE_APP,\n }\"\n >\n <transition @before-enter=\"scrollTop\" name=\"scaleTransition\" mode=\"out-in\" appear>\n <div class=\"w-100 h-min-100\" :key=\"componentKey\">\n <component class=\"w-100 h-min-100\" ref=\"page\" :is=\"Component\" @page-loading=\"handlePageLoading\" @page-loaded=\"handlePageLoaded\" />\n <component\n v-if=\"!MOBILE_APP && route.meta.footer && !route.meta.hideFooter\"\n ref=\"footer\"\n :is=\"route.meta.footer\"\n :theme=\"route.meta.footer_theme || 'light'\"\n :logotype=\"route.meta.logotype\"\n :location=\"route.meta.location\"\n />\n </div>\n </transition>\n </router-view>\n </Suspense>\n </div>\n\n <component class=\"z-index-2\" id=\"player-wrapper\" v-if=\"route.meta.player\" :is=\"route.meta.player\" />\n </div>\n </div>\n </section>\n\n <router-view v-slot=\"{ Component, route }\" name=\"defaultBottom\">\n <component :is=\"Component\" />\n </router-view>\n\n <component class=\"z-index-2\" v-if=\"MOBILE_APP && route.meta.title_hide\" :is=\"route.meta.bottombar\" />\n </div>\n</template>\n\n<script setup>\nimport { computed, ref, onMounted } from 'vue';\n// Router\nimport { useRoute } from 'vue-router';\n// Store\nimport { useStore } from '@martyrs/src/modules/core/views/store/core.store.js';\nimport { useGlobalMixins } from '@martyrs/src/modules/core/views/mixins/mixins.js';\n// Partials\nimport Status from '@martyrs/src/components/Status/Status.vue';\nimport Snack from '@martyrs/src/components/Status/Snack.vue';\nimport Popup from '@martyrs/src/components/Popup/Popup.vue';\nimport Breadcrumbs from '@martyrs/src/components/Breadcrumbs/Breadcrumbs.vue';\nimport Loader from '@martyrs/src/components/Loader/Loader.vue';\n\nimport NavigationBar from '@martyrs/src/modules/core/views/components/partials/NavigationBar.vue';\nimport LocationSelection from '@martyrs/src/modules/core/views/components/partials/LocationSelection.vue';\n\nimport ShopCart from '@martyrs/src/modules/orders/components/partials/ShopCart.vue';\n// PROPS\nconst props = defineProps({\n env: {\n type: Object,\n required: true,\n },\n app: {\n type: Object,\n required: true,\n },\n modules: {\n type: Object,\n required: true,\n },\n});\n\nconst store = useStore();\n\n/////////////////////////////\n// LOADING\n/////////////////////////////\n// State\nlet show = ref(false);\n// Preloader\nconst page = ref(null);\nconst scrollview = ref(null);\n\n// isPageLoading убран - используем core.state.loading\n\n// Обработчики событий загрузки\nfunction handlePageLoading() {\n store.core.state.loading = true;\n}\n\nfunction handlePageLoaded() {\n store.core.state.loading = false;\n}\n\n// Обработка события разрешения Suspense (когда async setup компонента завершается)\nfunction onSuspenseResolved() {\n // Если страница не отправляет событие page-loaded, этот обработчик\n // может служить запасным вариантом для отключения лоадера\n // Можно оставить закомментированным, если все страницы будут явно вызывать handlePageLoaded\n store.core.state.loading = false;\n}\n/////////////////////////////\n// CREATED\n/////////////////////////////\nconst route = useRoute();\n// const router = useRouter()\n\n// Инициализация sidebar для SSR + первая загрузка\nif (route.meta?.sidebarOpenOnEnter === true) {\n store.core.state.isOpenSidebar = true;\n}\n\n// Ref Code\nconst referalCode = ref(route.query.referalCode);\n/////////////////////////////\n// Methods\n/////////////////////////////\nfunction closeLocationPopup() {\n store.core.state.isOpenLocationPopup = false;\n}\nfunction scrollTop() {\n if (scrollview.value) scrollview.value.scrollTop = 0;\n}\n// Scrolling header\nconst scrollOffset = ref(0);\nlet isScrolled = false;\nconst header = ref(null);\n\nconst headerTheme = computed(() => {\n if (scrollOffset.value > 50) {\n return route.meta.header_theme || 'light';\n } else {\n return route.meta.header_theme || 'light';\n }\n});\n\nconst handleScroll = () => {\n scrollOffset.value = event.target.scrollTop;\n};\n/////////////////////////////\n// FIRST USE\n/////////////////////////////\nconst FirstUse = ref(false);\n\nimport { Preferences } from '@capacitor/preferences';\n\nasync function getFirstUse() {\n const ret = await Preferences.get({ key: 'first-use' });\n FirstUse.value = ret.value ? JSON.parse(ret.value) : true;\n}\n\nconst updateFirstUse = value => {\n FirstUse.value = value;\n};\n\nconst { isPhone, isTablet } = useGlobalMixins();\n\nonMounted(async () => {\n await getFirstUse();\n\n // Закрываем sidebar на mobile (CSS уже скрыл визуально)\n if ((isPhone() || isTablet()) && store.core.state.isOpenSidebar) {\n store.core.state.isOpenSidebar = false;\n }\n\n // Регистрация единого Service Worker (PWA + push notifications)\n if ('serviceWorker' in navigator && !window.__MOBILE_APP__) {\n window.addEventListener('load', () => {\n navigator.serviceWorker\n .register('/sw.js')\n .then(registration => {\n console.log('Unified SW registered: ', registration);\n })\n .catch(registrationError => {\n console.log('SW registration failed: ', registrationError);\n });\n });\n }\n\n if (!store.core.state.position && route.meta.location) {\n store.core.state.isOpenLocationPopup = true;\n } else {\n store.core.state.isOpenLocationPopup = false;\n }\n\n if (referalCode.value) {\n localStorage.setItem('referalCode', referalCode.value);\n }\n\n if (page.value) show.value = true;\n});\n\nconst componentKey = computed(() => {\n // Собираем только значимые параметры (ID сущностей)\n const significantParams = ['_id', 'product', 'organization', 'categoryPath', 'country', 'state', 'city']\n .map(param => route.params[param])\n .filter(Boolean)\n .join('-');\n\n return significantParams || route.meta.layoutKey || route.name;\n});\n</script>\n\n<style lang=\"scss\">\n.fade-enter-active,\n.fade-leave-active {\n transition: opacity 0.5s;\n}\n\n.fade-enter,\n.fade-leave-to\n\n/* .fade-leave-active в версии 2.1.8+ */ {\n opacity: 0;\n}\n\n.fade-move,\n.fade-enter-active,\n.fade-leave-active {\n transition: all 0.5s cubic-bezier(0.55, 0, 0.1, 1);\n}\n\n/* 2. declare enter from and leave to state */\n.fade-enter-from,\n.fade-leave-to {\n opacity: 0;\n transform: translate(30px, 0);\n}\n\n/* 3. ensure leaving items are taken out of layout flow so that moving\n animations can be calculated correctly. */\n.fade-leave-active {\n position: absolute;\n}\n\n.moveFromTop-enter-active,\n.moveFromTop-leave-active {\n transition:\n all 0.3s ease,\n max-height 0.2s ease;\n overflow: hidden;\n}\n\n.moveFromTop-enter-from,\n.moveFromTop-leave-to {\n transform: translateY(-1rem);\n opacity: 0;\n // max-height: 0;\n}\n\n.moveFromTop-enter-to,\n.moveFromTop-leave-from {\n // max-height: 100vh;\n}\n\n.moveFromTopAbsolute-enter-active,\n.moveFromTopAbsolute-leave-active {\n transform: translateY(0);\n opacity: 1;\n transition: all 0.5s ease;\n}\n\n.moveFromTopAbsolute-enter-from,\n.moveFromTopAbsolute-leave-to {\n position: absolute;\n transform: translateY(-1rem);\n opacity: 0;\n transition: all 0.5s ease;\n}\n\n.ScaleOut-enter-active,\n.ScaleOut-leave-active {\n opacity: 1;\n transform: scale(1);\n transition: all 0.3s ease;\n}\n\n.ScaleOut-enter-from,\n.ScaleOut-leave-to {\n opacity: 0;\n transform: scale(0.9);\n transition: all 0.3s ease;\n}\n\n.slide-fade-enter-active {\n // min-height: 100vh;\n transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);\n}\n\n.slide-fade-leave-active {\n // min-height: 100vh;\n transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);\n}\n\n.slide-fade-enter-from,\n.slide-fade-leave-to {\n min-height: 0;\n transform: translateX(20px);\n opacity: 0;\n left: 0;\n top: 0;\n}\n\n.scaleTransition-5px-enter-active,\n.scaleTransition-5px-leave-active {\n transform: translateY(0px);\n opacity: 1;\n z-index: 1;\n transition: all 0.2s ease;\n}\n\n.scaleTransition-5px-enter-from,\n.scaleTransition-5px-leave-to {\n opacity: 0;\n z-index: 0;\n position: absolute;\n transform: translateY(-30px);\n transition: all 0.2s ease;\n}\n\n.scaleTransition-enter-from,\n.scaleTransition-leave-to {\n opacity: 0;\n z-index: 0;\n position: absolute;\n width: inherit;\n height: inherit;\n display: block;\n transform: translateY(30px);\n transition: all 0.5s ease;\n}\n\n.scaleTransition-enter-active,\n.scaleTransition-leave-active {\n transform: translateY(0px);\n opacity: 1;\n z-index: 1;\n transition: all 0.5s ease;\n}\n\n.scaleTransition-enter-from,\n.scaleTransition-leave-to {\n opacity: 0;\n z-index: 0;\n position: absolute;\n width: inherit;\n height: inherit;\n display: block;\n transform: translateY(30px);\n transition: all 0.5s ease;\n}\n\n.scaleIn-enter-active,\n.scaleIn-leave-active {\n // background: red;\n transition: all 0.5s ease;\n\n > section,\n div {\n transform-origin: 0 0;\n transform: translateZ(0px);\n transition: all 0.5s ease;\n }\n}\n\n.scaleIn-enter-from,\n.scaleIn-leave-to {\n opacity: 0;\n transform: scale(0.95);\n\n > section,\n div {\n transform: translateZ(-30px);\n transition: all 0.5s ease;\n }\n}\n</style>\n"],"names":[],"mappings":"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"}
|