Browse Source

Added clipboard copy actions.

We need to add designs for feedback on the copy action
kb/add-usage-guide
Matthew Aaron Raymer 2 years ago
parent
commit
c9919987ca
  1. 11
      src/views/AccountViewView.vue

11
src/views/AccountViewView.vue

@ -80,7 +80,9 @@
>
<span
><code>{{ address }}</code>
<button @click="copy(address)">
<fa icon="copy" class="text-slate-400 fa-fw ml-1"></fa>
</button>
</span>
<span>
<button
@ -100,7 +102,9 @@
<div class="text-sm text-slate-500 mb-1">
<span
><code>{{ publicHex }}</code>
<button @click="copy(publicHex)">
<fa icon="copy" class="text-slate-400 fa-fw ml-1"></fa>
</button>
</span>
</div>
@ -108,7 +112,9 @@
<div class="text-sm text-slate-500 mb-1">
<span
><code>{{ UPORT_ROOT_DERIVATION_PATH }}</code>
<button @click="copy(UPORT_ROOT_DERIVATION_PATH)">
<fa icon="copy" class="text-slate-400 fa-fw ml-1"></fa>
</button>
</span>
</div>
</div>
@ -167,11 +173,13 @@
<script lang="ts">
import { Options, Vue } from "vue-class-component";
import { useClipboard } from "@vueuse/core";
import { createIdentifier, deriveAddress, newIdentifier } from "../libs/crypto";
import { IIdentifier } from "@veramo/core";
import * as R from "ramda";
import { db } from "../db";
import { useAppStore } from "@/store/app";
import { ref } from "vue";
@Options({
components: {},
@ -182,6 +190,9 @@ export default class AccountViewView extends Vue {
privateHex = "";
publicHex = "";
UPORT_ROOT_DERIVATION_PATH = "";
source = ref("Hello");
copy = useClipboard().copy;
async created() {
const previousIdentifiers: Array<IIdentifier> = [];
const toLowercase = true;

Loading…
Cancel
Save