blob: 600e6534bc811000076633dbc8cec60df5ee9a96 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
import CharLimit from "../decorators/CharLimit";
import React from "react";
import {Labelled} from "../decorators/Labelled";
import {Input} from "../Common/Input";
export const Text = React.forwardRef(({label, id, readOnly, onChange, value, maxLength, autoFocus}, ref) => {
return (
<Labelled label={label} value={value}>
<Input
ref={ref}
name={label}
readOnly={readOnly}
placeholder="Title"
id={id}
type="text"
autoFocus={autoFocus}
autoComplete="off"
onChange={onChange}
value={value} />
<CharLimit
content={value}
maxLength={maxLength} />
</Labelled>
);
})
|