Skip to content

Commit c3df822

Browse files
authored
Avoid widening "type" prop of TextInputDOMProps (#3623)
Improve autocomplete in IDE
1 parent 85ac035 commit c3df822

File tree

1 file changed

+1
-1
lines changed
  • packages/@react-types/shared/src

1 file changed

+1
-1
lines changed

packages/@react-types/shared/src/dom.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ export interface TextInputDOMProps extends DOMProps, TextInputDOMEvents {
157157
/**
158158
* The type of input to render. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#htmlattrdeftype).
159159
*/
160-
type?: 'text' | 'search' | 'url' | 'tel' | 'email' | 'password' | string,
160+
type?: 'text' | 'search' | 'url' | 'tel' | 'email' | 'password' | (string & {}),
161161

162162
/**
163163
* Hints at the type of data that might be entered by the user while editing the element or its contents. See [MDN](https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute).

0 commit comments

Comments
 (0)