|
1 |
| -# AUTO GENERATED FILE - DO NOT EDIT |
2 |
| - |
3 |
| -from dash.development.base_component import Component, _explicitize_args |
4 |
| - |
5 |
| - |
6 |
| -class Checklist(Component): |
7 |
| - """A Checklist component. |
8 |
| -Checklist is a component that encapsulates several checkboxes. |
9 |
| -The values and labels of the checklist is specified in the `options` |
10 |
| -property and the checked items are specified with the `values` property. |
11 |
| -Each checkbox is rendered as an input with a surrounding label. |
12 |
| -
|
13 |
| -Keyword arguments: |
14 |
| -- id (string; optional) |
15 |
| -- options (list; optional): An array of options |
16 |
| -- values (list; optional): The currently selected value |
17 |
| -- className (string; optional): The class of the container (div) |
18 |
| -- style (dict; optional): The style of the container (div) |
19 |
| -- inputStyle (dict; optional): The style of the <input> checkbox element |
20 |
| -- inputClassName (string; optional): The class of the <input> checkbox element |
21 |
| -- labelStyle (dict; optional): The style of the <label> that wraps the checkbox input |
22 |
| - and the option's label |
23 |
| -- labelClassName (string; optional): The class of the <label> that wraps the checkbox input |
24 |
| - and the option's label |
25 |
| -
|
26 |
| -Available events: 'change'""" |
27 |
| - @_explicitize_args |
28 |
| - def __init__(self, id=Component.UNDEFINED, options=Component.UNDEFINED, values=Component.UNDEFINED, className=Component.UNDEFINED, style=Component.UNDEFINED, inputStyle=Component.UNDEFINED, inputClassName=Component.UNDEFINED, labelStyle=Component.UNDEFINED, labelClassName=Component.UNDEFINED, **kwargs): |
29 |
| - self._prop_names = ['id', 'options', 'values', 'className', 'style', 'inputStyle', 'inputClassName', 'labelStyle', 'labelClassName'] |
30 |
| - self._type = 'Checklist' |
31 |
| - self._namespace = 'dash_core_components' |
32 |
| - self._valid_wildcard_attributes = [] |
33 |
| - self.available_events = ['change'] |
34 |
| - self.available_properties = ['id', 'options', 'values', 'className', 'style', 'inputStyle', 'inputClassName', 'labelStyle', 'labelClassName'] |
35 |
| - self.available_wildcard_properties = [] |
36 |
| - |
37 |
| - _explicit_args = kwargs.pop('_explicit_args') |
38 |
| - _locals = locals() |
39 |
| - _locals.update(kwargs) # For wildcard attrs |
40 |
| - args = {k: _locals[k] for k in _explicit_args if k != 'children'} |
41 |
| - |
42 |
| - for k in []: |
43 |
| - if k not in args: |
44 |
| - raise TypeError( |
45 |
| - 'Required argument `' + k + '` was not specified.') |
46 |
| - super(Checklist, self).__init__(**args) |
47 |
| - |
48 |
| - def __repr__(self): |
49 |
| - if(any(getattr(self, c, None) is not None |
50 |
| - for c in self._prop_names |
51 |
| - if c is not self._prop_names[0]) |
52 |
| - or any(getattr(self, c, None) is not None |
53 |
| - for c in self.__dict__.keys() |
54 |
| - if any(c.startswith(wc_attr) |
55 |
| - for wc_attr in self._valid_wildcard_attributes))): |
56 |
| - props_string = ', '.join([c+'='+repr(getattr(self, c, None)) |
57 |
| - for c in self._prop_names |
58 |
| - if getattr(self, c, None) is not None]) |
59 |
| - wilds_string = ', '.join([c+'='+repr(getattr(self, c, None)) |
60 |
| - for c in self.__dict__.keys() |
61 |
| - if any([c.startswith(wc_attr) |
62 |
| - for wc_attr in |
63 |
| - self._valid_wildcard_attributes])]) |
64 |
| - return ('Checklist(' + props_string + |
65 |
| - (', ' + wilds_string if wilds_string != '' else '') + ')') |
66 |
| - else: |
67 |
| - return ( |
68 |
| - 'Checklist(' + |
69 |
| - repr(getattr(self, self._prop_names[0], None)) + ')') |
| 1 | +# AUTO GENERATED FILE - DO NOT EDIT |
| 2 | + |
| 3 | +from dash.development.base_component import Component, _explicitize_args |
| 4 | + |
| 5 | + |
| 6 | +class Checklist(Component): |
| 7 | + """A Checklist component. |
| 8 | +Checklist is a component that encapsulates several checkboxes. |
| 9 | +The values and labels of the checklist is specified in the `options` |
| 10 | +property and the checked items are specified with the `values` property. |
| 11 | +Each checkbox is rendered as an input with a surrounding label. |
| 12 | +
|
| 13 | +Keyword arguments: |
| 14 | +- id (string; optional) |
| 15 | +- options (list; optional): An array of options |
| 16 | +- values (list; optional): The currently selected value |
| 17 | +- className (string; optional): The class of the container (div) |
| 18 | +- style (dict; optional): The style of the container (div) |
| 19 | +- inputStyle (dict; optional): The style of the <input> checkbox element |
| 20 | +- inputClassName (string; optional): The class of the <input> checkbox element |
| 21 | +- labelStyle (dict; optional): The style of the <label> that wraps the checkbox input |
| 22 | + and the option's label |
| 23 | +- labelClassName (string; optional): The class of the <label> that wraps the checkbox input |
| 24 | + and the option's label |
| 25 | +
|
| 26 | +Available events: 'change'""" |
| 27 | + @_explicitize_args |
| 28 | + def __init__(self, id=Component.UNDEFINED, options=Component.UNDEFINED, values=Component.UNDEFINED, className=Component.UNDEFINED, style=Component.UNDEFINED, inputStyle=Component.UNDEFINED, inputClassName=Component.UNDEFINED, labelStyle=Component.UNDEFINED, labelClassName=Component.UNDEFINED, **kwargs): |
| 29 | + self._prop_names = ['id', 'options', 'values', 'className', 'style', 'inputStyle', 'inputClassName', 'labelStyle', 'labelClassName'] |
| 30 | + self._type = 'Checklist' |
| 31 | + self._namespace = 'dash_core_components' |
| 32 | + self._valid_wildcard_attributes = [] |
| 33 | + self.available_events = ['change'] |
| 34 | + self.available_properties = ['id', 'options', 'values', 'className', 'style', 'inputStyle', 'inputClassName', 'labelStyle', 'labelClassName'] |
| 35 | + self.available_wildcard_properties = [] |
| 36 | + |
| 37 | + _explicit_args = kwargs.pop('_explicit_args') |
| 38 | + _locals = locals() |
| 39 | + _locals.update(kwargs) # For wildcard attrs |
| 40 | + args = {k: _locals[k] for k in _explicit_args if k != 'children'} |
| 41 | + |
| 42 | + for k in []: |
| 43 | + if k not in args: |
| 44 | + raise TypeError( |
| 45 | + 'Required argument `' + k + '` was not specified.') |
| 46 | + super(Checklist, self).__init__(**args) |
| 47 | + |
| 48 | + def __repr__(self): |
| 49 | + if(any(getattr(self, c, None) is not None |
| 50 | + for c in self._prop_names |
| 51 | + if c is not self._prop_names[0]) |
| 52 | + or any(getattr(self, c, None) is not None |
| 53 | + for c in self.__dict__.keys() |
| 54 | + if any(c.startswith(wc_attr) |
| 55 | + for wc_attr in self._valid_wildcard_attributes))): |
| 56 | + props_string = ', '.join([c+'='+repr(getattr(self, c, None)) |
| 57 | + for c in self._prop_names |
| 58 | + if getattr(self, c, None) is not None]) |
| 59 | + wilds_string = ', '.join([c+'='+repr(getattr(self, c, None)) |
| 60 | + for c in self.__dict__.keys() |
| 61 | + if any([c.startswith(wc_attr) |
| 62 | + for wc_attr in |
| 63 | + self._valid_wildcard_attributes])]) |
| 64 | + return ('Checklist(' + props_string + |
| 65 | + (', ' + wilds_string if wilds_string != '' else '') + ')') |
| 66 | + else: |
| 67 | + return ( |
| 68 | + 'Checklist(' + |
| 69 | + repr(getattr(self, self._prop_names[0], None)) + ')') |
0 commit comments