$input
Creates an <input> element wrapper for JSX-style composition.
Implementation
El $input({
String? key,
String? className,
String? id,
String? type,
String? name,
String? value,
String? placeholder,
bool? disabled,
bool? readOnly,
bool? required,
Map<String, dynamic>? style,
Map<String, dynamic>? spread,
void Function(SyntheticEvent)? onChange,
void Function(SyntheticEvent)? onInput,
void Function(SyntheticFocusEvent)? onFocus,
void Function(SyntheticFocusEvent)? onBlur,
void Function(SyntheticKeyboardEvent)? onKeyDown,
void Function(SyntheticKeyboardEvent)? onKeyUp,
}) {
final p = _buildJsxProps(
key: key,
className: className,
id: id,
style: style,
spread: spread,
onChange: onChange,
onInput: onInput,
onFocus: onFocus,
onBlur: onBlur,
onKeyDown: onKeyDown,
onKeyUp: onKeyUp,
);
if (type != null) p['type'] = type;
if (name != null) p['name'] = name;
if (value != null) p['value'] = value;
if (placeholder != null) p['placeholder'] = placeholder;
if (disabled != null) p['disabled'] = disabled;
if (readOnly != null) p['readOnly'] = readOnly;
if (required != null) p['required'] = required;
return El(InputElement.fromJS(_createJsxElement('input', p)));
}