Skip to content

Commit 1f6ae65

Browse files
committed
refactor: 支持拷贝粘贴
1 parent 44a66f7 commit 1f6ae65

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/BootstrapBlazor/Components/Input/OtpInput.razor.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ export function init(id) {
1414
input.value = [...el.querySelectorAll('.bb-opt-item')].map(input => input.value).join('');
1515
});
1616
EventHandler.on(el, 'keydown', '.bb-opt-item', e => {
17+
if (e.ctrlKey) {
18+
return;
19+
}
20+
1721
const isNumber = e.target.getAttribute('type') === 'number';
1822
if (skipKeys.indexOf(e.key) > -1) {
1923

0 commit comments

Comments
 (0)