From c2dbbe6396540ee9d76991a00f5028b49d221d0c Mon Sep 17 00:00:00 2001 From: Zephyrrus Date: Thu, 2 Jul 2020 23:42:02 +0300 Subject: feat: refactor account to use vuex, fix small presentational components --- src/site/pages/dashboard/account.vue | 74 +++++++++++++++++++++--------------- 1 file changed, 44 insertions(+), 30 deletions(-) (limited to 'src/site/pages/dashboard/account.vue') diff --git a/src/site/pages/dashboard/account.vue b/src/site/pages/dashboard/account.vue index 121b2b3..1c335e8 100644 --- a/src/site/pages/dashboard/account.vue +++ b/src/site/pages/dashboard/account.vue @@ -12,7 +12,7 @@ - @@ -20,7 +20,7 @@ - @@ -28,7 +28,7 @@ - @@ -36,7 +36,7 @@ - @@ -46,12 +46,17 @@ @click="changePassword">Change password - - + + +

+ +

+
@@ -65,51 +70,62 @@ -- cgit v1.2.3 From fd3f6de51a082dcd72c2ef557747e031ef7b9c4a Mon Sep 17 00:00:00 2001 From: Zephyrrus Date: Thu, 9 Jul 2020 02:24:40 +0300 Subject: refactor: refactor most of the admin pages to use the store instead of internal states --- src/site/pages/dashboard/account.vue | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) (limited to 'src/site/pages/dashboard/account.vue') diff --git a/src/site/pages/dashboard/account.vue b/src/site/pages/dashboard/account.vue index fb8b273..31ec8af 100644 --- a/src/site/pages/dashboard/account.vue +++ b/src/site/pages/dashboard/account.vue @@ -52,11 +52,11 @@
- +

- +

- +
@@ -154,6 +156,10 @@ export default { onConfirm: () => this.requestNewAPIKey(), }); }, + copyKey() { + this.$clipboard(this.apiKey); + this.$notifier.success('API key copied to clipboard'); + }, async requestNewAPIKey() { const response = await this.$store.dispatch('auth/requestAPIKey'); this.$buefy.toast.open(response.message); -- cgit v1.2.3