on master help sign in
fix: html5 input props updated for a11y
commit91176c2bdd4ec1759a048f7d694b29bff1b8056a authorMatt Condon (shrugs) <mattgcondon@gmail.com> dateTue 6 Aug 2019, 23:11 (7 years ago) parentc0c82dc
1 file changed+23−4
src/form/Inputs.js+23−4
src/form/Inputs.js+23−4
@@ -41,6 +41,9 @@ export function TicketInput({ name, ...rest }) {
4141 type="password"
4242 name={name}
4343 placeholder={PLACEHOLDER_TICKET}
44+ autoCapitalize="none"
45+ autoComplete="off"
46+ autoCorrect="off"
4447 accessory={
4548 touched && !active && error ? (
4649 <AccessoryIcon.Failure />
@@ -59,7 +62,14 @@ export function TicketInput({ name, ...rest }) {
5962
6063export function MnemonicInput({ ...rest }) {
6164 return (
62− <Input type="textarea" placeholder={PLACEHOLDER_MNEMONIC} mono {...rest} />
65+ <Input
66+ type="textarea"
67+ placeholder={PLACEHOLDER_MNEMONIC}
68+ autoCapitalize="none"
69+ autoComplete="off"
70+ mono
71+ {...rest}
72+ />
6373 );
6474}
6575
@@ -68,7 +78,9 @@ export function HdPathInput({ ...rest }) {
6878 <Input
6979 type="text"
7080 placeholder={PLACEHOLDER_HD_PATH}
81+ autoCapitalize="none"
7182 autoComplete="off"
83+ autoCorrect="off"
7284 {...rest}
7385 />
7486 );
@@ -79,7 +91,9 @@ export function PassphraseInput({ ...rest }) {
7991 <Input
8092 type="password"
8193 placeholder="Passphrase"
94+ autoCapitalize="none"
8295 autoComplete="off"
96+ autoCorrect="off"
8397 {...rest}
8498 />
8599 );
@@ -99,6 +113,9 @@ export function PointInput({ name, size = 4, ...rest }) {
99113 label="Point"
100114 name={name}
101115 placeholder={PLACEHOLDER_POINT}
116+ autoCapitalize="none"
117+ autoComplete="off"
118+ autoCorrect="off"
102119 accessory={
103120 value ? (
104121 <InputSigil
@@ -122,7 +139,9 @@ export function HexInput({ ...rest }) {
122139 <Input
123140 type="text"
124141 placeholder={PLACEHOLDER_PRIVATE_KEY}
142+ autoCapitalize="none"
125143 autoComplete="off"
144+ autoCorrect="off"
126145 mono
127146 {...rest}
128147 />
@@ -134,7 +153,8 @@ export function AddressInput({ ...rest }) {
134153 <Input
135154 type="text"
136155 placeholder={PLACEHOLDER_ADDRESS}
137− autoComplete="off"
156+ autoCapitalize="none"
157+ autoCorrect="off"
138158 mono
139159 {...rest}
140160 />
@@ -146,7 +166,6 @@ export function NumberInput({ ...rest }) {
146166 <Input
147167 type="number"
148168 label="Number"
149− autoComplete="off"
150169 config={{ format: convertToNumber }}
151170 {...rest}
152171 />
@@ -158,7 +177,7 @@ export function EmailInput({ ...rest }) {
158177 <Input
159178 type="email"
160179 placeholder={PLACEHOLDER_EMAIL}
161− autoComplete="off"
180+ autoCapitalize="none"
162181 {...rest}
163182 />
164183 );