Skip to content

Commit

Permalink
feat: add copy funcitonality
Browse files Browse the repository at this point in the history
  • Loading branch information
AlejandroAkbal committed Feb 25, 2021
1 parent 20c526a commit 7ef4838
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions pages/premium/booru.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
<td class="text-sm" @click="removeCustomBooru(booru)">
{{ booru.domain }}
</td>
<td class="text-sm" @click="copyBooruToForm(booru)">
{{ booru.type }}
</td>
<td class="text-sm">{{ booru.nsfw }}</td>
<td class="text-sm">{{ booru.config !== null }}</td>
</tr>
Expand Down Expand Up @@ -193,6 +196,15 @@ export default {
this.activeBooruManager({ operation: 'reset' })
},
copyBooruToForm(booru) {
// Clone as a weird fix so Vuex does not crash
this.formBooru = {
domain: booru.domain,
type: booru.type,
nsfw: booru.nsfw,
config: JSON.stringify(booru.config),
}
},
},
}
</script>

0 comments on commit 7ef4838

Please sign in to comment.