Skip to content

Commit

Permalink
Merge pull request #31 from soramitsu/feature/terms
Browse files Browse the repository at this point in the history
Added docs and disclaimer, changed about logo
  • Loading branch information
timofeytrepalin authored May 25, 2023
2 parents 4b1e849 + 7946d4e commit b07ad89
Show file tree
Hide file tree
Showing 11 changed files with 939 additions and 18 deletions.
1 change: 1 addition & 0 deletions public/adar/terms/ADARPrivacyPolicy.html

Large diffs are not rendered by default.

900 changes: 900 additions & 0 deletions public/adar/terms/ADARUpdatedTerms.html

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
<s-scrollbar class="app-body-scrollbar" v-loading="pageLoading">
<div class="app-content">
<router-view :parent-loading="loading || !nodeIsConnected" />
<app-disclaimer v-if="disclaimerVisibility" />
<!-- <p class="app-disclaimer" v-html="t('disclaimer')" /> -->
</div>
<footer class="app-footer">
Expand Down
8 changes: 8 additions & 0 deletions src/assets/img/adar/sidebar.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions src/components/App/Header/AppDisclaimer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -70,15 +70,15 @@ export default class AppDisclaimer extends Mixins(TranslationMixin) {
}
get memorandumLink(): string {
return this.generateDisclaimerLink(Links.terms, this.t('memorandum'));
return this.generateDisclaimerLink(Links.terms, this.$t('memorandum', { AppName: 'Polkaswap' }).toString());
}
get privacyLink(): string {
return this.generateDisclaimerLink(Links.privacy, this.t('helpDialog.privacyPolicy'));
}
get polkaswapFaqLink(): string {
return this.generateDisclaimerLink(Links.faq, this.t('FAQ'));
return this.generateDisclaimerLink(Links.faq, this.$t('FAQ', { AppName: 'Polkaswap' }).toString());
}
generateDisclaimerLink(href: string, content: string): string {
Expand Down
12 changes: 6 additions & 6 deletions src/components/App/Header/AppHeaderMenu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -177,12 +177,12 @@ export default class AppHeaderMenu extends Mixins(TranslationMixin) {
icon: 'basic-globe-24',
text: this.t('headerMenu.switchLanguage'),
},
// {
// value: HeaderMenuType.Disclaimer,
// icon: 'info-16',
// text: this.disclaimerText,
// disabled: this.discalimerDisabled,
// },
{
value: HeaderMenuType.Disclaimer,
icon: 'info-16',
text: this.disclaimerText,
disabled: this.discalimerDisabled,
},
];
}
Expand Down
17 changes: 9 additions & 8 deletions src/components/App/Menu/AppInfoPopper.vue
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ import { api, mixins } from '@soramitsu/soraneo-wallet-web';
import TranslationMixin from '@/components/mixins/TranslationMixin';
import { app, SocialNetworkLinks, Links } from '@/consts';
import { Links as AdarLinks } from '@/modules/ADAR/consts';
@Component
export default class AppInfoPopper extends Mixins(TranslationMixin, mixins.LoadingMixin) {
Expand All @@ -62,18 +63,18 @@ export default class AppInfoPopper extends Mixins(TranslationMixin, mixins.Loadi
get textLinks(): Array<{ title: string; href: string }> {
return [
// {
// title: this.t('helpDialog.privacyPolicy'),
// href: Links.privacy,
// },
{
title: this.t('helpDialog.privacyPolicy'),
href: AdarLinks.privacy,
},
{
title: this.t('releaseNotesText'),
href: Links.releaseNotes,
},
// {
// title: this.t('helpDialog.termsOfService'),
// href: Links.terms,
// },
{
title: this.t('helpDialog.termsOfService'),
href: AdarLinks.terms,
},
];
}
Expand Down
5 changes: 5 additions & 0 deletions src/components/App/Menu/SidebarItemContent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
<div v-if="icon === 'sora-card'" class="icon-container">
<side-menu-card class="sora-card-sidebar-icon" />
</div>
<div v-else-if="icon === 'adar-about'" class="icon-container">
<side-menu-adar-about class="sora-card-sidebar-icon" />
</div>
<div v-else-if="icon" class="icon-container">
<s-icon :name="icon" size="28" />
</div>
Expand All @@ -15,10 +18,12 @@
import { Component, Mixins, Prop } from 'vue-property-decorator';
import TranslationMixin from '@/components/mixins/TranslationMixin';
import SideMenuCard from '@/assets/img/sora-card/sidebar.svg?inline';
import SideMenuAdarAbout from '@/assets/img/adar/sidebar.svg?inline';
@Component({
components: {
SideMenuCard,
SideMenuAdarAbout,
},
})
export default class AppSidebarItemContent extends Mixins(TranslationMixin) {
Expand Down
2 changes: 1 addition & 1 deletion src/consts/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ const OtherPagesMenu: Array<SidebarMenuItem> = [
// title: PageNames.SoraCard,
// },
{
icon: 'file-file-text-24',
icon: 'adar-about',
title: AdarPageNames.About,
},
];
Expand Down
2 changes: 1 addition & 1 deletion src/lang/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@
"connectWalletTextTooltip": "Connect to {Sora} Network with {PolkadotJs}",
"selectNodeText": "Select Network Node",
"bridgeText": "Bridge",
"disclaimer": "{disclaimerPrefix} This website is maintained by the {Sora} community. Before continuing to use this website, please review the {polkaswapFaqLink} and documentation, which includes a detailed explanation on how {AppName} works, as well as the {memorandumLink}, and {privacyLink}. These documents are crucial to a secure and positive user experience. By using {AppName}, you acknowledge that you have read and understand these documents. You also acknowledge the following: 1) your sole responsibility for compliance with all laws that may apply to your particular use of {AppName} in your legal jurisdiction; 2) your understanding that the current version of {AppName} is an alpha version: it has not been fully tested, and some functions may not perform as designed; and 3) your understanding and voluntary acceptance of the risks involved in using {AppName}, including, but not limited to, the risk of losing tokens. Please do not continue without reading the {polkaswapFaqLink}, {memorandumLink}, {privacyLink}!",
"disclaimer": "The token swap functionality on ADAR Technologies Inc’s website is powered by the Polkaswap website (www.polkaswap.io) which is not maintained by us and is maintained by the SORA community. Therefore, in addition to our terms, the terms of Polkaswap apply mutatis mutandis. The terms of Polkaswap are available at {polkaswapFaqLink}, {memorandumLink}, and {privacyLink} ",
"poweredBy": "Powered by",
"confirmTransactionText": "Confirm transaction in {direction}",
"retryText": "Retry",
Expand Down
5 changes: 5 additions & 0 deletions src/modules/ADAR/consts/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,11 @@ export const Stages: Array<Stage> = [
createStage('Done', 'done'),
];

export const Links = {
terms: '/adar/terms/ADARUpdatedTerms.html',
privacy: '/adar/terms/ADARPrivacyPolicy.html',
};

function createStage(title: string, componentName: string): Stage {
return {
title,
Expand Down

0 comments on commit b07ad89

Please sign in to comment.