mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-19 07:37:25 +01:00
modal essentially complete but for scripts
This commit is contained in:
@@ -35,6 +35,7 @@
|
|||||||
<sub-canceled-modal v-if="isUserLoaded" />
|
<sub-canceled-modal v-if="isUserLoaded" />
|
||||||
<bug-report-modal v-if="isUserLoaded" />
|
<bug-report-modal v-if="isUserLoaded" />
|
||||||
<bug-report-success-modal v-if="isUserLoaded" />
|
<bug-report-success-modal v-if="isUserLoaded" />
|
||||||
|
<external-link-modal />
|
||||||
<birthday-modal />
|
<birthday-modal />
|
||||||
<snackbars />
|
<snackbars />
|
||||||
<router-view v-if="!isUserLoggedIn || isStaticPage" />
|
<router-view v-if="!isUserLoggedIn || isStaticPage" />
|
||||||
@@ -175,6 +176,7 @@ import amazonPaymentsModal from '@/components/payments/amazonModal';
|
|||||||
import paymentsSuccessModal from '@/components/payments/successModal';
|
import paymentsSuccessModal from '@/components/payments/successModal';
|
||||||
import subCancelModalConfirm from '@/components/payments/cancelModalConfirm';
|
import subCancelModalConfirm from '@/components/payments/cancelModalConfirm';
|
||||||
import subCanceledModal from '@/components/payments/canceledModal';
|
import subCanceledModal from '@/components/payments/canceledModal';
|
||||||
|
import externalLinkModal from '@/components/externalLinkModal.vue';
|
||||||
|
|
||||||
import spellsMixin from '@/mixins/spells';
|
import spellsMixin from '@/mixins/spells';
|
||||||
import {
|
import {
|
||||||
@@ -210,6 +212,7 @@ export default {
|
|||||||
subCanceledModal,
|
subCanceledModal,
|
||||||
bugReportModal,
|
bugReportModal,
|
||||||
bugReportSuccessModal,
|
bugReportSuccessModal,
|
||||||
|
externalLinkModal,
|
||||||
},
|
},
|
||||||
mixins: [notifications, spellsMixin],
|
mixins: [notifications, spellsMixin],
|
||||||
data () {
|
data () {
|
||||||
|
|||||||
@@ -22,21 +22,26 @@
|
|||||||
v-html="icons.exclamation"
|
v-html="icons.exclamation"
|
||||||
></div>
|
></div>
|
||||||
</div>
|
</div>
|
||||||
<h2>You are about to leave Habitica.com</h2>
|
<h2>
|
||||||
|
{{ $t('leaveHabitica') }}
|
||||||
|
</h2>
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
|
||||||
Habitica is not responsible for the content of any linked
|
<!-- BODY -->
|
||||||
website that is not owned or operated by HabitRPG.
|
<div
|
||||||
Please note that these websites' practices may differ
|
class="row leave-warning-text"
|
||||||
from Habitica’s community guidelines.
|
v-html="$t('leaveHabiticaText')"
|
||||||
|
>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- FOOTER -->
|
||||||
<div slot="modal-footer">
|
<div slot="modal-footer">
|
||||||
<button
|
<button
|
||||||
v-once
|
v-once
|
||||||
class="btn btn-primary"
|
class="btn btn-primary"
|
||||||
@click="submit()"
|
@click="close()"
|
||||||
>
|
>
|
||||||
{{ $t('onwards') }}
|
{{ $t('continue') }}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</b-modal>
|
</b-modal>
|
||||||
@@ -44,7 +49,32 @@
|
|||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '~@/assets/scss/colors.scss';
|
@import '~@/assets/scss/colors.scss';
|
||||||
|
|
||||||
#external-link-modal {
|
#external-link-modal {
|
||||||
|
.modal-md {
|
||||||
|
max-width: 448px;
|
||||||
|
min-width: 330px;
|
||||||
|
|
||||||
|
.modal-close {
|
||||||
|
position: absolute;
|
||||||
|
right: 16px;
|
||||||
|
top: 16px;
|
||||||
|
cursor: pointer;
|
||||||
|
|
||||||
|
.icon-close {
|
||||||
|
width: 18px;
|
||||||
|
height: 18px;
|
||||||
|
vertical-align: middle;
|
||||||
|
|
||||||
|
& svg {
|
||||||
|
fill: $yellow-1;
|
||||||
|
}
|
||||||
|
& :hover {
|
||||||
|
fill: $yellow-1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.modal-content {
|
.modal-content {
|
||||||
background: transparent;
|
background: transparent;
|
||||||
}
|
}
|
||||||
@@ -58,10 +88,6 @@
|
|||||||
border-top-left-radius: 8px;
|
border-top-left-radius: 8px;
|
||||||
border-bottom: none;
|
border-bottom: none;
|
||||||
|
|
||||||
h2 {
|
|
||||||
color: $green-1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.exclamation-container {
|
.exclamation-container {
|
||||||
width: 64px;
|
width: 64px;
|
||||||
height: 64px;
|
height: 64px;
|
||||||
@@ -72,43 +98,42 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.svg-exclamation {
|
.svg-exclamation {
|
||||||
width: 45px;
|
width: 8px;
|
||||||
color: $white;
|
color: $white;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
h2 {
|
||||||
|
color: $yellow-1;
|
||||||
|
// font-size: 1.25rem;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.modal-body {
|
.modal-body {
|
||||||
padding: 16px 32px 24px 32px;
|
padding: 16px 44px 20px 44px;
|
||||||
background: $white;
|
background: $white;
|
||||||
|
|
||||||
.modal-body-col {
|
.leave-warning-text {
|
||||||
display: flex;
|
font-size: 0.875rem;
|
||||||
flex-direction: column;
|
line-height: 1.71;
|
||||||
align-items: center;
|
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
|
||||||
.btn.btn-primary {
|
|
||||||
margin-top: 24px;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.details-block {
|
.modal-footer {
|
||||||
background: $gray-700;
|
background: $white;
|
||||||
border-radius: 4px;
|
border-bottom-right-radius: 8px;
|
||||||
padding: 8px 16px;
|
border-bottom-left-radius: 8px;
|
||||||
margin-top: 16px;
|
justify-content: center;
|
||||||
display: inline-flex;
|
border-top: none;
|
||||||
flex-direction: row;
|
padding-top: 0;
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import exclamationIcon from '@assets/svg/exclamation.svg';
|
import exclamationIcon from '@/assets/svg/exclamation.svg';
|
||||||
import closeIcon from '@/assets/svg/close.svg';
|
import closeIcon from '@/assets/svg/new-close.svg';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data () {
|
data () {
|
||||||
@@ -123,7 +148,7 @@ export default {
|
|||||||
close () {
|
close () {
|
||||||
this.$root.$emit('bv::hide::modal', 'external-link-modal');
|
this.$root.$emit('bv::hide::modal', 'external-link-modal');
|
||||||
console.log('Bye!');
|
console.log('Bye!');
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -212,5 +212,7 @@
|
|||||||
"contactForm": "Contact the Moderation Team",
|
"contactForm": "Contact the Moderation Team",
|
||||||
"loadEarlierMessages": "Load Earlier Messages",
|
"loadEarlierMessages": "Load Earlier Messages",
|
||||||
"askQuestion": "Ask a Question",
|
"askQuestion": "Ask a Question",
|
||||||
"emptyReportBugMessage": "Report Bug Message missing"
|
"emptyReportBugMessage": "Report Bug Message missing",
|
||||||
|
"leaveHabitica": "You are about to leave Habitica.com",
|
||||||
|
"leaveHabiticaText": "Habitica is not responsible for the content of any linked website that is not owned or operated by HabitRPG.<br>Please note that these websites' practices may differ from Habitica’s community guidelines."
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user