dash-flows 0.0.2__tar.gz → 0.0.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. dash_flows-0.0.4/MANIFEST.in +11 -0
  2. {dash_flows-0.0.2 → dash_flows-0.0.4}/PKG-INFO +16 -10
  3. dash_flows-0.0.4/README.md +98 -0
  4. dash_flows-0.0.4/dash_flows/AnimatedCircleNode.py +55 -0
  5. dash_flows-0.0.4/dash_flows/AnimatedNodeEdge.py +80 -0
  6. dash_flows-0.0.4/dash_flows/DashFlows.py +168 -0
  7. dash_flows-0.0.4/dash_flows/DevTools.py +80 -0
  8. dash_flows-0.0.4/dash_flows/ResizableNode.py +96 -0
  9. dash_flows-0.0.4/dash_flows/__init__.py +87 -0
  10. dash_flows-0.0.4/dash_flows/_imports_.py +13 -0
  11. dash_flows-0.0.2/dash_flow/dash_flow.min.js → dash_flows-0.0.4/dash_flows/dash_flows.min.js +3 -3
  12. dash_flows-0.0.4/dash_flows/dash_flows.min.js.map +1 -0
  13. dash_flows-0.0.4/dash_flows/metadata.json +1 -0
  14. dash_flows-0.0.4/dash_flows/package-info.json +65 -0
  15. {dash_flows-0.0.2 → dash_flows-0.0.4}/dash_flows.egg-info/PKG-INFO +17 -11
  16. dash_flows-0.0.4/dash_flows.egg-info/SOURCES.txt +22 -0
  17. dash_flows-0.0.4/package.json +65 -0
  18. {dash_flows-0.0.2 → dash_flows-0.0.4}/setup.py +1 -1
  19. dash_flows-0.0.4/tests/test_handle.py +19 -0
  20. dash_flows-0.0.2/MANIFEST.in +0 -11
  21. dash_flows-0.0.2/README.md +0 -169
  22. dash_flows-0.0.2/dash_flow/dash_flow.min.js.map +0 -1
  23. dash_flows-0.0.2/dash_flow/metadata.json +0 -1
  24. dash_flows-0.0.2/dash_flow/package-info.json +0 -64
  25. dash_flows-0.0.2/dash_flows.egg-info/SOURCES.txt +0 -14
  26. dash_flows-0.0.2/package.json +0 -64
  27. {dash_flows-0.0.2 → dash_flows-0.0.4}/LICENSE +0 -0
  28. {dash_flows-0.0.2 → dash_flows-0.0.4}/dash_flows.egg-info/dependency_links.txt +0 -0
  29. {dash_flows-0.0.2 → dash_flows-0.0.4}/dash_flows.egg-info/top_level.txt +0 -0
  30. {dash_flows-0.0.2 → dash_flows-0.0.4}/setup.cfg +0 -0
  31. {dash_flows-0.0.2 → dash_flows-0.0.4}/tests/test_usage.py +0 -0
@@ -0,0 +1,11 @@
1
+ include dash_flows/dash_flows.min.js
2
+ include dash_flows/dash_flows.min.js.map
3
+ include dash_flows/async-*.js
4
+ include dash_flows/async-*.js.map
5
+ include dash_flows/*-shared.js
6
+ include dash_flows/*-shared.js.map
7
+ include dash_flows/metadata.json
8
+ include dash_flows/package-info.json
9
+ include README.md
10
+ include LICENSE
11
+ include package.json
@@ -1,18 +1,24 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.2
2
2
  Name: dash_flows
3
- Version: 0.0.2
4
- Summary: A Dash component library for creating interactive node-based interfaces with React Flow
3
+ Version: 0.0.4
4
+ Summary: React Flow for the Plotly Dash framework with edittable handles.
5
5
  Author: Pip Install Python <pipinstallpython@gmail.com>
6
6
  License: MIT
7
7
  Classifier: Framework :: Dash
8
8
  Description-Content-Type: text/markdown
9
9
  License-File: LICENSE
10
+ Dynamic: author
11
+ Dynamic: classifier
12
+ Dynamic: description
13
+ Dynamic: description-content-type
14
+ Dynamic: license
15
+ Dynamic: summary
10
16
 
11
- # Dash Flow
17
+ # Dash Flows
12
18
 
13
- Dash Flow is a Dash component library.
19
+ Dash Flows is a Dash component library.
14
20
 
15
- A Dash component library for creating interactive node-based interfaces with React Flow
21
+ React Flow for the Plotly Dash framework.
16
22
 
17
23
  Get started with:
18
24
  1. Install Dash and its dependencies: https://dash.plotly.com/installation
@@ -47,7 +53,7 @@ If you have selected install_dependencies during the prompt, you can skip this p
47
53
  $ pip install -r tests/requirements.txt
48
54
  ```
49
55
 
50
- ### Write your component code in `src/lib/components/DashFlow.react.js`.
56
+ ### Write your component code in `src/lib/components/DashFlows.react.js`.
51
57
 
52
58
  - The demo app is in `src/demo` and you will import your example component code into your demo app.
53
59
  - Test your code in a Python environment:
@@ -63,9 +69,9 @@ If you have selected install_dependencies during the prompt, you can skip this p
63
69
  - A sample test is available in `tests/test_usage.py`, it will load `usage.py` and you can then automate interactions with selenium.
64
70
  - Run the tests with `$ pytest tests`.
65
71
  - The Dash team uses these types of integration tests extensively. Browse the Dash component code on GitHub for more examples of testing (e.g. https://github.com/plotly/dash-core-components)
66
- - Add custom styles to your component by putting your custom CSS files into your distribution folder (`dash_flow`).
72
+ - Add custom styles to your component by putting your custom CSS files into your distribution folder (`dash_flows`).
67
73
  - Make sure that they are referenced in `MANIFEST.in` so that they get properly included when you're ready to publish your component.
68
- - Make sure the stylesheets are added to the `_css_dist` dict in `dash_flow/__init__.py` so dash will serve them automatically when the component suite is requested.
74
+ - Make sure the stylesheets are added to the `_css_dist` dict in `dash_flows/__init__.py` so dash will serve them automatically when the component suite is requested.
69
75
  - [Review your code](./review_checklist.md)
70
76
 
71
77
  ### Create a production build and publish:
@@ -84,7 +90,7 @@ If you have selected install_dependencies during the prompt, you can skip this p
84
90
 
85
91
  3. Test your tarball by copying it into a new environment and installing it locally:
86
92
  ```
87
- $ pip install dash_flow-0.0.1.tar.gz
93
+ $ pip install dash_flows-0.0.3.tar.gz
88
94
  ```
89
95
 
90
96
  4. If it works, then you can publish the component to NPM and PyPI:
@@ -0,0 +1,98 @@
1
+ # Dash Flows
2
+
3
+ Dash Flows is a Dash component library.
4
+
5
+ React Flow for the Plotly Dash framework.
6
+
7
+ Get started with:
8
+ 1. Install Dash and its dependencies: https://dash.plotly.com/installation
9
+ 2. Run `python usage.py`
10
+ 3. Visit http://localhost:8050 in your web browser
11
+
12
+ ## Contributing
13
+
14
+ See [CONTRIBUTING.md](./CONTRIBUTING.md)
15
+
16
+ ### Install dependencies
17
+
18
+ If you have selected install_dependencies during the prompt, you can skip this part.
19
+
20
+ 1. Install npm packages
21
+ ```
22
+ $ npm install
23
+ ```
24
+ 2. Create a virtual env and activate.
25
+ ```
26
+ $ virtualenv venv
27
+ $ . venv/bin/activate
28
+ ```
29
+ _Note: venv\Scripts\activate for windows_
30
+
31
+ 3. Install python packages required to build components.
32
+ ```
33
+ $ pip install -r requirements.txt
34
+ ```
35
+ 4. Install the python packages for testing (optional)
36
+ ```
37
+ $ pip install -r tests/requirements.txt
38
+ ```
39
+
40
+ ### Write your component code in `src/lib/components/DashFlows.react.js`.
41
+
42
+ - The demo app is in `src/demo` and you will import your example component code into your demo app.
43
+ - Test your code in a Python environment:
44
+ 1. Build your code
45
+ ```
46
+ $ npm run build
47
+ ```
48
+ 2. Run and modify the `usage.py` sample dash app:
49
+ ```
50
+ $ python usage.py
51
+ ```
52
+ - Write tests for your component.
53
+ - A sample test is available in `tests/test_usage.py`, it will load `usage.py` and you can then automate interactions with selenium.
54
+ - Run the tests with `$ pytest tests`.
55
+ - The Dash team uses these types of integration tests extensively. Browse the Dash component code on GitHub for more examples of testing (e.g. https://github.com/plotly/dash-core-components)
56
+ - Add custom styles to your component by putting your custom CSS files into your distribution folder (`dash_flows`).
57
+ - Make sure that they are referenced in `MANIFEST.in` so that they get properly included when you're ready to publish your component.
58
+ - Make sure the stylesheets are added to the `_css_dist` dict in `dash_flows/__init__.py` so dash will serve them automatically when the component suite is requested.
59
+ - [Review your code](./review_checklist.md)
60
+
61
+ ### Create a production build and publish:
62
+
63
+ 1. Build your code:
64
+ ```
65
+ $ npm run build
66
+ ```
67
+ 2. Create a Python distribution
68
+ ```
69
+ $ python setup.py sdist bdist_wheel
70
+ ```
71
+ This will create source and wheel distribution in the generated the `dist/` folder.
72
+ See [PyPA](https://packaging.python.org/guides/distributing-packages-using-setuptools/#packaging-your-project)
73
+ for more information.
74
+
75
+ 3. Test your tarball by copying it into a new environment and installing it locally:
76
+ ```
77
+ $ pip install dash_flows-0.0.3.tar.gz
78
+ ```
79
+
80
+ 4. If it works, then you can publish the component to NPM and PyPI:
81
+ 1. Publish on PyPI
82
+ ```
83
+ $ twine upload dist/*
84
+ ```
85
+ 2. Cleanup the dist folder (optional)
86
+ ```
87
+ $ rm -rf dist
88
+ ```
89
+ 3. Publish on NPM (Optional if chosen False in `publish_on_npm`)
90
+ ```
91
+ $ npm publish
92
+ ```
93
+ _Publishing your component to NPM will make the JavaScript bundles available on the unpkg CDN. By default, Dash serves the component library's CSS and JS locally, but if you choose to publish the package to NPM you can set `serve_locally` to `False` and you may see faster load times._
94
+
95
+ 5. Share your component with the community! https://community.plotly.com/c/dash
96
+ 1. Publish this repository to GitHub
97
+ 2. Tag your GitHub repository with the plotly-dash tag so that it appears here: https://github.com/topics/plotly-dash
98
+ 3. Create a post in the Dash community forum: https://community.plotly.com/c/dash
@@ -0,0 +1,55 @@
1
+ # AUTO GENERATED FILE - DO NOT EDIT
2
+
3
+ import typing # noqa: F401
4
+ import numbers # noqa: F401
5
+ from typing_extensions import TypedDict, NotRequired, Literal # noqa: F401
6
+ from dash.development.base_component import Component, _explicitize_args
7
+ try:
8
+ from dash.development.base_component import ComponentType # noqa: F401
9
+ except ImportError:
10
+ ComponentType = typing.TypeVar("ComponentType", bound=Component)
11
+
12
+
13
+ class AnimatedCircleNode(Component):
14
+ """An AnimatedCircleNode component.
15
+
16
+
17
+ Keyword arguments:
18
+
19
+ - data (dict; required)
20
+
21
+ `data` is a dict with keys:
22
+
23
+ - label (boolean | number | string | dict | list; optional)"""
24
+ _children_props = []
25
+ _base_nodes = ['children']
26
+ _namespace = 'dash_flows'
27
+ _type = 'AnimatedCircleNode'
28
+ Data = TypedDict(
29
+ "Data",
30
+ {
31
+ "label": NotRequired[typing.Any]
32
+ }
33
+ )
34
+
35
+ @_explicitize_args
36
+ def __init__(
37
+ self,
38
+ data: typing.Optional["Data"] = None,
39
+ **kwargs
40
+ ):
41
+ self._prop_names = ['data']
42
+ self._valid_wildcard_attributes = []
43
+ self.available_properties = ['data']
44
+ self.available_wildcard_properties = []
45
+ _explicit_args = kwargs.pop('_explicit_args')
46
+ _locals = locals()
47
+ _locals.update(kwargs) # For wildcard attrs and excess named props
48
+ args = {k: _locals[k] for k in _explicit_args}
49
+
50
+ for k in ['data']:
51
+ if k not in args:
52
+ raise TypeError(
53
+ 'Required argument `' + k + '` was not specified.')
54
+
55
+ super(AnimatedCircleNode, self).__init__(**args)
@@ -0,0 +1,80 @@
1
+ # AUTO GENERATED FILE - DO NOT EDIT
2
+
3
+ import typing # noqa: F401
4
+ import numbers # noqa: F401
5
+ from typing_extensions import TypedDict, NotRequired, Literal # noqa: F401
6
+ from dash.development.base_component import Component, _explicitize_args
7
+ try:
8
+ from dash.development.base_component import ComponentType # noqa: F401
9
+ except ImportError:
10
+ ComponentType = typing.TypeVar("ComponentType", bound=Component)
11
+
12
+
13
+ class AnimatedNodeEdge(Component):
14
+ """An AnimatedNodeEdge component.
15
+ AnimatedNodeEdge is a custom edge component that animates a node along its path.
16
+
17
+ Keyword arguments:
18
+
19
+ - id (string; optional):
20
+ The ID of the edge.
21
+
22
+ - data (dict; default { animatedNode: '' }):
23
+ Edge data containing the ID of the node to animate.
24
+
25
+ `data` is a dict with keys:
26
+
27
+ - animatedNode (string; optional):
28
+ ID of the node to animate along this edge.
29
+
30
+ - sourcePosition (string; optional):
31
+ Position of the source handle.
32
+
33
+ - sourceX (number; optional):
34
+ X coordinate of the source node.
35
+
36
+ - sourceY (number; optional):
37
+ Y coordinate of the source node.
38
+
39
+ - targetPosition (string; optional):
40
+ Position of the target handle.
41
+
42
+ - targetX (number; optional):
43
+ X coordinate of the target node.
44
+
45
+ - targetY (number; optional):
46
+ Y coordinate of the target node."""
47
+ _children_props = []
48
+ _base_nodes = ['children']
49
+ _namespace = 'dash_flows'
50
+ _type = 'AnimatedNodeEdge'
51
+ Data = TypedDict(
52
+ "Data",
53
+ {
54
+ "animatedNode": NotRequired[str]
55
+ }
56
+ )
57
+
58
+ @_explicitize_args
59
+ def __init__(
60
+ self,
61
+ id: typing.Optional[typing.Union[str, dict]] = None,
62
+ data: typing.Optional["Data"] = None,
63
+ sourceX: typing.Optional[typing.Union[int, float, numbers.Number]] = None,
64
+ sourceY: typing.Optional[typing.Union[int, float, numbers.Number]] = None,
65
+ targetX: typing.Optional[typing.Union[int, float, numbers.Number]] = None,
66
+ targetY: typing.Optional[typing.Union[int, float, numbers.Number]] = None,
67
+ sourcePosition: typing.Optional[str] = None,
68
+ targetPosition: typing.Optional[str] = None,
69
+ **kwargs
70
+ ):
71
+ self._prop_names = ['id', 'data', 'sourcePosition', 'sourceX', 'sourceY', 'targetPosition', 'targetX', 'targetY']
72
+ self._valid_wildcard_attributes = []
73
+ self.available_properties = ['id', 'data', 'sourcePosition', 'sourceX', 'sourceY', 'targetPosition', 'targetX', 'targetY']
74
+ self.available_wildcard_properties = []
75
+ _explicit_args = kwargs.pop('_explicit_args')
76
+ _locals = locals()
77
+ _locals.update(kwargs) # For wildcard attrs and excess named props
78
+ args = {k: _locals[k] for k in _explicit_args}
79
+
80
+ super(AnimatedNodeEdge, self).__init__(**args)
@@ -0,0 +1,168 @@
1
+ # AUTO GENERATED FILE - DO NOT EDIT
2
+
3
+ import typing # noqa: F401
4
+ import numbers # noqa: F401
5
+ from typing_extensions import TypedDict, NotRequired, Literal # noqa: F401
6
+ from dash.development.base_component import Component, _explicitize_args
7
+ try:
8
+ from dash.development.base_component import ComponentType # noqa: F401
9
+ except ImportError:
10
+ ComponentType = typing.TypeVar("ComponentType", bound=Component)
11
+
12
+
13
+ class DashFlows(Component):
14
+ """A DashFlows component.
15
+
16
+
17
+ Keyword arguments:
18
+
19
+ - id (string; optional):
20
+ The ID used to identify this component in Dash callbacks.
21
+
22
+ - className (string; default ''):
23
+ CSS class name for the container div.
24
+
25
+ - edges (list of dicts; optional):
26
+ Array of edges defining connections between nodes.
27
+
28
+ `edges` is a list of dicts with keys:
29
+
30
+ - id (string; required)
31
+
32
+ - source (string; required)
33
+
34
+ - target (string; required)
35
+
36
+ - type (string; optional)
37
+
38
+ - data (dict; optional)
39
+
40
+ - style (dict; optional)
41
+
42
+ - markerEnd (dict; optional)
43
+
44
+ `markerEnd` is a dict with keys:
45
+
46
+ - type (string; required)
47
+
48
+ - color (string; optional)
49
+
50
+ - size (number; optional)
51
+
52
+ - elementsSelectable (boolean; default True):
53
+ Enable/disable the ability to select elements.
54
+
55
+ - layoutOptions (string; optional):
56
+ Layout options for arranging nodes using the ELK layout engine.
57
+
58
+ - nodes (list of dicts; optional):
59
+ Array of nodes to display in the flow.
60
+
61
+ `nodes` is a list of dicts with keys:
62
+
63
+ - id (string; required)
64
+
65
+ - type (string; optional)
66
+
67
+ - data (dict; required)
68
+
69
+ - position (dict; required)
70
+
71
+ `position` is a dict with keys:
72
+
73
+ - x (number; required)
74
+
75
+ - y (number; required)
76
+
77
+ - style (dict; optional)
78
+
79
+ - nodesConnectable (boolean; default True):
80
+ Enable/disable the ability to make new connections between nodes.
81
+
82
+ - nodesDraggable (boolean; default True):
83
+ Enable/disable node dragging behavior.
84
+
85
+ - showBackground (boolean; default True):
86
+ Show/hide the background pattern.
87
+
88
+ - showControls (boolean; default True):
89
+ Show/hide the control panel.
90
+
91
+ - showDevTools (boolean; default False):
92
+ Show/hide the developer tools panel.
93
+
94
+ - showMiniMap (boolean; default True):
95
+ Show/hide the minimap navigation component."""
96
+ _children_props = []
97
+ _base_nodes = ['children']
98
+ _namespace = 'dash_flows'
99
+ _type = 'DashFlows'
100
+ NodesPosition = TypedDict(
101
+ "NodesPosition",
102
+ {
103
+ "x": typing.Union[int, float, numbers.Number],
104
+ "y": typing.Union[int, float, numbers.Number]
105
+ }
106
+ )
107
+
108
+ Nodes = TypedDict(
109
+ "Nodes",
110
+ {
111
+ "id": str,
112
+ "type": NotRequired[str],
113
+ "data": dict,
114
+ "position": "NodesPosition",
115
+ "style": NotRequired[dict]
116
+ }
117
+ )
118
+
119
+ EdgesMarkerEnd = TypedDict(
120
+ "EdgesMarkerEnd",
121
+ {
122
+ "type": str,
123
+ "color": NotRequired[str],
124
+ "size": NotRequired[typing.Union[int, float, numbers.Number]]
125
+ }
126
+ )
127
+
128
+ Edges = TypedDict(
129
+ "Edges",
130
+ {
131
+ "id": str,
132
+ "source": str,
133
+ "target": str,
134
+ "type": NotRequired[str],
135
+ "data": NotRequired[dict],
136
+ "style": NotRequired[dict],
137
+ "markerEnd": NotRequired["EdgesMarkerEnd"]
138
+ }
139
+ )
140
+
141
+ @_explicitize_args
142
+ def __init__(
143
+ self,
144
+ id: typing.Optional[typing.Union[str, dict]] = None,
145
+ nodesDraggable: typing.Optional[bool] = None,
146
+ nodesConnectable: typing.Optional[bool] = None,
147
+ elementsSelectable: typing.Optional[bool] = None,
148
+ showMiniMap: typing.Optional[bool] = None,
149
+ showControls: typing.Optional[bool] = None,
150
+ showBackground: typing.Optional[bool] = None,
151
+ nodes: typing.Optional[typing.Sequence["Nodes"]] = None,
152
+ edges: typing.Optional[typing.Sequence["Edges"]] = None,
153
+ style: typing.Optional[typing.Any] = None,
154
+ className: typing.Optional[str] = None,
155
+ showDevTools: typing.Optional[bool] = None,
156
+ layoutOptions: typing.Optional[str] = None,
157
+ **kwargs
158
+ ):
159
+ self._prop_names = ['id', 'className', 'edges', 'elementsSelectable', 'layoutOptions', 'nodes', 'nodesConnectable', 'nodesDraggable', 'showBackground', 'showControls', 'showDevTools', 'showMiniMap', 'style']
160
+ self._valid_wildcard_attributes = []
161
+ self.available_properties = ['id', 'className', 'edges', 'elementsSelectable', 'layoutOptions', 'nodes', 'nodesConnectable', 'nodesDraggable', 'showBackground', 'showControls', 'showDevTools', 'showMiniMap', 'style']
162
+ self.available_wildcard_properties = []
163
+ _explicit_args = kwargs.pop('_explicit_args')
164
+ _locals = locals()
165
+ _locals.update(kwargs) # For wildcard attrs and excess named props
166
+ args = {k: _locals[k] for k in _explicit_args}
167
+
168
+ super(DashFlows, self).__init__(**args)
@@ -0,0 +1,80 @@
1
+ # AUTO GENERATED FILE - DO NOT EDIT
2
+
3
+ import typing # noqa: F401
4
+ import numbers # noqa: F401
5
+ from typing_extensions import TypedDict, NotRequired, Literal # noqa: F401
6
+ from dash.development.base_component import Component, _explicitize_args
7
+ try:
8
+ from dash.development.base_component import ComponentType # noqa: F401
9
+ except ImportError:
10
+ ComponentType = typing.TypeVar("ComponentType", bound=Component)
11
+
12
+
13
+ class DevTools(Component):
14
+ """A DevTools component.
15
+ DevTools component for displaying debug information about the flow
16
+
17
+ Keyword arguments:
18
+
19
+ - nodes (list of dicts; required):
20
+ Array of nodes to display information about.
21
+
22
+ `nodes` is a list of dicts with keys:
23
+
24
+ - id (string; required)
25
+
26
+ - type (string; optional)
27
+
28
+ - viewport (dict; required):
29
+ Current viewport information including position and zoom level.
30
+
31
+ `viewport` is a dict with keys:
32
+
33
+ - x (number; required)
34
+
35
+ - y (number; required)
36
+
37
+ - zoom (number; required)"""
38
+ _children_props = []
39
+ _base_nodes = ['children']
40
+ _namespace = 'dash_flows'
41
+ _type = 'DevTools'
42
+ Viewport = TypedDict(
43
+ "Viewport",
44
+ {
45
+ "x": typing.Union[int, float, numbers.Number],
46
+ "y": typing.Union[int, float, numbers.Number],
47
+ "zoom": typing.Union[int, float, numbers.Number]
48
+ }
49
+ )
50
+
51
+ Nodes = TypedDict(
52
+ "Nodes",
53
+ {
54
+ "id": str,
55
+ "type": NotRequired[str]
56
+ }
57
+ )
58
+
59
+ @_explicitize_args
60
+ def __init__(
61
+ self,
62
+ viewport: typing.Optional["Viewport"] = None,
63
+ nodes: typing.Optional[typing.Sequence["Nodes"]] = None,
64
+ **kwargs
65
+ ):
66
+ self._prop_names = ['nodes', 'viewport']
67
+ self._valid_wildcard_attributes = []
68
+ self.available_properties = ['nodes', 'viewport']
69
+ self.available_wildcard_properties = []
70
+ _explicit_args = kwargs.pop('_explicit_args')
71
+ _locals = locals()
72
+ _locals.update(kwargs) # For wildcard attrs and excess named props
73
+ args = {k: _locals[k] for k in _explicit_args}
74
+
75
+ for k in ['nodes', 'viewport']:
76
+ if k not in args:
77
+ raise TypeError(
78
+ 'Required argument `' + k + '` was not specified.')
79
+
80
+ super(DevTools, self).__init__(**args)
@@ -0,0 +1,96 @@
1
+ # AUTO GENERATED FILE - DO NOT EDIT
2
+
3
+ import typing # noqa: F401
4
+ import numbers # noqa: F401
5
+ from typing_extensions import TypedDict, NotRequired, Literal # noqa: F401
6
+ from dash.development.base_component import Component, _explicitize_args
7
+ try:
8
+ from dash.development.base_component import ComponentType # noqa: F401
9
+ except ImportError:
10
+ ComponentType = typing.TypeVar("ComponentType", bound=Component)
11
+
12
+
13
+ class ResizableNode(Component):
14
+ """A ResizableNode component.
15
+
16
+
17
+ Keyword arguments:
18
+
19
+ - data (dict; required)
20
+
21
+ `data` is a dict with keys:
22
+
23
+ - label (boolean | number | string | dict | list; optional)
24
+
25
+ - handles (list of dicts; required)
26
+
27
+ `handles` is a list of dicts with keys:
28
+
29
+ - id (string; required)
30
+
31
+ - type (string; required)
32
+
33
+ - position (string; required)
34
+
35
+ - style (dict; optional)
36
+
37
+ - isConnectable (boolean; optional)
38
+
39
+ - isConnectableStart (boolean; optional)
40
+
41
+ - isConnectableEnd (boolean; optional)
42
+
43
+ - onConnect (optional)
44
+
45
+ - isValidConnection (optional)
46
+
47
+ - selected (boolean; default False)"""
48
+ _children_props = []
49
+ _base_nodes = ['children']
50
+ _namespace = 'dash_flows'
51
+ _type = 'ResizableNode'
52
+ DataHandles = TypedDict(
53
+ "DataHandles",
54
+ {
55
+ "id": str,
56
+ "type": str,
57
+ "position": str,
58
+ "style": NotRequired[dict],
59
+ "isConnectable": NotRequired[bool],
60
+ "isConnectableStart": NotRequired[bool],
61
+ "isConnectableEnd": NotRequired[bool],
62
+ "onConnect": NotRequired[typing.Any],
63
+ "isValidConnection": NotRequired[typing.Any]
64
+ }
65
+ )
66
+
67
+ Data = TypedDict(
68
+ "Data",
69
+ {
70
+ "label": NotRequired[typing.Any],
71
+ "handles": typing.Sequence["DataHandles"]
72
+ }
73
+ )
74
+
75
+ @_explicitize_args
76
+ def __init__(
77
+ self,
78
+ data: typing.Optional["Data"] = None,
79
+ selected: typing.Optional[bool] = None,
80
+ **kwargs
81
+ ):
82
+ self._prop_names = ['data', 'selected']
83
+ self._valid_wildcard_attributes = []
84
+ self.available_properties = ['data', 'selected']
85
+ self.available_wildcard_properties = []
86
+ _explicit_args = kwargs.pop('_explicit_args')
87
+ _locals = locals()
88
+ _locals.update(kwargs) # For wildcard attrs and excess named props
89
+ args = {k: _locals[k] for k in _explicit_args}
90
+
91
+ for k in ['data']:
92
+ if k not in args:
93
+ raise TypeError(
94
+ 'Required argument `' + k + '` was not specified.')
95
+
96
+ super(ResizableNode, self).__init__(**args)