fix(vcSelect):Maintain keyboard events when using a custom element. (#8321)

main
pengpeng 2025-08-27 15:07:36 +08:00 committed by GitHub
parent 35c1ad9c80
commit 04f6ba33c7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 6 additions and 1 deletions

View File

@ -840,6 +840,7 @@ export default defineComponent({
customizeRawInputElement,
{
ref: selectorDomRef,
tabindex: 0,
},
false,
true,
@ -877,7 +878,11 @@ export default defineComponent({
// Render raw
if (customizeRawInputElement) {
renderNode = selectorNode;
renderNode = (
<div onKeydown={onInternalKeyDown} onKeyup={onInternalKeyUp}>
{selectorNode}
</div>
);
} else {
renderNode = (
<div