Skip to content

Commit 539cca5

Browse files
authored
Press enter is no longer allowed. (#2085)
Signed-off-by: bgravenorst <[email protected]>
1 parent e072510 commit 539cca5

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/components/ParserOpenRPC/InteractiveBox/templates/BaseInputTemplate.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,11 @@ export const BaseInputTemplate = ({
8383
type={isNumber ? 'number' : (schema.type as string)}
8484
pattern={schema.pattern}
8585
onChange={onInputChange}
86+
onKeyDown={e => {
87+
if (e.key === 'Enter') {
88+
e.preventDefault()
89+
}
90+
}}
8691
onFocus={() => {
8792
setIsFocused(true)
8893
}}

0 commit comments

Comments
 (0)