Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion templates/boltcards/display.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<q-card-section>
<q-list>
<q-item v-for="item in cardInfo">
<q-item-section>
<q-item-section contenteditable="true" @paste="handlePaste($event, item.value)">
<q-item-label lines="1">${item.label}</q-item-label>
<q-item-label caption>${card[item.value]}</q-item-label>
</q-item-section>
Expand Down Expand Up @@ -139,6 +139,16 @@
position: position || 'bottom'
})
})
},
handlePaste(event, value) {
event.preventDefault();
const clipboardData = event.clipboardData || window.clipboardData;
const pastedText = clipboardData.getData('text');
this.card[value] = pastedText; // Update the field with pasted content
this.$q.notify({
message: 'Pasted from clipboard!',
position: 'bottom'
});
}
}
})
Expand Down