Improve G1G1 process (#11792)

* WIP(g1g1): notif

* WIP(g1g1): notif cont'd

* WIP(gifting): partial modal implementation

* feat(gifting): select giftee modal

* fix(gifting): notification order, modal dismiss

* fix(modals): correct some repops

* fix(gifting): style updates

* fix(modals): new dismiss logic

* fix(modals): new dismiss no go??

* refactor(close): catch up with dismiss functionality

* refactor(g1g1): optimizations
This commit is contained in:
Sabe Jones
2020-02-24 09:54:57 -06:00
committed by GitHub
parent 5718d8396d
commit e502588abc
5 changed files with 23 additions and 6 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 41 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 12 KiB

View File

@@ -2,19 +2,38 @@
<div <div
class="notification d-flex flex-column justify-content-center text-center" class="notification d-flex flex-column justify-content-center text-center"
> >
<strong class="mx-auto mb-2"> {{ $t('g1g1Announcement') }} </strong> <strong
<p class="mx-4"> {{ $t('g1g1Details') }} </p> class="mx-auto mb-2"
v-once
>
{{ $t('g1g1Announcement') }}
</strong>
<p
class="mx-4"
v-once
>
{{ $t('g1g1Details') }}
</p>
<div <div
class="btn-secondary mx-auto d-flex" class="btn-secondary mx-auto d-flex"
@click="showSelectUser()" @click="showSelectUser()"
> >
<div class="m-auto"> {{ $t('sendGift') }} </div> <div
class="m-auto"
v-once
>
{{ $t('sendGift') }}
</div>
</div> </div>
<div <div
class="notification-remove" class="notification-remove"
@click.stop="remove()" @click.stop="remove()"
> >
<div class="svg-icon" v-html="icons.close"></div> <div
class="svg-icon"
v-html="icons.close"
v-once
></div>
</div> </div>
</div> </div>
</template> </template>

View File

@@ -173,7 +173,6 @@ export default {
methods: { methods: {
close () { close () {
this.$root.$emit('habitica::dismiss-modal', 'select-user-modal'); this.$root.$emit('habitica::dismiss-modal', 'select-user-modal');
this.$root.$emit('bv::hide::modal', 'select-user-modal');
}, },
searchUser: debounce(async function userSearch (searchTerm) { searchUser: debounce(async function userSearch (searchTerm) {
this.foundUser = {}; this.foundUser = {};

View File

@@ -245,7 +245,6 @@ export default {
close () { close () {
this.paymentData = {}; this.paymentData = {};
this.$root.$emit('habitica::dismiss-modal', 'payments-success-modal'); this.$root.$emit('habitica::dismiss-modal', 'payments-success-modal');
this.$root.$emit('bv::hide::modal', 'payments-success-modal');
}, },
}, },
}; };