djust-theming | Demo Home Components | Gallery Storybook Editor Diff

Switch

python component Core UI 7 params
EXAMPLES 2
python
switch(name='notifications', label='Enable notifications', checked=True)
python
switch(name='dark_mode', label='Dark mode', checked=False)
USAGE
python
from djust_components.components.switch import Switch

component = Switch(name='',
    checked=False,
    label=None,
    disabled=False,
    action=None,
    custom_class='',
    kwargs)
html = component.render()
PARAMETERS 7
NameTypeDefault
name <class 'str'> ''
checked <class 'bool'> False
label typing.Optional[str] None
disabled <class 'bool'> False
action typing.Optional[str] None
custom_class <class 'str'> ''
kwargs