@ozdao/prometheus-framework 0.2.38 → 0.2.40
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/auth.server.js +1 -2
- package/dist/auth.server.mjs +1 -2
- package/dist/files.server.js +1 -2
- package/dist/files.server.mjs +1 -2
- package/dist/globals.server.js +1 -1
- package/dist/globals.server.mjs +1 -1
- package/dist/mailing-10560277.mjs +78 -0
- package/dist/mailing-902d13d5.js +77 -0
- package/dist/main.css +1 -1
- package/dist/prometheus-framework/src/components/Button/Button.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Button/Button.vue.js +225 -2
- package/dist/prometheus-framework/src/components/Button/Button.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/Button/Button.vue2.js +2 -225
- package/dist/prometheus-framework/src/components/Checkbox/Checkbox.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Checkbox/Checkbox.vue.js +61 -2
- package/dist/prometheus-framework/src/components/Checkbox/Checkbox.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/Checkbox/Checkbox.vue2.js +2 -61
- package/dist/prometheus-framework/src/components/Chips/Chips.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Chips/Chips.vue.js +13 -9
- package/dist/prometheus-framework/src/components/Chips/Chips.vue2.cjs +1 -0
- package/dist/prometheus-framework/src/components/Chips/Chips.vue2.js +4 -0
- package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue.js +26 -22
- package/dist/prometheus-framework/src/components/Feed/Feed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Feed/Feed.vue.js +29 -30
- package/dist/prometheus-framework/src/components/Field/Field.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Field/Field.vue.js +76 -2
- package/dist/prometheus-framework/src/components/Field/Field.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/Field/Field.vue2.js +2 -76
- package/dist/prometheus-framework/src/components/Popup/Popup.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Popup/Popup.vue.js +70 -2
- package/dist/prometheus-framework/src/components/Popup/Popup.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/Popup/Popup.vue2.js +2 -70
- package/dist/prometheus-framework/src/components/Select/Select.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Select/Select.vue.js +95 -2
- package/dist/prometheus-framework/src/components/Select/Select.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/Select/Select.vue2.js +2 -95
- package/dist/prometheus-framework/src/components/Slider/Slider.vue.cjs +1 -0
- package/dist/prometheus-framework/src/components/Slider/Slider.vue.js +69 -0
- package/dist/prometheus-framework/src/components/Tab/Tab.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Tab/Tab.vue.js +44 -2
- package/dist/prometheus-framework/src/components/Tab/Tab.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/Tab/Tab.vue2.js +2 -44
- package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.js +10 -7
- package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.js +18 -15
- package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.js +16 -13
- package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.js +23 -20
- package/dist/prometheus-framework/src/modules/auth/localization/SignUp.json.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/localization/SignUp.json.js +1 -1
- package/dist/prometheus-framework/src/modules/auth/store/auth.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/store/auth.js +8 -8
- package/dist/prometheus-framework/src/modules/community/community.client.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/community.client.js +18 -20
- package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.js +88 -62
- package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.js +97 -68
- package/dist/prometheus-framework/src/modules/community/components/pages/BlogPost.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/pages/BlogPost.vue.js +35 -34
- package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.js +18 -18
- package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue2.js +2 -2
- package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.js +5 -5
- package/dist/prometheus-framework/src/modules/community/components/sections/Feed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/sections/Feed.vue.js +4 -4
- package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.js +65 -19
- package/dist/prometheus-framework/src/modules/community/components/sections/JoinUs.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/sections/JoinUs.vue.js +9 -9
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.js +8 -7
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Image.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Image.vue.js +6 -6
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.cjs +5 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.js +65 -2
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.cjs +1 -5
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.js +2 -65
- package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.js +64 -70
- package/dist/prometheus-framework/src/modules/events/components/blocks/CardEvent.vue.js +6 -6
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/layouts/layoutEvents.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/layouts/layoutEvents.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +5 -5
- package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.js +6 -5
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.js +43 -42
- package/dist/prometheus-framework/src/modules/icons/entities/IconFeatured.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/icons/entities/IconFeatured.vue.js +30 -0
- package/dist/prometheus-framework/src/modules/icons/entities/IconFollowing.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/icons/entities/IconFollowing.vue.js +47 -0
- package/dist/prometheus-framework/src/modules/icons/entities/IconPopular.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/icons/entities/IconPopular.vue.js +28 -0
- package/dist/prometheus-framework/src/modules/icons/entities/IconRecent.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/icons/entities/IconRecent.vue.js +45 -0
- package/dist/prometheus-framework/src/modules/icons/navigation/IconArrow.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/icons/navigation/IconArrow.vue.js +32 -0
- package/dist/prometheus-framework/src/modules/icons/navigation/IconChevronRight.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/icons/navigation/IconChevronRight.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/icons/navigation/IconEdit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/icons/navigation/IconEdit.vue.js +25 -14
- package/dist/prometheus-framework/src/modules/icons/navigation/IconEllipsis.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/icons/navigation/IconEllipsis.vue.js +44 -0
- package/dist/prometheus-framework/src/modules/landing/components/sections/MobileApp.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/landing/components/sections/MobileApp.vue.js +90 -67
- package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/orders/components/pages/EditOrder.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/pages/EditOrder.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/pages/Orders.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/pages/Orders.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormOrderDetails.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormOrderDetails.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.js +45 -42
- package/dist/prometheus-framework/src/modules/organizations/components/blocks/DepartmentMemberModify.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/blocks/DepartmentMemberModify.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +6 -6
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.js +5 -5
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organizations.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organizations.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.js +60 -55
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/organizations/components/sections/FeedDepartments.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/FeedDepartments.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersList.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersList.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +18 -17
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Publics.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Publics.vue.js +20 -21
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardLeftover.vue.js +7 -7
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/products/components/blocks/ImagesThumbnails.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/ImagesThumbnails.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/products/components/pages/Leftovers.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Leftovers.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js +6 -6
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductsBackoffice.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductsBackoffice.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/PopularProducts.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/PopularProducts.vue.js +37 -34
- package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.js +23 -23
- package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.js +8 -8
- package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +6 -6
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileBlogposts.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileBlogposts.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEvents.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEvents.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/wallet/components/pages/Wallet.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/wallet/components/pages/Wallet.vue.js +31 -30
- package/dist/prometheus-framework.cjs.js +20 -20
- package/dist/prometheus-framework.es.js +1003 -999
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/components/Button/Button.vue +2 -3
- package/src/components/Chips/Chips.vue +9 -3
- package/src/components/Dropdown/Dropdown.vue +9 -3
- package/src/components/Feed/Feed.vue +7 -11
- package/src/components/Feed/Masonry.vue +177 -0
- package/src/components/FieldBig/FieldBig.vue +3 -3
- package/src/components/LocationSelection/LocationSelection.vue +1 -1
- package/src/components/Navigation/Navigation.vue +2 -0
- package/src/components/Shader/Shader.vue +161 -116
- package/src/components/Slider/Slider.vue +92 -0
- package/src/modules/applications/applications.client.js +2 -0
- package/src/modules/applications/components/sections/SubscribeNewsletter.vue +114 -0
- package/src/modules/applications/controllers/applications.controller.js +125 -136
- package/src/modules/applications/models/application.model.js +22 -7
- package/src/modules/applications/routes/applications.routes.js +29 -13
- package/src/modules/auth/components/pages/EnterCode.vue +4 -1
- package/src/modules/auth/components/pages/EnterPassword.vue +4 -1
- package/src/modules/auth/components/pages/ResetPassword.vue +4 -1
- package/src/modules/auth/components/pages/SignUp.vue +4 -1
- package/src/modules/auth/controllers/auth.controller.js +2 -3
- package/src/modules/auth/localization/SignUp.json +1 -1
- package/src/modules/auth/store/auth.js +3 -5
- package/src/modules/chats/components/blocks/ChatMessage.vue +3 -2
- package/src/modules/chats/components/pages/ChatPage.vue +6 -6
- package/src/modules/chats/components/sections/ChatWindow.vue +57 -12
- package/src/modules/chats/store/chat.store.js +6 -1
- package/src/modules/community/community.client.js +0 -2
- package/src/modules/community/components/blocks/CardBlogpost.vue +71 -33
- package/src/modules/community/components/layouts/Community.vue +63 -24
- package/src/modules/community/components/pages/Blog.vue +37 -0
- package/src/modules/community/components/pages/BlogPost.vue +5 -6
- package/src/modules/community/components/pages/Community.vue +1 -0
- package/src/modules/community/components/sections/Feed.vue +1 -1
- package/src/modules/community/components/sections/HotPosts.vue +64 -24
- package/src/modules/community/components/sections/JoinUs.vue +4 -5
- package/src/modules/community/store/blogposts.js +1 -0
- package/src/modules/constructor/components/elements/Embed.vue +7 -6
- package/src/modules/constructor/components/elements/Image.vue +2 -2
- package/src/modules/constructor/components/elements/Textarea.vue +1 -1
- package/src/modules/constructor/components/sections/Constructor.vue +2 -18
- package/src/modules/files/middlewares/server/middlewareBusboy.js +1 -1
- package/src/modules/files/routes/files.routes.js +9 -1
- package/src/modules/globals/components/blocks/CardHeader.vue +6 -3
- package/src/modules/globals/utils/mailing.js +12 -0
- package/src/modules/icons/entities/IconEarn.vue +20 -0
- package/src/modules/icons/entities/IconFeatured.vue +14 -0
- package/src/modules/icons/entities/IconFollowing.vue +17 -0
- package/src/modules/icons/entities/IconPopular.vue +14 -0
- package/src/modules/icons/entities/IconRecent.vue +17 -0
- package/src/modules/icons/navigation/IconAdd.vue +1 -3
- package/src/modules/icons/navigation/IconArrow.vue +21 -0
- package/src/modules/icons/navigation/IconCheckmark.vue +16 -0
- package/src/modules/icons/navigation/IconChevronRight.vue +2 -2
- package/src/modules/icons/navigation/IconEdit.vue +16 -2
- package/src/modules/icons/navigation/IconEllipsis.vue +16 -0
- package/src/modules/icons/placeholders/PlaceholderChat.vue +9 -0
- package/src/modules/landing/components/sections/MobileApp.vue +38 -21
- package/src/modules/landing/components/sections/SectionEarn.vue +104 -0
- package/src/modules/landing/components/sections/SectionFeatures.vue +80 -0
- package/src/modules/landing/components/sections/{Guide.vue → SectionGuide.vue} +1 -1
- package/src/modules/landing/components/sections/SectionHeroToken.vue +138 -0
- package/src/modules/landing/components/sections/SectionRoadmap.vue +108 -0
- package/src/modules/marketplace/components/layouts/Marketplace.vue +2 -2
- package/src/modules/orders/components/blocks/StatusHistory.vue +7 -1
- package/src/modules/orders/components/pages/Order.vue +3 -4
- package/src/modules/organizations/components/blocks/CardOrganization.vue +6 -6
- package/src/modules/organizations/components/pages/Organization.vue +1 -1
- package/src/modules/organizations/components/sections/DetailsTab.vue +42 -43
- package/src/modules/organizations/components/sections/Publics.vue +3 -4
- package/src/modules/products/components/sections/HeroRecommendation.vue +9 -170
- package/src/modules/products/components/sections/MenuSection.vue +4 -4
- package/src/modules/products/components/sections/PopularProducts.vue +3 -3
- package/src/modules/spots/components/layouts/Spots.vue +2 -2
- package/src/modules/wallet/components/pages/Wallet.vue +1 -1
- package/src/styles/base/all.scss +4 -0
- package/src/styles/base/backgrounds.scss +2 -2
- package/src/styles/base/shadow_transitions_hover_refactor.scss +11 -1
- package/src/styles/typography.scss +19 -12
- package/src/modules/community/components/sections/SubscribeNewsletter.vue +0 -67
- package/src/modules/constructor/components/elements/Youtube.vue +0 -52
- package/src/modules/landing/components/sections/HeroGovernance.vue +0 -156
@@ -1,161 +1,150 @@
|
|
1
|
-
// CONFIGS
|
2
|
-
// const sms = require("../config/sms.config");
|
3
1
|
// --------------------------------------------------
|
4
2
|
// DEPENENCY
|
5
3
|
// --------------------------------------------------
|
6
4
|
const axios = require('axios');
|
7
|
-
// --------------------------------------------------
|
8
|
-
// Used models
|
9
5
|
// --------------------------------------------------
|
10
|
-
|
11
|
-
|
6
|
+
// UTILS
|
7
|
+
// --------------------------------------------------
|
8
|
+
const { sendChatMessageTelegram } = require('@pf/src/modules/globals/utils/mailing');
|
12
9
|
// --------------------------------------------------
|
13
10
|
// METHODS
|
14
11
|
// --------------------------------------------------
|
15
|
-
|
16
|
-
|
17
|
-
const applications = await Application.find({});
|
18
|
-
if (!applications) {
|
19
|
-
return res.status(404).send({ message: "Applications not found." });
|
20
|
-
}
|
21
|
-
res.status(200).send(applications);
|
22
|
-
} catch (err) {
|
23
|
-
res.status(500).send({ message: err });
|
24
|
-
}
|
25
|
-
};
|
26
|
-
|
27
|
-
exports.create = async (req, res) => {
|
28
|
-
try {
|
29
|
-
const application = await Application.create(req.body);
|
30
|
-
if (!application) {
|
31
|
-
return res.status(404).send({ message: "Something wrong when creating application." });
|
32
|
-
}
|
12
|
+
const middlewareFactory = (db) => {
|
13
|
+
const Application = db.application;
|
33
14
|
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
[
|
44
|
-
{ text: 'Confirm', callback_data: `confirm_${application._id}` },
|
45
|
-
{ text: 'Lost', callback_data: `lost_${application._id}` },
|
46
|
-
{ text: 'Delete', callback_data: `delete_${application._id}` }
|
47
|
-
]
|
48
|
-
]
|
49
|
-
});
|
50
|
-
|
51
|
-
const telegramUrl = `https://api.telegram.org/bot${telegramToken}/sendMessage`;
|
52
|
-
|
53
|
-
// Отправка сообщения каждому чату из массива
|
54
|
-
for (const chatId of chatIds) {
|
55
|
-
await axios.post(telegramUrl, {
|
56
|
-
chat_id: chatId,
|
57
|
-
text: text,
|
58
|
-
// reply_markup: inlineKeyboard
|
59
|
-
});
|
15
|
+
const read = async (req, res) => {
|
16
|
+
try {
|
17
|
+
const applications = await Application.find({});
|
18
|
+
if (!applications) {
|
19
|
+
return res.status(404).send({ message: "Applications not found." });
|
20
|
+
}
|
21
|
+
res.status(200).send(applications);
|
22
|
+
} catch (err) {
|
23
|
+
res.status(500).send({ message: err });
|
60
24
|
}
|
25
|
+
};
|
61
26
|
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
res.status(500).send({ message: err });
|
66
|
-
}
|
67
|
-
};
|
68
|
-
|
27
|
+
const create = async (req, res) => {
|
28
|
+
try {
|
29
|
+
const application = await Application.create(req.body);
|
69
30
|
|
70
|
-
|
71
|
-
|
31
|
+
if (!application) {
|
32
|
+
return res.status(404).send({ message: "Something wrong when creating application." });
|
33
|
+
}
|
72
34
|
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
35
|
+
try {
|
36
|
+
const messageSent = await sendChatMessageTelegram(process.env.TELEGRAM_BOT_USERS.split(","),`New application from ${req.body}`)
|
37
|
+
} catch (err) {
|
38
|
+
console.log(err)
|
39
|
+
}
|
40
|
+
res.status(200).send(application);
|
77
41
|
|
78
|
-
|
79
|
-
|
42
|
+
} catch (err) {
|
43
|
+
res.status(500).send({ message: err });
|
44
|
+
}
|
45
|
+
};
|
80
46
|
|
47
|
+
const update = async (req, res) => {
|
81
48
|
try {
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
updatedApplication = await Application.findOneAndUpdate(
|
88
|
-
{ _id: applicationId },
|
89
|
-
{ status: 'confirmed' },
|
90
|
-
{ new: true }
|
91
|
-
);
|
92
|
-
break;
|
93
|
-
case 'lost':
|
94
|
-
updatedApplication = await Application.findOneAndUpdate(
|
95
|
-
{ _id: applicationId },
|
96
|
-
{ status: 'lost' },
|
97
|
-
{ new: true }
|
98
|
-
);
|
99
|
-
break;
|
100
|
-
case 'delete':
|
101
|
-
updatedApplication = await Application.findOneAndDelete({ _id: applicationId });
|
102
|
-
break;
|
103
|
-
}
|
104
|
-
|
105
|
-
if (!updatedApplication) {
|
106
|
-
console.log("Application not found or not updated.");
|
107
|
-
} else {
|
108
|
-
console.log("Application updated:", updatedApplication);
|
109
|
-
}
|
110
|
-
|
49
|
+
const application = await Application.findOneAndUpdate({ _id: req.params._id }, req.body, { new: true });
|
50
|
+
if (!application) {
|
51
|
+
return res.status(404).send({ message: "Application not found." });
|
52
|
+
}
|
53
|
+
res.status(200).send(application);
|
111
54
|
} catch (err) {
|
112
|
-
|
55
|
+
res.status(500).send({ message: err });
|
113
56
|
}
|
57
|
+
};
|
114
58
|
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
};
|
125
|
-
|
126
|
-
exports.get = async (req, res) => {
|
127
|
-
try {
|
128
|
-
const application = await Application.findOne({ url: req.params.url });
|
129
|
-
if (!application) {
|
130
|
-
return res.status(404).send({ message: "Application not found." });
|
59
|
+
const deleteMethod = async (req, res) => {
|
60
|
+
try {
|
61
|
+
const application = await Application.findOneAndDelete({ _id: req.params._id });
|
62
|
+
if (!application) {
|
63
|
+
return res.status(404).send({ message: "Something wrong when deleting application." });
|
64
|
+
}
|
65
|
+
res.status(200).send(application);
|
66
|
+
} catch (err) {
|
67
|
+
res.status(500).send({ message: err });
|
131
68
|
}
|
132
|
-
|
133
|
-
} catch (err) {
|
134
|
-
res.status(500).send({ message: err });
|
135
|
-
}
|
136
|
-
};
|
69
|
+
};
|
137
70
|
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
71
|
+
const get = async (req, res) => {
|
72
|
+
try {
|
73
|
+
const application = await Application.findOne({ url: req.params.url });
|
74
|
+
if (!application) {
|
75
|
+
return res.status(404).send({ message: "Application not found." });
|
76
|
+
}
|
77
|
+
res.status(200).send(application);
|
78
|
+
} catch (err) {
|
79
|
+
res.status(500).send({ message: err });
|
143
80
|
}
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
81
|
+
};
|
82
|
+
|
83
|
+
const handleTelegramWebhook = async (req, res) => {
|
84
|
+
const update = req.body;
|
85
|
+
|
86
|
+
// Проверка, является ли это обратным вызовом от inline клавиатуры
|
87
|
+
if (update.callback_query) {
|
88
|
+
const callbackQuery = update.callback_query;
|
89
|
+
const callbackData = callbackQuery.data;
|
90
|
+
|
91
|
+
// Разбор callback_data
|
92
|
+
const [action, applicationId] = callbackData.split('_');
|
93
|
+
|
94
|
+
try {
|
95
|
+
// Выполнение действий в зависимости от callback_data
|
96
|
+
let updatedApplication = null;
|
97
|
+
|
98
|
+
switch (action) {
|
99
|
+
case 'confirm':
|
100
|
+
updatedApplication = await Application.findOneAndUpdate(
|
101
|
+
{ _id: applicationId },
|
102
|
+
{ status: 'confirmed' },
|
103
|
+
{ new: true }
|
104
|
+
);
|
105
|
+
break;
|
106
|
+
case 'lost':
|
107
|
+
updatedApplication = await Application.findOneAndUpdate(
|
108
|
+
{ _id: applicationId },
|
109
|
+
{ status: 'lost' },
|
110
|
+
{ new: true }
|
111
|
+
);
|
112
|
+
break;
|
113
|
+
case 'delete':
|
114
|
+
updatedApplication = await Application.findOneAndDelete({ _id: applicationId });
|
115
|
+
break;
|
116
|
+
}
|
117
|
+
|
118
|
+
if (!updatedApplication) {
|
119
|
+
console.log("Application not found or not updated.");
|
120
|
+
} else {
|
121
|
+
console.log("Application updated:", updatedApplication);
|
122
|
+
}
|
123
|
+
|
124
|
+
} catch (err) {
|
125
|
+
console.log("Error updating application:", err);
|
126
|
+
}
|
127
|
+
|
128
|
+
// Ответ на callback query, чтобы убрать часы ожидания на кнопке
|
129
|
+
const queryId = callbackQuery.id;
|
130
|
+
const telegramToken = '6206215053:AAHYCYzpFZF9jDZC-TC03NSff8oo2ExqsSU';
|
131
|
+
axios.post(`https://api.telegram.org/bot${telegramToken}/answerCallbackQuery`, {
|
132
|
+
callback_query_id: queryId
|
133
|
+
});
|
155
134
|
}
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
135
|
+
|
136
|
+
res.sendStatus(200);
|
137
|
+
};
|
138
|
+
|
139
|
+
|
140
|
+
return {
|
141
|
+
read,
|
142
|
+
create,
|
143
|
+
update,
|
144
|
+
delete: deleteMethod,
|
145
|
+
handleTelegramWebhook,
|
146
|
+
get
|
147
|
+
};
|
160
148
|
};
|
161
149
|
|
150
|
+
module.exports = middlewareFactory;
|
@@ -1,13 +1,28 @@
|
|
1
1
|
const mongoose = require('mongoose');
|
2
2
|
|
3
3
|
const ApplicationSchema = new mongoose.Schema({
|
4
|
-
status: {
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
4
|
+
status: {
|
5
|
+
type: String,
|
6
|
+
default: 'created'
|
7
|
+
},
|
8
|
+
type: {
|
9
|
+
type: String,
|
10
|
+
default: 'newsletter'
|
11
|
+
},
|
12
|
+
contacts: {
|
13
|
+
name: {
|
14
|
+
type: String
|
15
|
+
},
|
16
|
+
phone: {
|
17
|
+
type: String
|
18
|
+
},
|
19
|
+
email: {
|
20
|
+
type: String
|
21
|
+
},
|
22
|
+
}
|
23
|
+
}, {
|
24
|
+
timestamps: { currentTime: () => Date.now() }
|
25
|
+
});
|
11
26
|
|
12
27
|
const Application = mongoose.model("Application", ApplicationSchema);
|
13
28
|
|
@@ -1,16 +1,24 @@
|
|
1
|
-
|
1
|
+
// Factories
|
2
|
+
const controllerFactory = require("../controllers/applications.controller");
|
3
|
+
// Middlewares
|
4
|
+
const middlewareFactoryGlobal = require('@pf/src/modules/middlewares/server');
|
5
|
+
module.exports = function(app, db, origins) {
|
6
|
+
const controller = controllerFactory(db);
|
7
|
+
|
8
|
+
const { authJwt } = middlewareFactoryGlobal(db);
|
2
9
|
|
3
|
-
module.exports = function(app) {
|
4
10
|
app.use(function(req, res, next) {
|
5
|
-
|
6
|
-
|
7
|
-
});
|
11
|
+
|
12
|
+
const origin = req.headers.origin;
|
8
13
|
|
14
|
+
if (origins.includes(origin)) {
|
15
|
+
res.setHeader('Access-Control-Allow-Origin', origin);
|
16
|
+
}
|
9
17
|
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
);
|
18
|
+
res.header("Access-Control-Allow-Headers", "x-access-token, Origin, Content-Type, Accept");
|
19
|
+
|
20
|
+
next();
|
21
|
+
});
|
14
22
|
|
15
23
|
app.post(
|
16
24
|
"/applications",
|
@@ -18,11 +26,11 @@ module.exports = function(app) {
|
|
18
26
|
);
|
19
27
|
|
20
28
|
app.get(
|
21
|
-
"/applications
|
22
|
-
controller.
|
29
|
+
"/applications",
|
30
|
+
controller.read
|
23
31
|
);
|
24
32
|
|
25
|
-
|
33
|
+
app.post(
|
26
34
|
"/applications/:_id",
|
27
35
|
controller.update
|
28
36
|
);
|
@@ -31,8 +39,16 @@ module.exports = function(app) {
|
|
31
39
|
"/applications/:_id",
|
32
40
|
controller.delete
|
33
41
|
);
|
42
|
+
|
43
|
+
app.get(
|
44
|
+
"/applications/:_id",
|
45
|
+
controller.get
|
46
|
+
);
|
34
47
|
|
35
|
-
app.post(
|
48
|
+
app.post(
|
49
|
+
"/applications/telegram-webhook",
|
50
|
+
controller.handleTelegramWebhook
|
51
|
+
);
|
36
52
|
|
37
53
|
};
|
38
54
|
|
@@ -76,7 +76,10 @@
|
|
76
76
|
// Localization
|
77
77
|
import text from '@pf/src/modules/auth/localization/EnterCode.json'
|
78
78
|
// Localization
|
79
|
-
const { t } = useI18n(
|
79
|
+
const { t } = useI18n({
|
80
|
+
useScope: 'global',
|
81
|
+
...text
|
82
|
+
})
|
80
83
|
|
81
84
|
const state = reactive({
|
82
85
|
digits: ['', '', '', ''],
|
@@ -53,7 +53,10 @@ const passswordValidation = ref(null)
|
|
53
53
|
// Localization
|
54
54
|
import text from '@pf/src/modules/auth/localization/EnterPassword.json'
|
55
55
|
// Localization
|
56
|
-
const { t } = useI18n(
|
56
|
+
const { t } = useI18n({
|
57
|
+
useScope: 'global',
|
58
|
+
...text
|
59
|
+
})
|
57
60
|
// Accessing router
|
58
61
|
const route = useRoute()
|
59
62
|
const router = useRouter()
|
@@ -72,7 +72,10 @@ import * as twofa from '@pf/src/modules/auth/store/twofa'
|
|
72
72
|
// Import validation
|
73
73
|
import * as inputsValidation from '@pf/src/modules/middlewares/client/inputs.validation'
|
74
74
|
// Localization
|
75
|
-
const { t } = useI18n(
|
75
|
+
const { t } = useI18n({
|
76
|
+
useScope: 'global',
|
77
|
+
...text
|
78
|
+
})
|
76
79
|
// Validation
|
77
80
|
const phoneValidation = ref(null)
|
78
81
|
const emailValidation = ref(null)
|
@@ -78,7 +78,10 @@
|
|
78
78
|
// Import validation
|
79
79
|
import * as inputsValidation from '@pf/src/modules/middlewares/client/inputs.validation'
|
80
80
|
// Localization
|
81
|
-
const { t } = useI18n(
|
81
|
+
const { t } = useI18n({
|
82
|
+
useScope: 'global',
|
83
|
+
...text
|
84
|
+
})
|
82
85
|
// Validation
|
83
86
|
const phoneValidation = ref(null)
|
84
87
|
const emailValidation = ref(null)
|
@@ -6,7 +6,7 @@ const { uuid } = require('uuidv4');
|
|
6
6
|
const { verifyAppleIdToken } = require('../utils/server/verifyAppleIdToken')
|
7
7
|
// Factory
|
8
8
|
const controllerFactory = (db) => {
|
9
|
-
|
9
|
+
|
10
10
|
const User = db.user;
|
11
11
|
const Membership = db.membership;
|
12
12
|
const Invite = db.invite;
|
@@ -38,7 +38,6 @@ const controllerFactory = (db) => {
|
|
38
38
|
}
|
39
39
|
|
40
40
|
try {
|
41
|
-
|
42
41
|
let user = await User.findOne(query).populate('roles').exec();
|
43
42
|
|
44
43
|
if ((type === 'email' || type === 'phone')) {
|
@@ -89,7 +88,7 @@ const controllerFactory = (db) => {
|
|
89
88
|
}
|
90
89
|
});
|
91
90
|
} catch (err) {
|
92
|
-
console.error(err);
|
91
|
+
// console.error(err);
|
93
92
|
res.status(500).send({ message: err });
|
94
93
|
}
|
95
94
|
};
|
@@ -32,8 +32,6 @@
|
|
32
32
|
|
33
33
|
const userCookie = await getCookie('user');
|
34
34
|
|
35
|
-
console.log('user cookie is ' + userCookie)
|
36
|
-
|
37
35
|
if (userCookie) {
|
38
36
|
const { _id, email, phone, roles, accessToken } = userCookie;
|
39
37
|
|
@@ -212,8 +210,8 @@
|
|
212
210
|
|
213
211
|
// Cookies
|
214
212
|
const optionsDefault = {
|
215
|
-
development: { secure: false, expires:
|
216
|
-
production: { expires:
|
213
|
+
development: { secure: false, expires: 7 },
|
214
|
+
production: { expires: 7, path: '/', domain: process.env.API_URL, sameSite: 'none', secure: true }
|
217
215
|
};
|
218
216
|
|
219
217
|
async function getCookie(name) {
|
@@ -226,7 +224,7 @@
|
|
226
224
|
}
|
227
225
|
}
|
228
226
|
|
229
|
-
function setCookie(name, data, env = process.env.
|
227
|
+
function setCookie(name, data, env = process.env.DOMAIN_URL) {
|
230
228
|
if (process.env.MOBILE_APP) {
|
231
229
|
// Если приложение запущено в Capacitor
|
232
230
|
Preferences.set({
|
@@ -3,8 +3,9 @@
|
|
3
3
|
class="pd-small"
|
4
4
|
:class="{'bg-main-nano': message.username === 'Weeder Support'}"
|
5
5
|
>
|
6
|
-
<p class="w-100 p-small">
|
7
|
-
<
|
6
|
+
<p class="flex-v-center gap-thin flex-nowrap flex w-100 p-small">
|
7
|
+
<img v-if="message.username === 'Weeder Support'" src="/logo/logo.png" class="i-medium">
|
8
|
+
<strong class="mn-r-auto"><span class="t-semi">{{ message.username }}</span> <span class="t-transp">{{formatDate(message.createdAt)}}</span></strong>
|
8
9
|
</p>
|
9
10
|
<p>{{ message.text }}</p>
|
10
11
|
</div>
|
@@ -1,15 +1,15 @@
|
|
1
1
|
<template>
|
2
|
-
<div class="chat-page">
|
3
|
-
<aside class="chat-list">
|
2
|
+
<!-- <div class="chat-page h-max-20r"> -->
|
3
|
+
<!-- <aside class="chat-list"> -->
|
4
4
|
<!-- Примерный список чатов. Должен быть дополнен реальной логикой -->
|
5
5
|
<!-- <div v-for="chat in chats" :key="chat.id" @click="selectChat(chat.id)">
|
6
6
|
Чат {{ chat.name }}
|
7
7
|
</div> -->
|
8
|
-
</aside>
|
9
|
-
<main class="chat-main">
|
8
|
+
<!-- </aside> -->
|
9
|
+
<!-- <main class="chat-main"> -->
|
10
10
|
<ChatWindow />
|
11
|
-
</main>
|
12
|
-
</div>
|
11
|
+
<!-- </main> -->
|
12
|
+
<!-- </div> -->
|
13
13
|
</template>
|
14
14
|
|
15
15
|
<script setup>
|
@@ -1,27 +1,56 @@
|
|
1
1
|
<template>
|
2
|
-
<div class="
|
3
|
-
|
4
|
-
<
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
2
|
+
<div class="bg-white radius-semi bg-white o-hidden pos-relative">
|
3
|
+
|
4
|
+
<div ref="allMessages" class="chat-messages o-scroll h-max-20r">
|
5
|
+
<div class="pos-relative h-min-20r flex-justify-end flex flex-column br-b br-solid br-black-transp-10">
|
6
|
+
<transition name="scaleIn" mode="out-in">
|
7
|
+
<div v-if="messages.length < 1" class="flex-center w-100 h-100 flex-column flex pos-absolute">
|
8
|
+
<PlaceholderChat class="radius-100 mn-b-thin"/>
|
9
|
+
<h4>Here you can view your chat history</h4>
|
10
|
+
<p>Feel free to ask if you have any questions.</p>
|
11
|
+
</div>
|
12
|
+
|
13
|
+
<TransitionGroup v-else name="list" tag="ul" class="w-100 o-hidden">
|
14
|
+
<ChatMessage
|
15
|
+
v-for="message in messages"
|
16
|
+
:key="message._id"
|
17
|
+
:message="message"
|
18
|
+
/>
|
19
|
+
|
20
|
+
</TransitionGroup>
|
21
|
+
</transition>
|
22
|
+
|
23
|
+
</div>
|
24
|
+
</div>
|
25
|
+
|
26
|
+
|
27
|
+
<div class="flex-nowrap flex-v-center flex bg-white w-100 radius-big pd-small">
|
28
|
+
<IconAdd
|
29
|
+
class="mn-r-thin t-transp i-regular"
|
30
|
+
/>
|
31
|
+
<input class="" placeholder="Enter your message" type="text" v-model="newMessage" @keyup.enter="sendMessage" />
|
32
|
+
</div>
|
11
33
|
</div>
|
12
34
|
</template>
|
13
35
|
|
14
36
|
<script setup>
|
15
|
-
import { ref, computed } from 'vue';
|
37
|
+
import { ref, computed, watch } from 'vue';
|
38
|
+
|
39
|
+
import IconAdd from '@pf/src/modules/icons/navigation/IconAdd.vue'
|
40
|
+
import PlaceholderChat from '@pf/src/modules/icons/placeholders/PlaceholderChat.vue'
|
41
|
+
|
16
42
|
import ChatMessage from '../blocks/ChatMessage.vue';
|
17
43
|
import chatStore from '../../store/chat.store.js';
|
18
44
|
|
19
45
|
const newMessage = ref('');
|
46
|
+
const allMessages = ref(null)
|
47
|
+
|
48
|
+
// Вычисляемые свойства
|
20
49
|
const messages = computed(() => chatStore.state.messages);
|
21
50
|
|
51
|
+
// Функция для отправки сообщения
|
22
52
|
const sendMessage = () => {
|
23
53
|
if (newMessage.value) {
|
24
|
-
|
25
54
|
const message = {
|
26
55
|
text: newMessage.value,
|
27
56
|
username: chatStore.state.username,
|
@@ -29,12 +58,28 @@ const sendMessage = () => {
|
|
29
58
|
};
|
30
59
|
|
31
60
|
chatStore.methods.addMessage(message);
|
61
|
+
console.log(allMessages.value.lastElementChild.offsetHeight)
|
62
|
+
allMessages.value.scrollTop = allMessages.value.lastElementChild.offsetHeight
|
32
63
|
|
33
64
|
newMessage.value = '';
|
34
65
|
}
|
35
66
|
};
|
67
|
+
|
68
|
+
// // При добавлении нового сообщения автоматически прокручиваем вниз
|
69
|
+
watch(chatStore.state.messages, () => {
|
70
|
+
allMessages.value.scrollTop = allMessages.value.lastElementChild.offsetHeight
|
71
|
+
}, {deep: true});
|
72
|
+
|
36
73
|
</script>
|
37
74
|
|
38
75
|
<style>
|
39
|
-
|
76
|
+
.list-enter-active,
|
77
|
+
.list-leave-active {
|
78
|
+
transition: all 0.5s ease;
|
79
|
+
}
|
80
|
+
.list-enter-from,
|
81
|
+
.list-leave-to {
|
82
|
+
opacity: 0;
|
83
|
+
transform: translateX(30px);
|
84
|
+
}
|
40
85
|
</style>
|
@@ -9,8 +9,12 @@ const state = reactive({
|
|
9
9
|
|
10
10
|
const methods = {
|
11
11
|
connectWebSocket() {
|
12
|
+
console.log('process env')
|
13
|
+
console.log(process.env.WSS_URL)
|
14
|
+
|
12
15
|
return new Promise(function(resolve, reject) {
|
13
|
-
|
16
|
+
|
17
|
+
state.websocket = new WebSocket(process.env.WSS_URL);
|
14
18
|
|
15
19
|
state.websocket.onopen = function() {
|
16
20
|
resolve(state.websocket);
|
@@ -28,6 +32,7 @@ const methods = {
|
|
28
32
|
});
|
29
33
|
},
|
30
34
|
setMessages(messages) {
|
35
|
+
console.log(process.env.API_URL)
|
31
36
|
state.messages = messages;
|
32
37
|
},
|
33
38
|
addMessage(message) {
|