mirror of
https://github.com/mayswind/ezbookkeeping.git
synced 2026-05-17 00:12:11 +08:00
use pinia to replace vuex, code refactor
This commit is contained in:
@@ -25,6 +25,8 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { makeButtonCopyToClipboard, changeClipboardObjectText } from '@/lib/misc.js';
|
||||
|
||||
export default {
|
||||
props: [
|
||||
'title',
|
||||
@@ -52,7 +54,7 @@ export default {
|
||||
watch: {
|
||||
'information': function (newValue) {
|
||||
if (this.clipboardHolder) {
|
||||
this.$utilities.changeClipboardObjectText(this.clipboardHolder, newValue);
|
||||
changeClipboardObjectText(this.clipboardHolder, newValue);
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -71,7 +73,7 @@ export default {
|
||||
}
|
||||
|
||||
if (self.$refs.copyToClipboardIcon) {
|
||||
self.clipboardHolder = self.$utilities.makeButtonCopyToClipboard({
|
||||
self.clipboardHolder = makeButtonCopyToClipboard({
|
||||
el: '#copy-to-clipboard-icon',
|
||||
text: self.information,
|
||||
successCallback: function () {
|
||||
|
||||
Reference in New Issue
Block a user