diff --git a/package.json b/package.json index 58b5e1235..48e8536c6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "polkaswap-exchange-web", - "version": "1.26.0", + "version": "1.26.1", "repository": { "type": "git", "url": "https://github.com/sora-xor/polkaswap-exchange-web.git" diff --git a/public/marketing.json b/public/marketing.json index 2e158f56c..cbbdf3976 100644 --- a/public/marketing.json +++ b/public/marketing.json @@ -1,4 +1,9 @@ [ + { + "title": "ROADMAP 2024 SURVEY", + "img": "/marketing/survey.png", + "link": "https://form.typeform.com/to/Mb6p2Kpy" + }, { "title": "SORA POLKADOT CROWDLOAN", "img": "/marketing/crowdloan.png", diff --git a/public/marketing/survey.png b/public/marketing/survey.png new file mode 100644 index 000000000..1c3784620 Binary files /dev/null and b/public/marketing/survey.png differ diff --git a/src/App.vue b/src/App.vue index 3ee44bc6e..cc5aadc2c 100644 --- a/src/App.vue +++ b/src/App.vue @@ -6,7 +6,7 @@ :visible="menuVisibility" :on-select="goTo" :is-about-page-opened="isAboutPage" - @open-download-dialog="openDownloadDialog" + @open-product-dialog="openProductDialog" @click.native="handleAppMenuClick" > @@ -23,7 +23,7 @@ - + @@ -88,9 +88,10 @@ import type Theme from '@soramitsu/soramitsu-js-ui/lib/types/Theme'; }, }) export default class App extends Mixins(mixins.TransactionMixin, NodeErrorMixin) { + /** Product-based class fields should be like show${product}Popup */ + showSoraMobilePopup = false; menuVisibility = false; showConfirmInviteUser = false; - showMobilePopup = false; showNotifsDarkPage = false; responsiveClass = BreakpointClass.LargeDesktop; @@ -354,8 +355,12 @@ export default class App extends Mixins(mixins.TransactionMixin, NodeErrorMixin) } } - openDownloadDialog(): void { - this.showMobilePopup = true; + openProductDialog(product: string): void { + // Product-based class fields should be like show${product}Popup (like showSoraMobilePopup) + const fieldName = `show${product[0].toUpperCase() + product.slice(1)}Popup`; + if (typeof this[fieldName] === 'boolean') { + this[fieldName] = true; + } } async beforeDestroy(): Promise { diff --git a/src/components/App/Menu/AppInfoPopper.vue b/src/components/App/Menu/AppInfoPopper.vue index a86ef558a..8c71b4380 100644 --- a/src/components/App/Menu/AppInfoPopper.vue +++ b/src/components/App/Menu/AppInfoPopper.vue @@ -1,5 +1,11 @@ - + + + + + {{ product.title }} + + + + {{ product.title }} + + + import { api, mixins } from '@soramitsu/soraneo-wallet-web'; -import { Component, Mixins } from 'vue-property-decorator'; +import { Component, Mixins, Ref } from 'vue-property-decorator'; import TranslationMixin from '@/components/mixins/TranslationMixin'; import { app, SocialNetworkLinks, Links } from '@/consts'; @@ -50,6 +74,8 @@ export default class AppInfoPopper extends Mixins(TranslationMixin, mixins.Loadi readonly SocialNetworkLinks = SocialNetworkLinks; readonly app = app; + @Ref('infoPopup') private readonly infoPopup!: any; + specVersion: Nullable = null; created(): void { @@ -58,6 +84,21 @@ export default class AppInfoPopper extends Mixins(TranslationMixin, mixins.Loadi }); } + private showSoraMobileDialog(): void { + this.$emit('open-product-dialog', 'soraMobile'); + this.infoPopup?.doClose?.(); + } + + get products(): Array<{ title: string; icon?: string; href?: string; action?: () => void }> { + return [ + { + title: this.t('mobilePopup.sideMenu'), + icon: 'symbols-24', + action: this.showSoraMobileDialog, + }, + ]; + } + get textLinks(): Array<{ title: string; href: string }> { return [ { @@ -148,10 +189,15 @@ $social-link-min-height: 34px; } } - &--social { + &--social, + &--product { min-height: $social-link-min-height; } + &--product:hover { + cursor: pointer; + } + &--text { & + & { margin-top: $basic-spacing-small; diff --git a/src/components/App/Menu/AppMenu.vue b/src/components/App/Menu/AppMenu.vue index c3e273cab..9c7b4c97d 100644 --- a/src/components/App/Menu/AppMenu.vue +++ b/src/components/App/Menu/AppMenu.vue @@ -49,25 +49,16 @@ active-hover-color="transparent" > - - +