CustomInput
Custom HTML input widget for creating custom interactive components.
Signature
def CustomInput(
html_body: str,
key: str = None,
required: bool = True,
label: str = '',
html_head: str = '',
height: int = 200,
css: str = '',
js: str = '',
full_width: bool = False,
change_event: Callable = None,
errors: Union[List[str], str] = None
)
Parameters
Name | Description | Type | Default |
---|---|---|---|
html_body (required) | HTML content for the body of the custom component. | str | None |
key | Identifier for the widget, defaults to hash of html_body if not provided. | str | None |
required | Whether the input must be filled before proceeding. | bool | True |
label | Text label displayed above the component. | str | '' |
html_head | HTML content for the head section. | str | '' |
height | Height of the component in pixels. | int | 200 |
css | CSS styles for the component. | str | '' |
js | JavaScript code for the component. | str | '' |
full_width | Whether the component should take up the full width of its container. | bool | False |
change_event | Function to process value changes before storing. | Callable | None |
errors | Pre-defined validation error messages to display. | Union[List[str], str] | None |