/
alt3rmann
/
label-studio
Обзор
Документация
Войти
/
alt3rmann
/
label-studio
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
develop
web/apps/labelstudio/src/components/Form/Elements/Input/Input.jsx
24 строки
768 B
Nick Skriabin
feat: DIA-1888: [FE] JWT auth token (#7049)
13 фев 2025, 16:05
Не верифицирован
13 фев 2025, 16:05
981139e
Код
Авторство
О чём код?
import { cn } from "../../../../utils/bem"; import { FormField } from "../../FormField"; import { default as Label } from "../Label/Label"; import "./Input.scss"; const Input = ({ label, description, className, validate, required, skip, labelProps, ghost, ...props }) => { const classList = [cn("input-ls").mod({ ghost }), className].join(" ").trim(); const input = ( <FormField label={label} name={props.name} validate={validate} required={required} skip={skip} {...props}> {(ref) => <input {...props} ref={ref} className={classList} />} </FormField> ); return label ? ( <Label {...(labelProps ?? {})} description={description} text={label} required={required}> {input} </Label> ) : ( input ); }; export default Input;