ansys-solutions-dash-super-components 0.2.dev7__tar.gz → 0.2.dev9__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.
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/PKG-INFO +9 -11
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/README.rst +4 -4
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/pyproject.toml +36 -36
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/assets/dashAgGridComponentFunctions.js +21 -5
- ansys_solutions_dash_super_components-0.2.dev9/src/ansys/solutions/dash_super_components/assets/tree-styles.css +63 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/authenticator.py +20 -18
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/dual_input_range_slider.py +34 -10
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/folder_selector.py +477 -233
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/input_form.py +17 -9
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/input_row_array.py +51 -37
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/logs_supervisor.py +447 -142
- ansys_solutions_dash_super_components-0.2.dev9/src/ansys/solutions/dash_super_components/transaction_method_status_badge.py +476 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/transaction_supervisor.py +363 -115
- ansys_solutions_dash_super_components-0.2.dev9/src/ansys/solutions/dash_super_components/tree.py +979 -0
- ansys_solutions_dash_super_components-0.2.dev9/src/ansys/solutions/dash_super_components/utils/_common_colors.py +39 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/utils/config.py +29 -4
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/utils/logs_parser.py +128 -28
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/utils/status_badge_properties.py +8 -33
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/utils/svg_icons.py +108 -2
- ansys_solutions_dash_super_components-0.2.dev7/src/ansys/solutions/dash_super_components/transaction_method_status_badge.py +0 -366
- ansys_solutions_dash_super_components-0.2.dev7/src/ansys/solutions/dash_super_components/tree.py +0 -396
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/AUTHORS +0 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/LICENSE +0 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/__init__.py +0 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/assets/__init__.py +0 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/utils/__init__.py +0 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/utils/aio_ids.py +0 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/utils/api_requests.py +0 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/utils/assets_server.py +0 -0
- {ansys_solutions_dash_super_components-0.2.dev7 → ansys_solutions_dash_super_components-0.2.dev9}/src/ansys/solutions/dash_super_components/utils/path_validator.py +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: ansys-solutions-dash-super-components
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.dev9
|
|
4
4
|
Summary: A collection of pre-assembled, high-level Dash UI components built on Dash Mantine Components for simulation web applications.
|
|
5
|
-
License: Apache-2.0
|
|
5
|
+
License-Expression: Apache-2.0
|
|
6
6
|
License-File: AUTHORS
|
|
7
7
|
License-File: LICENSE
|
|
8
8
|
Keywords: Ansys Solutions
|
|
@@ -10,14 +10,12 @@ Author: ANSYS, Inc.
|
|
|
10
10
|
Author-email: pyansys.core@ansys.com
|
|
11
11
|
Maintainer: ANSYS, Inc.
|
|
12
12
|
Maintainer-email: pyansys.core@ansys.com
|
|
13
|
-
Requires-Python: >=3.
|
|
13
|
+
Requires-Python: >=3.11,<4
|
|
14
14
|
Classifier: Development Status :: 3 - Alpha
|
|
15
15
|
Classifier: Intended Audience :: Other Audience
|
|
16
16
|
Classifier: License :: OSI Approved :: Apache Software License
|
|
17
17
|
Classifier: Natural Language :: English
|
|
18
18
|
Classifier: Operating System :: OS Independent
|
|
19
|
-
Classifier: Programming Language :: Python :: 3
|
|
20
|
-
Classifier: Programming Language :: Python :: 3.10
|
|
21
19
|
Classifier: Programming Language :: Python :: 3.11
|
|
22
20
|
Classifier: Programming Language :: Python :: 3.12
|
|
23
21
|
Classifier: Programming Language :: Python :: 3.13
|
|
@@ -30,8 +28,8 @@ Requires-Dist: dash-iconify (>=0.1,<0.2)
|
|
|
30
28
|
Requires-Dist: dash-mantine-components (>=2.3.0,<3.0.0)
|
|
31
29
|
Requires-Dist: flask (>=2.2.0,<4.0.0)
|
|
32
30
|
Requires-Dist: pandas (>=2.2.2,<3.0.0)
|
|
33
|
-
Project-URL: Changelog, https://
|
|
34
|
-
Project-URL: Documentation, https://
|
|
31
|
+
Project-URL: Changelog, https://super-components-for-dash.docs.solutions.ansys.com/version/stable/changelog.html
|
|
32
|
+
Project-URL: Documentation, https://super-components-for-dash.docs.solutions.ansys.com/
|
|
35
33
|
Project-URL: Homepage, https://github.com/ansys/super-components-for-dash
|
|
36
34
|
Project-URL: Issues, https://github.com/ansys/super-components-for-dash/issues
|
|
37
35
|
Project-URL: Repository, https://github.com/ansys/super-components-for-dash
|
|
@@ -74,7 +72,7 @@ Documentation and issues
|
|
|
74
72
|
|
|
75
73
|
For full documentation, including the getting started guide, user guide, and API
|
|
76
74
|
reference, see the `Super Components for Dash documentation
|
|
77
|
-
<https://
|
|
75
|
+
<https://super-components-for-dash.docs.solutions.ansys.com/>`_.
|
|
78
76
|
In the upper right corner of the documentation's title bar, there is an option for
|
|
79
77
|
switching from viewing the documentation for the latest stable release to viewing
|
|
80
78
|
the documentation for the development version or previously released versions.
|
|
@@ -86,7 +84,7 @@ issues to report bugs and request new features.
|
|
|
86
84
|
Installation
|
|
87
85
|
------------
|
|
88
86
|
|
|
89
|
-
The ``ansys-solutions-dash-super-components`` package supports Python 3.
|
|
87
|
+
The ``ansys-solutions-dash-super-components`` package supports Python 3.11
|
|
90
88
|
through 3.14 on Windows and Linux.
|
|
91
89
|
|
|
92
90
|
Install the latest release from `PyPI
|
|
@@ -146,7 +144,7 @@ your browser.
|
|
|
146
144
|
|
|
147
145
|
For detailed instructions on how to get started with Super Components for Dash, see the
|
|
148
146
|
`getting started guide
|
|
149
|
-
<https://
|
|
147
|
+
<https://super-components-for-dash.docs.solutions.ansys.com/version/dev/getting-started.html>`_
|
|
150
148
|
in the documentation.
|
|
151
149
|
|
|
152
150
|
For more complex examples, see the `showcase application
|
|
@@ -157,7 +155,7 @@ Contributing
|
|
|
157
155
|
------------
|
|
158
156
|
|
|
159
157
|
Contributions are welcome! See the `contributing guide
|
|
160
|
-
<https://
|
|
158
|
+
<https://super-components-for-dash.docs.solutions.ansys.com/version/dev/contribute.html>`_ for
|
|
161
159
|
developer installation instructions and guidelines on how to contribute code,
|
|
162
160
|
documentation, and examples to this project.
|
|
163
161
|
|
|
@@ -35,7 +35,7 @@ Documentation and issues
|
|
|
35
35
|
|
|
36
36
|
For full documentation, including the getting started guide, user guide, and API
|
|
37
37
|
reference, see the `Super Components for Dash documentation
|
|
38
|
-
<https://
|
|
38
|
+
<https://super-components-for-dash.docs.solutions.ansys.com/>`_.
|
|
39
39
|
In the upper right corner of the documentation's title bar, there is an option for
|
|
40
40
|
switching from viewing the documentation for the latest stable release to viewing
|
|
41
41
|
the documentation for the development version or previously released versions.
|
|
@@ -47,7 +47,7 @@ issues to report bugs and request new features.
|
|
|
47
47
|
Installation
|
|
48
48
|
------------
|
|
49
49
|
|
|
50
|
-
The ``ansys-solutions-dash-super-components`` package supports Python 3.
|
|
50
|
+
The ``ansys-solutions-dash-super-components`` package supports Python 3.11
|
|
51
51
|
through 3.14 on Windows and Linux.
|
|
52
52
|
|
|
53
53
|
Install the latest release from `PyPI
|
|
@@ -107,7 +107,7 @@ your browser.
|
|
|
107
107
|
|
|
108
108
|
For detailed instructions on how to get started with Super Components for Dash, see the
|
|
109
109
|
`getting started guide
|
|
110
|
-
<https://
|
|
110
|
+
<https://super-components-for-dash.docs.solutions.ansys.com/version/dev/getting-started.html>`_
|
|
111
111
|
in the documentation.
|
|
112
112
|
|
|
113
113
|
For more complex examples, see the `showcase application
|
|
@@ -118,7 +118,7 @@ Contributing
|
|
|
118
118
|
------------
|
|
119
119
|
|
|
120
120
|
Contributions are welcome! See the `contributing guide
|
|
121
|
-
<https://
|
|
121
|
+
<https://super-components-for-dash.docs.solutions.ansys.com/version/dev/contribute.html>`_ for
|
|
122
122
|
developer installation instructions and guidelines on how to contribute code,
|
|
123
123
|
documentation, and examples to this project.
|
|
124
124
|
|
|
@@ -1,31 +1,40 @@
|
|
|
1
1
|
[build-system]
|
|
2
2
|
build-backend = "poetry.core.masonry.api"
|
|
3
|
-
|
|
4
|
-
# It will be read by the setup_environment.py script to install this version.
|
|
5
|
-
requires = [ "poetry-core>=2.0.0", "setuptools>=65.0" ]
|
|
3
|
+
requires = [ "poetry-core>=2.0.0" ]
|
|
6
4
|
|
|
7
|
-
[
|
|
5
|
+
[project]
|
|
8
6
|
name = "ansys-solutions-dash-super-components"
|
|
9
|
-
version = "0.2.
|
|
7
|
+
version = "0.2.dev9"
|
|
10
8
|
description = "A collection of pre-assembled, high-level Dash UI components built on Dash Mantine Components for simulation web applications."
|
|
11
9
|
license = "Apache-2.0"
|
|
12
|
-
authors = ["ANSYS, Inc.
|
|
13
|
-
maintainers = ["ANSYS, Inc.
|
|
10
|
+
authors = [{ name = "ANSYS, Inc.", email = "pyansys.core@ansys.com" }]
|
|
11
|
+
maintainers = [{ name = "ANSYS, Inc.", email = "pyansys.core@ansys.com" }]
|
|
14
12
|
readme = "README.rst"
|
|
15
13
|
keywords = [ "Ansys Solutions" ]
|
|
14
|
+
requires-python = ">=3.11,<4"
|
|
15
|
+
dynamic = ["dependencies"]
|
|
16
16
|
classifiers = [
|
|
17
17
|
"Development Status :: 3 - Alpha",
|
|
18
18
|
"Intended Audience :: Other Audience",
|
|
19
19
|
"License :: OSI Approved :: Apache Software License",
|
|
20
20
|
"Natural Language :: English",
|
|
21
21
|
"Operating System :: OS Independent",
|
|
22
|
-
"Programming Language :: Python :: 3.10",
|
|
23
22
|
"Programming Language :: Python :: 3.11",
|
|
24
23
|
"Programming Language :: Python :: 3.12",
|
|
25
24
|
"Programming Language :: Python :: 3.13",
|
|
26
25
|
"Programming Language :: Python :: 3.14",
|
|
27
26
|
"Topic :: Scientific/Engineering",
|
|
28
27
|
]
|
|
28
|
+
|
|
29
|
+
[project.urls]
|
|
30
|
+
Homepage = "https://github.com/ansys/super-components-for-dash"
|
|
31
|
+
Documentation = "https://super-components-for-dash.docs.solutions.ansys.com/"
|
|
32
|
+
Repository = "https://github.com/ansys/super-components-for-dash"
|
|
33
|
+
Issues = "https://github.com/ansys/super-components-for-dash/issues"
|
|
34
|
+
Changelog = "https://super-components-for-dash.docs.solutions.ansys.com/version/stable/changelog.html"
|
|
35
|
+
|
|
36
|
+
[tool.poetry]
|
|
37
|
+
requires-poetry = ">=2.3.2"
|
|
29
38
|
packages = [
|
|
30
39
|
{ include = "ansys/solutions/dash_super_components", from = "src" },
|
|
31
40
|
]
|
|
@@ -38,64 +47,57 @@ name = "PyPI"
|
|
|
38
47
|
priority = "primary"
|
|
39
48
|
|
|
40
49
|
[tool.poetry.dependencies]
|
|
41
|
-
python = ">=3.
|
|
50
|
+
python = ">=3.11, <4"
|
|
42
51
|
dash = ">=2.18.2, <3.4.0" # >= 3.4.0 incompatible with dash-extensions <2.0.5
|
|
43
52
|
dash-ag-grid = ">=31.2.0, <32.0.0" # 32.x introduces breaking changes for LogsSupervisor
|
|
44
53
|
dash-extensions = ">=1.0.20"
|
|
45
54
|
dash-iconify = "^0.1"
|
|
46
55
|
dash-mantine-components = ">=2.3.0, <3.0.0"
|
|
47
56
|
flask = ">=2.2.0, <4.0.0"
|
|
48
|
-
pandas = "
|
|
57
|
+
pandas = ">=2.2.2, <3.0.0"
|
|
49
58
|
|
|
50
59
|
[tool.poetry.group.tests]
|
|
51
60
|
optional = true
|
|
52
61
|
[tool.poetry.group.tests.dependencies]
|
|
53
|
-
coverage = "^7.
|
|
62
|
+
coverage = "^7.15.0"
|
|
54
63
|
mock = "^5.2.0"
|
|
55
|
-
pytest = "^9.
|
|
64
|
+
pytest = "^9.1.1"
|
|
56
65
|
pytest-cov = "^7.1.0"
|
|
57
66
|
pytest-html = "^4.2.0"
|
|
58
67
|
pytest-md = "^0.2.0"
|
|
59
68
|
pytest-xdist = "^3.8.0"
|
|
60
69
|
pytest-mock = "^3.15.1"
|
|
61
70
|
requests = ">=2.28"
|
|
62
|
-
tox = "^4.
|
|
71
|
+
tox = "^4.56.2"
|
|
63
72
|
|
|
64
73
|
[tool.poetry.group.doc]
|
|
65
74
|
optional = true
|
|
66
75
|
[tool.poetry.group.doc.dependencies]
|
|
67
|
-
ansys-sphinx-theme = "^1.
|
|
76
|
+
ansys-sphinx-theme = "^1.9.0"
|
|
68
77
|
linkchecker = "^10.6.0"
|
|
69
78
|
numpydoc = "^1.10.0"
|
|
70
|
-
sphinx = "
|
|
79
|
+
sphinx = "^9.0.0"
|
|
71
80
|
sphinx-copybutton = "^0.5.2"
|
|
72
|
-
sphinx-autobuild = "^
|
|
73
|
-
sphinx-design = "^0.
|
|
81
|
+
sphinx-autobuild = "^2025.8.25"
|
|
82
|
+
sphinx-design = "^0.7.0"
|
|
74
83
|
sphinx_code_tabs = "^0.5.5"
|
|
75
84
|
sphinxcontrib-video = "^0.4.2"
|
|
76
|
-
sphinx-gallery = "^0.
|
|
85
|
+
sphinx-gallery = "^0.21.0"
|
|
77
86
|
toml = "^0.10.2" # Needed by conf.py
|
|
78
87
|
|
|
79
88
|
[tool.poetry.group.style]
|
|
80
89
|
optional = true
|
|
81
90
|
[tool.poetry.group.style.dependencies]
|
|
82
|
-
codespell = "^2.4.
|
|
91
|
+
codespell = "^2.4.2"
|
|
83
92
|
numpydoc = "^1.10.0"
|
|
84
|
-
pyright = "^1.1.
|
|
85
|
-
ruff = "^0.15.
|
|
86
|
-
pre-commit = "^4.
|
|
93
|
+
pyright = "^1.1.411"
|
|
94
|
+
ruff = "^0.15.20"
|
|
95
|
+
pre-commit = "^4.6.0"
|
|
87
96
|
vale = ">=3.13.0"
|
|
88
|
-
docformatter = "^1.7.
|
|
89
|
-
|
|
90
|
-
[tool.poetry.urls]
|
|
91
|
-
Homepage = "https://github.com/ansys/super-components-for-dash"
|
|
92
|
-
Documentation = "https://dash-super-components.docs.solutions.ansys.com/"
|
|
93
|
-
Repository = "https://github.com/ansys/super-components-for-dash"
|
|
94
|
-
Issues = "https://github.com/ansys/super-components-for-dash/issues"
|
|
95
|
-
Changelog = "https://dash-super-components.docs.solutions.ansys.com/version/stable/changelog.html"
|
|
97
|
+
docformatter = "^1.7.8"
|
|
96
98
|
|
|
97
99
|
[tool.ruff]
|
|
98
|
-
target-version = "
|
|
100
|
+
target-version = "py311"
|
|
99
101
|
|
|
100
102
|
line-length = 100 # pyansys requirement
|
|
101
103
|
fix = true
|
|
@@ -152,6 +154,7 @@ skip = [
|
|
|
152
154
|
"./doc/source/examples", # auto-generated by sphinx-gallery
|
|
153
155
|
".github",
|
|
154
156
|
"*.toml",
|
|
157
|
+
"poetry.lock",
|
|
155
158
|
]
|
|
156
159
|
|
|
157
160
|
[tool.pytest.ini_options]
|
|
@@ -167,9 +170,10 @@ source = [ "ansys.solutions.dash_super_components" ] # pyansys requirement
|
|
|
167
170
|
|
|
168
171
|
[tool.coverage.report]
|
|
169
172
|
show_missing = true # pyansys requirement
|
|
170
|
-
omit = [ "*/pytest-of-*/pytest-*/popen-*/*", "/tmp*/*", "
|
|
173
|
+
omit = [ "*/pytest-of-*/pytest-*/popen-*/*", "/tmp*/*", "tests*" ]
|
|
171
174
|
|
|
172
175
|
[tool.pyright]
|
|
176
|
+
pythonVersion = "3.11"
|
|
173
177
|
extraPaths = [ "src" ]
|
|
174
178
|
include = [
|
|
175
179
|
"src",
|
|
@@ -179,7 +183,6 @@ exclude = [
|
|
|
179
183
|
"**/.*",
|
|
180
184
|
"examples/showcase_all",
|
|
181
185
|
".git",
|
|
182
|
-
"setup_environment.py",
|
|
183
186
|
]
|
|
184
187
|
venvPath = "."
|
|
185
188
|
venv = ".venv"
|
|
@@ -268,6 +271,3 @@ wrap-summaries = 100
|
|
|
268
271
|
wrap-descriptions = 100
|
|
269
272
|
recursive = "true"
|
|
270
273
|
pre-summary-newline = "true"
|
|
271
|
-
|
|
272
|
-
[build-system-requirements]
|
|
273
|
-
build-system-version = "2.3.2"
|
|
@@ -16,6 +16,14 @@
|
|
|
16
16
|
|
|
17
17
|
var dagcomponentfuncs = window.dashAgGridComponentFunctions = window.dashAgGridComponentFunctions || {};
|
|
18
18
|
|
|
19
|
+
const commonColors = {
|
|
20
|
+
MANTINE_BLUE: "var(--mantine-color-blue-6)",
|
|
21
|
+
MANTINE_ORANGE: "var(--mantine-color-orange-6)",
|
|
22
|
+
MANTINE_RED: "var(--mantine-color-red-6)",
|
|
23
|
+
MANTINE_PINK: "var(--mantine-color-pink-6)",
|
|
24
|
+
MANTINE_GRAPE: "var(--mantine-color-grape-6)",
|
|
25
|
+
};
|
|
26
|
+
|
|
19
27
|
dagcomponentfuncs.DMC_Badge_Level_Name = function (props) {
|
|
20
28
|
const {setData, data} = props;
|
|
21
29
|
|
|
@@ -28,31 +36,31 @@ dagcomponentfuncs.DMC_Badge_Level_Name = function (props) {
|
|
|
28
36
|
leftSection = React.createElement(window.dash_iconify.DashIconify, {
|
|
29
37
|
icon: "material-symbols:info",
|
|
30
38
|
});
|
|
31
|
-
color =
|
|
39
|
+
color = commonColors.MANTINE_BLUE;
|
|
32
40
|
}
|
|
33
41
|
else if (props.value == "WARNING") {
|
|
34
42
|
leftSection = React.createElement(window.dash_iconify.DashIconify, {
|
|
35
43
|
icon: "material-symbols:warning",
|
|
36
44
|
});
|
|
37
|
-
color =
|
|
45
|
+
color = commonColors.MANTINE_ORANGE;
|
|
38
46
|
}
|
|
39
47
|
else if (props.value == "ERROR") {
|
|
40
48
|
leftSection = React.createElement(window.dash_iconify.DashIconify, {
|
|
41
49
|
icon: "icon-park-solid:error",
|
|
42
50
|
});
|
|
43
|
-
color =
|
|
51
|
+
color = commonColors.MANTINE_RED;
|
|
44
52
|
}
|
|
45
53
|
else if (props.value == "CRITICAL") {
|
|
46
54
|
leftSection = React.createElement(window.dash_iconify.DashIconify, {
|
|
47
55
|
icon: "eos-icons:critical-bug-outlined",
|
|
48
56
|
});
|
|
49
|
-
color =
|
|
57
|
+
color = commonColors.MANTINE_PINK;
|
|
50
58
|
}
|
|
51
59
|
else if (props.value == "DEBUG") {
|
|
52
60
|
leftSection = React.createElement(window.dash_iconify.DashIconify, {
|
|
53
61
|
icon: "eos-icons:critical-bug",
|
|
54
62
|
});
|
|
55
|
-
color =
|
|
63
|
+
color = commonColors.MANTINE_GRAPE;
|
|
56
64
|
}
|
|
57
65
|
|
|
58
66
|
return React.createElement(
|
|
@@ -69,3 +77,11 @@ dagcomponentfuncs.DMC_Badge_Level_Name = function (props) {
|
|
|
69
77
|
props.value
|
|
70
78
|
);
|
|
71
79
|
};
|
|
80
|
+
|
|
81
|
+
dagcomponentfuncs.DMC_NoRows_Overlay = function (props) {
|
|
82
|
+
return React.createElement(
|
|
83
|
+
"div",
|
|
84
|
+
{className: "ag-overlay-no-rows-center", role: "status"},
|
|
85
|
+
props.message || "No rows to show."
|
|
86
|
+
);
|
|
87
|
+
};
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2026 ANSYS, Inc. and/or its affiliates.
|
|
3
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
*
|
|
5
|
+
*
|
|
6
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
+
* you may not use this file except in compliance with the License.
|
|
8
|
+
* You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/* Tree component theme support */
|
|
20
|
+
|
|
21
|
+
/* Ensure active item label/sections follow NavLink active color. */
|
|
22
|
+
.mantine-NavLink-root[data-active] .mantine-NavLink-label,
|
|
23
|
+
.mantine-NavLink-root[data-active] .mantine-NavLink-section {
|
|
24
|
+
color: inherit !important;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
/* Keep icon sections theme-aware by default; active items inherit active color. */
|
|
28
|
+
.mantine-NavLink-section {
|
|
29
|
+
color: var(--mantine-color-text);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/* Dedicated expand/collapse control used by Tree parent items. */
|
|
33
|
+
.tree-expander-control {
|
|
34
|
+
display: inline-flex;
|
|
35
|
+
align-items: center;
|
|
36
|
+
justify-content: center;
|
|
37
|
+
width: 24px;
|
|
38
|
+
height: 24px;
|
|
39
|
+
color: var(--mantine-color-dimmed);
|
|
40
|
+
user-select: none;
|
|
41
|
+
cursor: pointer;
|
|
42
|
+
border-radius: 6px;
|
|
43
|
+
background: transparent;
|
|
44
|
+
flex-shrink: 0;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.tree-expander-control::before {
|
|
48
|
+
content: "";
|
|
49
|
+
width: 8px;
|
|
50
|
+
height: 8px;
|
|
51
|
+
border-right: 2px solid currentColor;
|
|
52
|
+
border-bottom: 2px solid currentColor;
|
|
53
|
+
transform: rotate(-45deg);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.tree-expander-control.tree-expander-open::before {
|
|
57
|
+
transform: rotate(45deg);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.tree-expander-control:hover {
|
|
61
|
+
color: var(--mantine-color-text);
|
|
62
|
+
background: color-mix(in srgb, var(--mantine-color-text) 8%, transparent);
|
|
63
|
+
}
|
|
@@ -17,9 +17,12 @@
|
|
|
17
17
|
|
|
18
18
|
"""Provide a Dash component for crafting an authentication form."""
|
|
19
19
|
|
|
20
|
+
import copy
|
|
20
21
|
from typing import Any, TypeVar
|
|
21
22
|
import uuid
|
|
22
23
|
|
|
24
|
+
from ansys.solutions.dash_super_components.utils._common_colors import _CommonColors as CommonColors
|
|
25
|
+
|
|
23
26
|
try:
|
|
24
27
|
# dash-extensions < 2.0.5
|
|
25
28
|
from dash_extensions.enrich import _Wildcard # pyright: ignore[reportAttributeAccessIssue]
|
|
@@ -32,7 +35,10 @@ from dash_extensions.enrich import html
|
|
|
32
35
|
import dash_mantine_components as dmc
|
|
33
36
|
|
|
34
37
|
from ansys.solutions.dash_super_components.utils.aio_ids import AIOIds
|
|
35
|
-
from ansys.solutions.dash_super_components.utils.svg_icons import
|
|
38
|
+
from ansys.solutions.dash_super_components.utils.svg_icons import (
|
|
39
|
+
IconNames,
|
|
40
|
+
create_icon_span,
|
|
41
|
+
)
|
|
36
42
|
|
|
37
43
|
T = TypeVar("T", dmc.TextInput, dmc.PasswordInput, dmc.Button)
|
|
38
44
|
|
|
@@ -150,7 +156,7 @@ class Authenticator(html.Div):
|
|
|
150
156
|
items = []
|
|
151
157
|
|
|
152
158
|
self.items = items
|
|
153
|
-
self.
|
|
159
|
+
self._card_props = copy.deepcopy(card_props)
|
|
154
160
|
self.aio_id = aio_id if aio_id is not None else str(uuid.uuid4())
|
|
155
161
|
self._default_card_props = {
|
|
156
162
|
"withBorder": True,
|
|
@@ -161,10 +167,7 @@ class Authenticator(html.Div):
|
|
|
161
167
|
self._default_button_props = {
|
|
162
168
|
"children": "Connect",
|
|
163
169
|
"disabled": False,
|
|
164
|
-
"leftSection":
|
|
165
|
-
src=create_base64_svg_src(IconNames.HUGE_ROCKET, color="#adb5bd"),
|
|
166
|
-
),
|
|
167
|
-
"className": "mantine-button",
|
|
170
|
+
"leftSection": create_icon_span(IconNames.HUGE_ROCKET, size_px=16),
|
|
168
171
|
"style": {"width": "100%"},
|
|
169
172
|
}
|
|
170
173
|
self._default_text_input_props = {
|
|
@@ -179,8 +182,8 @@ class Authenticator(html.Div):
|
|
|
179
182
|
"placeholder": "Enter your password.",
|
|
180
183
|
"required": True,
|
|
181
184
|
"disabled": False,
|
|
182
|
-
"leftSection":
|
|
183
|
-
|
|
185
|
+
"leftSection": create_icon_span(
|
|
186
|
+
IconNames.MDI_SECURE, size_px=16, color=CommonColors.MANTINE_PLACEHOLDER
|
|
184
187
|
),
|
|
185
188
|
"style": {"width": "100%"},
|
|
186
189
|
}
|
|
@@ -194,8 +197,8 @@ class Authenticator(html.Div):
|
|
|
194
197
|
"label": "Username",
|
|
195
198
|
"placeholder": "Enter your username",
|
|
196
199
|
"required": True,
|
|
197
|
-
"leftSection":
|
|
198
|
-
|
|
200
|
+
"leftSection": create_icon_span(
|
|
201
|
+
IconNames.MDI_USER, size_px=16, color=CommonColors.MANTINE_PLACEHOLDER
|
|
199
202
|
),
|
|
200
203
|
},
|
|
201
204
|
},
|
|
@@ -206,8 +209,8 @@ class Authenticator(html.Div):
|
|
|
206
209
|
"label": "Password",
|
|
207
210
|
"placeholder": "Enter your password",
|
|
208
211
|
"required": True,
|
|
209
|
-
"leftSection":
|
|
210
|
-
|
|
212
|
+
"leftSection": create_icon_span(
|
|
213
|
+
IconNames.MDI_SECURE, size_px=16, color=CommonColors.MANTINE_PLACEHOLDER
|
|
211
214
|
),
|
|
212
215
|
},
|
|
213
216
|
},
|
|
@@ -216,22 +219,21 @@ class Authenticator(html.Div):
|
|
|
216
219
|
"id": "connect",
|
|
217
220
|
"properties": {
|
|
218
221
|
"children": "Connect",
|
|
219
|
-
"leftSection":
|
|
220
|
-
src=create_base64_svg_src(IconNames.HUGE_ROCKET, color="#adb5bd"),
|
|
221
|
-
),
|
|
222
|
+
"leftSection": create_icon_span(IconNames.HUGE_ROCKET, size_px=16),
|
|
222
223
|
},
|
|
224
|
+
"variant": "filled",
|
|
223
225
|
},
|
|
224
226
|
]
|
|
225
227
|
|
|
226
228
|
for prop, value in self._default_card_props.items():
|
|
227
|
-
if prop not in
|
|
228
|
-
|
|
229
|
+
if prop not in self._card_props:
|
|
230
|
+
self._card_props[prop] = value
|
|
229
231
|
|
|
230
232
|
super().__init__(
|
|
231
233
|
[
|
|
232
234
|
html.Div(
|
|
233
235
|
[
|
|
234
|
-
dmc.Card(self._generate_form(), **
|
|
236
|
+
dmc.Card(self._generate_form(), **self._card_props),
|
|
235
237
|
],
|
|
236
238
|
),
|
|
237
239
|
],
|
|
@@ -82,14 +82,14 @@ class DualInputRangeSlider(html.Div):
|
|
|
82
82
|
the component and will be overridden. Default style: ``{"width": "20%"}``.
|
|
83
83
|
lower_bound_input_props : dict, optional
|
|
84
84
|
Additional properties forwarded to the lower bound :class:`dmc.NumberInput`.
|
|
85
|
-
The keys ``min``, ``max``, ``step``, ``value``,
|
|
86
|
-
controlled by the component and will be overridden.
|
|
87
|
-
Default: label ``"Min"``, variant ``"filled"``, style ``{"width": "
|
|
85
|
+
The keys ``min``, ``max``, ``step``, ``value``, ``decimalScale``, ``debounce``,
|
|
86
|
+
and ``clampBehavior`` are controlled by the component and will be overridden.
|
|
87
|
+
Default: label ``"Min"``, variant ``"filled"``, style ``{"width": "15%"}``.
|
|
88
88
|
upper_bound_input_props : dict, optional
|
|
89
89
|
Additional properties forwarded to the upper bound :class:`dmc.NumberInput`.
|
|
90
|
-
The keys ``min``, ``max``, ``step``, ``value``,
|
|
91
|
-
controlled by the component and will be overridden.
|
|
92
|
-
Default: label ``"Max"``, variant ``"filled"``, style ``{"width": "
|
|
90
|
+
The keys ``min``, ``max``, ``step``, ``value``, ``decimalScale``, ``debounce``,
|
|
91
|
+
and ``clampBehavior`` are controlled by the component and will be overridden.
|
|
92
|
+
Default: label ``"Max"``, variant ``"filled"``, style ``{"width": "15%"}``.
|
|
93
93
|
aio_id : str, optional
|
|
94
94
|
Unique identifier for this component instance. A UUID is generated when
|
|
95
95
|
not provided.
|
|
@@ -225,6 +225,8 @@ class DualInputRangeSlider(html.Div):
|
|
|
225
225
|
"max": self._max,
|
|
226
226
|
"step": self._step,
|
|
227
227
|
"decimalScale": self._decimal_scale,
|
|
228
|
+
"debounce": True, # Avoids unnecessary callback calls while typing
|
|
229
|
+
"clampBehavior": "strict", # Prevents user from entering values outside of [min, max]
|
|
228
230
|
}
|
|
229
231
|
self._populate_with_defaults(self._lower_bound_input_props, default_lower_bound_input_props)
|
|
230
232
|
self._enforce_controlled_props(
|
|
@@ -243,6 +245,8 @@ class DualInputRangeSlider(html.Div):
|
|
|
243
245
|
"max": self._max,
|
|
244
246
|
"step": self._step,
|
|
245
247
|
"decimalScale": self._decimal_scale,
|
|
248
|
+
"debounce": True, # Avoids unnecessary callback calls while typing
|
|
249
|
+
"clampBehavior": "strict", # Prevents user from entering values outside of [min, max]
|
|
246
250
|
}
|
|
247
251
|
self._populate_with_defaults(self._upper_bound_input_props, default_upper_bound_input_props)
|
|
248
252
|
self._enforce_controlled_props(
|
|
@@ -369,8 +373,8 @@ class DualInputRangeSlider(html.Div):
|
|
|
369
373
|
)
|
|
370
374
|
def update_slider_or_inputs_values(
|
|
371
375
|
slider_value: list[float | int],
|
|
372
|
-
lower_bound_value: float | int,
|
|
373
|
-
upper_bound_value: float | int,
|
|
376
|
+
lower_bound_value: float | int | str,
|
|
377
|
+
upper_bound_value: float | int | str,
|
|
374
378
|
slider_id: dict[str, Any],
|
|
375
379
|
lower_bound_id: dict[str, Any],
|
|
376
380
|
upper_bound_id: dict[str, Any],
|
|
@@ -386,12 +390,32 @@ class DualInputRangeSlider(html.Div):
|
|
|
386
390
|
elif trigger_id == lower_bound_id:
|
|
387
391
|
# make sure that minRange=0 is respected (i.e., lower bound <= upper bound)
|
|
388
392
|
# if not respected, shift upper bound (comparable to RangeSlider behavior)
|
|
393
|
+
lower_bound_value_update = no_update
|
|
394
|
+
try:
|
|
395
|
+
lower_bound_value = float(lower_bound_value)
|
|
396
|
+
except (ValueError, TypeError):
|
|
397
|
+
lower_bound_value = slider_value[0]
|
|
398
|
+
lower_bound_value_update = slider_value[0]
|
|
389
399
|
valid_upper_bound_value = max(lower_bound_value, slider_value[1])
|
|
390
|
-
return
|
|
400
|
+
return (
|
|
401
|
+
[lower_bound_value, valid_upper_bound_value],
|
|
402
|
+
lower_bound_value_update,
|
|
403
|
+
valid_upper_bound_value,
|
|
404
|
+
)
|
|
391
405
|
elif trigger_id == upper_bound_id:
|
|
392
406
|
# make sure that minRange=0 is respected (i.e., lower bound <= upper bound)
|
|
393
407
|
# if not respected, shift lower bound (comparable to RangeSlider behavior)
|
|
408
|
+
upper_bound_value_update = no_update
|
|
409
|
+
try:
|
|
410
|
+
upper_bound_value = float(upper_bound_value)
|
|
411
|
+
except (ValueError, TypeError):
|
|
412
|
+
upper_bound_value = slider_value[1]
|
|
413
|
+
upper_bound_value_update = slider_value[1]
|
|
394
414
|
valid_lower_bound_value = min(upper_bound_value, slider_value[0])
|
|
395
|
-
return
|
|
415
|
+
return (
|
|
416
|
+
[valid_lower_bound_value, upper_bound_value],
|
|
417
|
+
valid_lower_bound_value,
|
|
418
|
+
upper_bound_value_update,
|
|
419
|
+
)
|
|
396
420
|
else:
|
|
397
421
|
raise PreventUpdate
|