@inventreedb/ui 0.11.2 → 1.4.0
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.
- package/CHANGELOG.md +33 -0
- package/dist/.vite/manifest.json +92 -5
- package/dist/components/Boundary.js +16 -7
- package/dist/components/Boundary.js.map +1 -1
- package/dist/components/InvenTreeTable.js +4 -3
- package/dist/components/InvenTreeTable.js.map +1 -1
- package/dist/components/RowActions.js +3 -2
- package/dist/components/RowActions.js.map +1 -1
- package/dist/components/StylishText.d.ts +6 -0
- package/dist/components/StylishText.js +36 -0
- package/dist/components/StylishText.js.map +1 -0
- package/dist/components/nav/DetailDrawer.css.d.ts +1 -0
- package/dist/components/nav/DetailDrawer.css.js +6 -0
- package/dist/components/nav/DetailDrawer.css.js.map +1 -0
- package/dist/components/nav/DetailDrawer.d.ts +22 -0
- package/dist/components/nav/DetailDrawer.js +66 -0
- package/dist/components/nav/DetailDrawer.js.map +1 -0
- package/dist/enums/ApiEndpoints.d.ts +1 -0
- package/dist/enums/ApiEndpoints.js +1 -0
- package/dist/enums/ApiEndpoints.js.map +1 -1
- package/dist/enums/ModelInformation.js +1 -0
- package/dist/enums/ModelInformation.js.map +1 -1
- package/dist/enums/ModelType.d.ts +9 -0
- package/dist/enums/ModelType.js.map +1 -1
- package/dist/enums/Roles.d.ts +1 -0
- package/dist/enums/Roles.js +1 -0
- package/dist/enums/Roles.js.map +1 -1
- package/dist/functions/Events.js +4 -3
- package/dist/functions/Events.js.map +1 -1
- package/dist/functions/Navigation.js +5 -2
- package/dist/functions/Navigation.js.map +1 -1
- package/dist/functions/Plugins.js +4 -2
- package/dist/functions/Plugins.js.map +1 -1
- package/dist/hooks/MonitorBackgroundTask.js +10 -8
- package/dist/hooks/MonitorBackgroundTask.js.map +1 -1
- package/dist/hooks/MonitorDataOutput.js +4 -3
- package/dist/hooks/MonitorDataOutput.js.map +1 -1
- package/dist/hooks/UseFilterSet.js +7 -6
- package/dist/hooks/UseFilterSet.js.map +1 -1
- package/dist/hooks/UseTable.js +1 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -1
- package/dist/node_modules/@mantine/hooks/esm/use-debounced-value/use-debounced-value.js +40 -15
- package/dist/node_modules/@mantine/hooks/esm/use-debounced-value/use-debounced-value.js.map +1 -1
- package/dist/node_modules/@mantine/hooks/esm/use-document-visibility/use-document-visibility.js +1 -1
- package/dist/node_modules/@mantine/hooks/esm/use-document-visibility/use-document-visibility.js.map +1 -1
- package/dist/node_modules/@mantine/hooks/esm/use-local-storage/create-storage.js +57 -62
- package/dist/node_modules/@mantine/hooks/esm/use-local-storage/create-storage.js.map +1 -1
- package/dist/node_modules/@mantine/hooks/esm/use-local-storage/use-local-storage.js.map +1 -1
- package/dist/node_modules/@mantine/hooks/esm/use-window-event/use-window-event.js +5 -3
- package/dist/node_modules/@mantine/hooks/esm/use-window-event/use-window-event.js.map +1 -1
- package/dist/node_modules/@mantine/hooks/esm/utils/random-id/random-id.js.map +1 -1
- package/dist/node_modules/@remix-run/router/dist/router.js +458 -0
- package/dist/node_modules/@remix-run/router/dist/router.js.map +1 -0
- package/dist/node_modules/@sentry/browser/build/npm/esm/prod/report-dialog.js +2 -2
- package/dist/node_modules/@sentry/browser/build/npm/esm/prod/report-dialog.js.map +1 -1
- package/dist/node_modules/@sentry/core/build/esm/scope.js +6 -5
- package/dist/node_modules/@sentry/core/build/esm/scope.js.map +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/chain-and-copy-promiselike.js +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/chain-and-copy-promiselike.js.map +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/is.js +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/is.js.map +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/misc.js +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/misc.js.map +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/randomSafeContext.js +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/randomSafeContext.js.map +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/time.js +1 -1
- package/dist/node_modules/@sentry/core/build/esm/utils/time.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/createReactComponent.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/createReactComponent.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/defaultAttributes.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/defaultAttributes.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconAdjustments.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconAdjustments.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowRight.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowRight.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconCheck.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconCheck.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js +14 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js.map +1 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconCircleCheck.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconCircleCheck.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconCircleX.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconCircleX.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconCopy.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconCopy.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconDots.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconDots.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconEdit.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconEdit.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconExclamationCircle.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconExclamationCircle.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconPlus.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconPlus.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconSearch.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconSearch.js.map +1 -1
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconTrash.js +6 -0
- package/dist/node_modules/@tabler/icons-react/dist/esm/icons/IconTrash.js.map +1 -1
- package/dist/node_modules/@tanstack/query-core/build/modern/focusManager.js +31 -20
- package/dist/node_modules/@tanstack/query-core/build/modern/focusManager.js.map +1 -1
- package/dist/node_modules/@tanstack/query-core/build/modern/onlineManager.js +27 -17
- package/dist/node_modules/@tanstack/query-core/build/modern/onlineManager.js.map +1 -1
- package/dist/node_modules/@tanstack/query-core/build/modern/queryObserver.js +179 -177
- package/dist/node_modules/@tanstack/query-core/build/modern/queryObserver.js.map +1 -1
- package/dist/node_modules/@tanstack/query-core/build/modern/timeoutManager.js +31 -21
- package/dist/node_modules/@tanstack/query-core/build/modern/timeoutManager.js.map +1 -1
- package/dist/node_modules/@tanstack/react-query/build/modern/errorBoundaryUtils.js +1 -1
- package/dist/node_modules/@tanstack/react-query/build/modern/errorBoundaryUtils.js.map +1 -1
- package/dist/node_modules/@tanstack/react-query/build/modern/suspense.js +1 -1
- package/dist/node_modules/@tanstack/react-query/build/modern/suspense.js.map +1 -1
- package/dist/node_modules/@tanstack/react-query/build/modern/useBaseQuery.js +7 -4
- package/dist/node_modules/@tanstack/react-query/build/modern/useBaseQuery.js.map +1 -1
- package/dist/node_modules/react/cjs/react-jsx-runtime.development.js +10 -1
- package/dist/node_modules/react/cjs/react-jsx-runtime.development.js.map +1 -1
- package/dist/node_modules/react/cjs/react-jsx-runtime.production.js +10 -1
- package/dist/node_modules/react/cjs/react-jsx-runtime.production.js.map +1 -1
- package/dist/node_modules/react-router/dist/index.js +714 -0
- package/dist/node_modules/react-router/dist/index.js.map +1 -0
- package/dist/node_modules/react-router-dom/dist/index.js +536 -0
- package/dist/node_modules/react-router-dom/dist/index.js.map +1 -0
- package/dist/node_modules/zustand/esm/react/shallow.js +13 -0
- package/dist/node_modules/zustand/esm/react/shallow.js.map +1 -0
- package/dist/node_modules/zustand/esm/vanilla/shallow.js +57 -0
- package/dist/node_modules/zustand/esm/vanilla/shallow.js.map +1 -0
- package/dist/states/LocalLibState.d.ts +17 -0
- package/dist/states/LocalLibState.js +16 -0
- package/dist/states/LocalLibState.js.map +1 -0
- package/dist/states/StoredTableState.js +2 -1
- package/dist/states/StoredTableState.js.map +1 -1
- package/dist/states/types.d.ts +3 -0
- package/dist/types/Forms.d.ts +13 -6
- package/dist/types/Panel.d.ts +26 -0
- package/dist/types/Plugins.d.ts +14 -2
- package/dist/types/Plugins.js +2 -2
- package/dist/types/Plugins.js.map +1 -1
- package/dist/types/Rendering.d.ts +53 -0
- package/dist/types/Tables.d.ts +5 -1
- package/dist/ui.css +4 -0
- package/lib/components/Boundary.tsx +6 -3
- package/lib/components/RowActions.tsx +2 -2
- package/lib/components/StylishText.tsx +46 -0
- package/lib/components/nav/DetailDrawer.css.ts +6 -0
- package/lib/components/nav/DetailDrawer.tsx +108 -0
- package/lib/enums/ApiEndpoints.tsx +1 -0
- package/lib/enums/ModelInformation.tsx +1 -0
- package/lib/enums/ModelType.tsx +13 -0
- package/lib/enums/Roles.tsx +1 -0
- package/lib/hooks/UseFilterSet.tsx +8 -8
- package/lib/index.ts +16 -0
- package/lib/states/LocalLibState.tsx +23 -0
- package/lib/states/types.tsx +7 -0
- package/lib/types/Forms.tsx +13 -6
- package/lib/types/Panel.tsx +30 -0
- package/lib/types/Plugins.tsx +20 -1
- package/lib/types/Rendering.tsx +60 -0
- package/lib/types/Tables.tsx +5 -1
- package/package.json +20 -17
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,39 @@
|
|
|
2
2
|
|
|
3
3
|
This file contains historical changelog information for the InvenTree UI components library.
|
|
4
4
|
|
|
5
|
+
### 1.4.0 - May 2026
|
|
6
|
+
|
|
7
|
+
#### Version Numbering
|
|
8
|
+
|
|
9
|
+
This update brings the version numbering in-line with the core InvenTree server version, which is currently at `1.4.0`. This versioning scheme will be maintained going forward, with the UI components library version matching the core server version.
|
|
10
|
+
|
|
11
|
+
Thus, version `1.4.x` of the UI components library will be compatible with version `1.4.x` of the InvenTree server, and so on.
|
|
12
|
+
|
|
13
|
+
#### Mantine Library Update
|
|
14
|
+
|
|
15
|
+
The underlying Mantine library has been updated from version `8.x` to version `9.x`. This update may introduce breaking changes for plugins that rely on the InvenTree UI components library, as the Mantine library is a core dependency. Plugin developers should test their plugins against this new version to ensure compatibility.
|
|
16
|
+
|
|
17
|
+
#### New Components
|
|
18
|
+
|
|
19
|
+
Adds additional functions in the plugin context related to form rendering and API invocation:
|
|
20
|
+
- `useInstance`
|
|
21
|
+
- `renderRemoteInstance`
|
|
22
|
+
- `EditApiForm`
|
|
23
|
+
- `RenderInlineModel`
|
|
24
|
+
- `Thumbnail`
|
|
25
|
+
|
|
26
|
+
Exposes sub-components related to DetailDrawer rendering:
|
|
27
|
+
- `DetailDrawerComponent`
|
|
28
|
+
- `useLocalLibState`
|
|
29
|
+
|
|
30
|
+
### 0.11.3 - April 2026
|
|
31
|
+
|
|
32
|
+
Exposes additional type definitions related to rendering drawers from tables:
|
|
33
|
+
- `DetailDrawer`
|
|
34
|
+
- `TableState`
|
|
35
|
+
|
|
36
|
+
Also exposes `StylishText`, which is required downstream for rendering the DetailDrawer component, and is used in a number of places within the InvenTree UI.
|
|
37
|
+
|
|
5
38
|
### 0.11.2 - April 2026
|
|
6
39
|
|
|
7
40
|
Exposes additional type definitions related to tables and filters:
|
package/dist/.vite/manifest.json
CHANGED
|
@@ -122,6 +122,14 @@
|
|
|
122
122
|
"node_modules/@tabler/icons-react/dist/esm/icons/IconSearch.mjs"
|
|
123
123
|
]
|
|
124
124
|
},
|
|
125
|
+
"lib/components/StylishText.tsx": {
|
|
126
|
+
"file": "components/StylishText.js",
|
|
127
|
+
"name": "components/StylishText",
|
|
128
|
+
"src": "lib/components/StylishText.tsx",
|
|
129
|
+
"imports": [
|
|
130
|
+
"/home/inventree/src/frontend/node_modules/react/jsx-runtime.js?commonjs-es-import"
|
|
131
|
+
]
|
|
132
|
+
},
|
|
125
133
|
"lib/components/TableColumnSelect.tsx": {
|
|
126
134
|
"file": "components/TableColumnSelect.js",
|
|
127
135
|
"name": "components/TableColumnSelect",
|
|
@@ -140,6 +148,26 @@
|
|
|
140
148
|
"lib/functions/Conversion.tsx"
|
|
141
149
|
]
|
|
142
150
|
},
|
|
151
|
+
"lib/components/nav/DetailDrawer.css.ts": {
|
|
152
|
+
"file": "components/nav/DetailDrawer.css.js",
|
|
153
|
+
"name": "components/nav/DetailDrawer.css",
|
|
154
|
+
"src": "lib/components/nav/DetailDrawer.css.ts"
|
|
155
|
+
},
|
|
156
|
+
"lib/components/nav/DetailDrawer.tsx": {
|
|
157
|
+
"file": "components/nav/DetailDrawer.js",
|
|
158
|
+
"name": "components/nav/DetailDrawer",
|
|
159
|
+
"src": "lib/components/nav/DetailDrawer.tsx",
|
|
160
|
+
"imports": [
|
|
161
|
+
"/home/inventree/src/frontend/node_modules/react/jsx-runtime.js?commonjs-es-import",
|
|
162
|
+
"node_modules/react-router-dom/dist/index.js",
|
|
163
|
+
"node_modules/zustand/esm/react/shallow.mjs",
|
|
164
|
+
"lib/states/LocalLibState.tsx",
|
|
165
|
+
"lib/components/StylishText.tsx",
|
|
166
|
+
"lib/components/nav/DetailDrawer.css.ts",
|
|
167
|
+
"node_modules/react-router/dist/index.js",
|
|
168
|
+
"node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.mjs"
|
|
169
|
+
]
|
|
170
|
+
},
|
|
143
171
|
"lib/enums/ApiEndpoints.tsx": {
|
|
144
172
|
"file": "enums/ApiEndpoints.js",
|
|
145
173
|
"name": "enums/ApiEndpoints",
|
|
@@ -224,10 +252,10 @@
|
|
|
224
252
|
"src": "lib/hooks/MonitorBackgroundTask.tsx",
|
|
225
253
|
"imports": [
|
|
226
254
|
"/home/inventree/src/frontend/node_modules/react/jsx-runtime.js?commonjs-es-import",
|
|
255
|
+
"node_modules/@mantine/hooks/esm/use-document-visibility/use-document-visibility.mjs",
|
|
227
256
|
"node_modules/@tanstack/react-query/build/modern/useQuery.js",
|
|
228
257
|
"lib/enums/ApiEndpoints.tsx",
|
|
229
258
|
"lib/functions/Api.tsx",
|
|
230
|
-
"node_modules/@mantine/hooks/esm/use-document-visibility/use-document-visibility.mjs",
|
|
231
259
|
"node_modules/@tabler/icons-react/dist/esm/icons/IconCircleCheck.mjs",
|
|
232
260
|
"node_modules/@tabler/icons-react/dist/esm/icons/IconCircleX.mjs",
|
|
233
261
|
"node_modules/@tabler/icons-react/dist/esm/icons/IconExclamationCircle.mjs"
|
|
@@ -239,11 +267,11 @@
|
|
|
239
267
|
"src": "lib/hooks/MonitorDataOutput.tsx",
|
|
240
268
|
"imports": [
|
|
241
269
|
"/home/inventree/src/frontend/node_modules/react/jsx-runtime.js?commonjs-es-import",
|
|
270
|
+
"node_modules/@mantine/hooks/esm/use-document-visibility/use-document-visibility.mjs",
|
|
242
271
|
"node_modules/@tanstack/react-query/build/modern/useQuery.js",
|
|
243
272
|
"lib/components/ProgressBar.tsx",
|
|
244
273
|
"lib/enums/ApiEndpoints.tsx",
|
|
245
274
|
"lib/functions/Api.tsx",
|
|
246
|
-
"node_modules/@mantine/hooks/esm/use-document-visibility/use-document-visibility.mjs",
|
|
247
275
|
"node_modules/@tabler/icons-react/dist/esm/icons/IconExclamationCircle.mjs",
|
|
248
276
|
"node_modules/@tabler/icons-react/dist/esm/icons/IconCircleCheck.mjs"
|
|
249
277
|
]
|
|
@@ -261,8 +289,8 @@
|
|
|
261
289
|
"name": "hooks/UseTable",
|
|
262
290
|
"src": "lib/hooks/UseTable.tsx",
|
|
263
291
|
"imports": [
|
|
264
|
-
"
|
|
265
|
-
"
|
|
292
|
+
"node_modules/@mantine/hooks/esm/utils/random-id/random-id.mjs",
|
|
293
|
+
"lib/hooks/UseFilterSet.tsx"
|
|
266
294
|
]
|
|
267
295
|
},
|
|
268
296
|
"lib/index.ts": {
|
|
@@ -298,7 +326,19 @@
|
|
|
298
326
|
"lib/hooks/MonitorBackgroundTask.tsx",
|
|
299
327
|
"lib/hooks/UseFilterSet.tsx",
|
|
300
328
|
"lib/hooks/UseTable.tsx",
|
|
301
|
-
"lib/
|
|
329
|
+
"lib/components/nav/DetailDrawer.tsx",
|
|
330
|
+
"lib/components/StylishText.tsx",
|
|
331
|
+
"lib/states/StoredTableState.tsx",
|
|
332
|
+
"lib/states/LocalLibState.tsx"
|
|
333
|
+
]
|
|
334
|
+
},
|
|
335
|
+
"lib/states/LocalLibState.tsx": {
|
|
336
|
+
"file": "states/LocalLibState.js",
|
|
337
|
+
"name": "states/LocalLibState",
|
|
338
|
+
"src": "lib/states/LocalLibState.tsx",
|
|
339
|
+
"imports": [
|
|
340
|
+
"node_modules/zustand/esm/middleware.mjs",
|
|
341
|
+
"node_modules/zustand/esm/react.mjs"
|
|
302
342
|
]
|
|
303
343
|
},
|
|
304
344
|
"lib/states/StoredTableState.tsx": {
|
|
@@ -351,6 +391,11 @@
|
|
|
351
391
|
"name": "node_modules/@mantine/hooks/esm/utils/random-id/random-id",
|
|
352
392
|
"src": "node_modules/@mantine/hooks/esm/utils/random-id/random-id.mjs"
|
|
353
393
|
},
|
|
394
|
+
"node_modules/@remix-run/router/dist/router.js": {
|
|
395
|
+
"file": "node_modules/@remix-run/router/dist/router.js",
|
|
396
|
+
"name": "node_modules/@remix-run/router/dist/router",
|
|
397
|
+
"src": "node_modules/@remix-run/router/dist/router.js"
|
|
398
|
+
},
|
|
354
399
|
"node_modules/@sentry/browser/build/npm/esm/prod/debug-build.js": {
|
|
355
400
|
"file": "node_modules/@sentry/browser/build/npm/esm/prod/debug-build.js",
|
|
356
401
|
"name": "node_modules/@sentry/browser/build/npm/esm/prod/debug-build",
|
|
@@ -646,6 +691,14 @@
|
|
|
646
691
|
"node_modules/@tabler/icons-react/dist/esm/createReactComponent.mjs"
|
|
647
692
|
]
|
|
648
693
|
},
|
|
694
|
+
"node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.mjs": {
|
|
695
|
+
"file": "node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js",
|
|
696
|
+
"name": "node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft",
|
|
697
|
+
"src": "node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.mjs",
|
|
698
|
+
"imports": [
|
|
699
|
+
"node_modules/@tabler/icons-react/dist/esm/createReactComponent.mjs"
|
|
700
|
+
]
|
|
701
|
+
},
|
|
649
702
|
"node_modules/@tabler/icons-react/dist/esm/icons/IconCircleCheck.mjs": {
|
|
650
703
|
"file": "node_modules/@tabler/icons-react/dist/esm/icons/IconCircleCheck.js",
|
|
651
704
|
"name": "node_modules/@tabler/icons-react/dist/esm/icons/IconCircleCheck",
|
|
@@ -859,6 +912,23 @@
|
|
|
859
912
|
"node_modules/@tanstack/react-query/build/modern/useBaseQuery.js"
|
|
860
913
|
]
|
|
861
914
|
},
|
|
915
|
+
"node_modules/react-router-dom/dist/index.js": {
|
|
916
|
+
"file": "node_modules/react-router-dom/dist/index.js",
|
|
917
|
+
"name": "node_modules/react-router-dom/dist/index",
|
|
918
|
+
"src": "node_modules/react-router-dom/dist/index.js",
|
|
919
|
+
"imports": [
|
|
920
|
+
"node_modules/react-router/dist/index.js",
|
|
921
|
+
"node_modules/@remix-run/router/dist/router.js"
|
|
922
|
+
]
|
|
923
|
+
},
|
|
924
|
+
"node_modules/react-router/dist/index.js": {
|
|
925
|
+
"file": "node_modules/react-router/dist/index.js",
|
|
926
|
+
"name": "node_modules/react-router/dist/index",
|
|
927
|
+
"src": "node_modules/react-router/dist/index.js",
|
|
928
|
+
"imports": [
|
|
929
|
+
"node_modules/@remix-run/router/dist/router.js"
|
|
930
|
+
]
|
|
931
|
+
},
|
|
862
932
|
"node_modules/react/cjs/react-jsx-runtime.development.js": {
|
|
863
933
|
"file": "node_modules/react/cjs/react-jsx-runtime.development.js",
|
|
864
934
|
"name": "node_modules/react/cjs/react-jsx-runtime.development",
|
|
@@ -898,9 +968,26 @@
|
|
|
898
968
|
"node_modules/zustand/esm/vanilla.mjs"
|
|
899
969
|
]
|
|
900
970
|
},
|
|
971
|
+
"node_modules/zustand/esm/react/shallow.mjs": {
|
|
972
|
+
"file": "node_modules/zustand/esm/react/shallow.js",
|
|
973
|
+
"name": "node_modules/zustand/esm/react/shallow",
|
|
974
|
+
"src": "node_modules/zustand/esm/react/shallow.mjs",
|
|
975
|
+
"imports": [
|
|
976
|
+
"node_modules/zustand/esm/vanilla/shallow.mjs"
|
|
977
|
+
]
|
|
978
|
+
},
|
|
901
979
|
"node_modules/zustand/esm/vanilla.mjs": {
|
|
902
980
|
"file": "node_modules/zustand/esm/vanilla.js",
|
|
903
981
|
"name": "node_modules/zustand/esm/vanilla",
|
|
904
982
|
"src": "node_modules/zustand/esm/vanilla.mjs"
|
|
983
|
+
},
|
|
984
|
+
"node_modules/zustand/esm/vanilla/shallow.mjs": {
|
|
985
|
+
"file": "node_modules/zustand/esm/vanilla/shallow.js",
|
|
986
|
+
"name": "node_modules/zustand/esm/vanilla/shallow",
|
|
987
|
+
"src": "node_modules/zustand/esm/vanilla/shallow.mjs"
|
|
988
|
+
},
|
|
989
|
+
"style.css": {
|
|
990
|
+
"file": "ui.css",
|
|
991
|
+
"src": "style.css"
|
|
905
992
|
}
|
|
906
993
|
}
|
|
@@ -3,21 +3,30 @@ import { ErrorBoundary } from "../node_modules/@sentry/react/build/esm/errorboun
|
|
|
3
3
|
import IconExclamationCircle from "../node_modules/@tabler/icons-react/dist/esm/icons/IconExclamationCircle.js";
|
|
4
4
|
const _i18n = window["LinguiCore"].i18n;
|
|
5
5
|
const Alert = window["MantineCore"].Alert;
|
|
6
|
+
const Stack = window["MantineCore"].Stack;
|
|
6
7
|
const useCallback = window["React"].useCallback;
|
|
7
8
|
function DefaultFallback({
|
|
8
9
|
title
|
|
9
10
|
}) {
|
|
10
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(Alert, { color: "red", icon: /* @__PURE__ */ jsxRuntimeExports.jsx(IconExclamationCircle, {}), title:
|
|
11
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Alert, { color: "red", icon: /* @__PURE__ */ jsxRuntimeExports.jsx(IconExclamationCircle, {}), title: `INVE-E17: ${_i18n._(
|
|
11
12
|
/*i18n*/
|
|
12
13
|
{
|
|
13
14
|
id: "qwCNwv"
|
|
14
15
|
}
|
|
15
|
-
)}: ${title}`, children:
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
)}: ${title}`, children: /* @__PURE__ */ jsxRuntimeExports.jsxs(Stack, { gap: "xs", children: [
|
|
17
|
+
_i18n._(
|
|
18
|
+
/*i18n*/
|
|
19
|
+
{
|
|
20
|
+
id: "kH8meY"
|
|
21
|
+
}
|
|
22
|
+
),
|
|
23
|
+
_i18n._(
|
|
24
|
+
/*i18n*/
|
|
25
|
+
{
|
|
26
|
+
id: "pz0nW1"
|
|
27
|
+
}
|
|
28
|
+
)
|
|
29
|
+
] }) });
|
|
21
30
|
}
|
|
22
31
|
function Boundary({
|
|
23
32
|
children,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Boundary.js","sources":["../../lib/components/Boundary.tsx"],"sourcesContent":["import { t } from '@lingui/core/macro';\nimport { Alert } from '@mantine/core';\nimport { ErrorBoundary, type FallbackRender } from '@sentry/react';\nimport { IconExclamationCircle } from '@tabler/icons-react';\nimport { type ReactNode, useCallback } from 'react';\n\nexport function DefaultFallback({\n title\n}: Readonly<{ title: string }>): ReactNode {\n return (\n <Alert\n color='red'\n icon={<IconExclamationCircle />}\n title={
|
|
1
|
+
{"version":3,"file":"Boundary.js","sources":["../../lib/components/Boundary.tsx"],"sourcesContent":["import { t } from '@lingui/core/macro';\nimport { Alert, Stack } from '@mantine/core';\nimport { ErrorBoundary, type FallbackRender } from '@sentry/react';\nimport { IconExclamationCircle } from '@tabler/icons-react';\nimport { type ReactNode, useCallback } from 'react';\n\nexport function DefaultFallback({\n title\n}: Readonly<{ title: string }>): ReactNode {\n return (\n <Alert\n color='red'\n icon={<IconExclamationCircle />}\n title={`INVE-E17: ${t`Error rendering component`}: ${title}`}\n >\n <Stack gap='xs'>\n {t`An error occurred while rendering this component. Refer to the console for more information.`}\n {t`Try reloading the page, or contact your administrator if the problem persists.`}\n </Stack>\n </Alert>\n );\n}\n\nexport function Boundary({\n children,\n label,\n fallback\n}: Readonly<{\n children: ReactNode;\n label: string;\n fallback?: React.ReactElement<any> | FallbackRender;\n}>): ReactNode {\n const onError = useCallback(\n (error: unknown, componentStack: string | undefined, eventId: string) => {\n console.error(`ERR: Error rendering component: ${label}`);\n console.error(error);\n },\n []\n );\n\n return (\n <ErrorBoundary\n fallback={fallback ?? <DefaultFallback title={label} />}\n onError={onError}\n >\n {children}\n </ErrorBoundary>\n );\n}\n"],"names":["DefaultFallback","title","jsx","_i18n","_","id","jsxs","Boundary","children","label","fallback","onError","useCallback","error","componentStack","eventId","console"],"mappings":";;;AAAA,MAAA,QAAA,OAAA,YAAA,EAAA;AACA,MAAA,QAAA,OAAA,aAAA,EAAA;;AAGA,MAAA,cAAA,OAAA,OAAA,EAAA;AAEO,SAASA,gBAAgB;AAAA,EAC9BC;AAC2B,GAAc;AACzC,SACEC,kCAAAA,IAAC,OAAA,EACC,OAAM,OACN,4CAAO,uBAAA,CAAA,CAAqB,GAC5B,OAAO,aAAAC,MAAAC;AAAAA;AAAAA,IAAa;AAAA,MAAAC,IAAA;AAAA,IAAA;AAAA,EAA2B,CAAC,KAAKJ,KAAK,IAE1D,UAAAK,uCAAC,OAAA,EAAM,KAAI,MACTH,UAAAA;AAAAA,IAAAA,MAAAC;AAAAA;AAAAA,MAAC;AAAA,QAAAC,IAAA;AAAA,MAAA;AAAA,IAA8F;AAAA,IAC/FF,MAAAC;AAAAA;AAAAA,MAAC;AAAA,QAAAC,IAAA;AAAA,MAAA;AAAA,IAAgF;AAAA,EAAC,EAAA,CACpF,EAAA,CACF;AAEJ;AAEO,SAASE,SAAS;AAAA,EACvBC;AAAAA,EACAC;AAAAA,EACAC;AAKD,GAAc;AACb,QAAMC,UAAUC,YACd,CAACC,OAAgBC,gBAAoCC,YAAoB;AACvEC,YAAQH,MAAM,mCAAmCJ,KAAK,EAAE;AACxDO,YAAQH,MAAMA,KAAK;AAAA,EACrB,GACA,CAAA,CACF;AAEA,SACEX,kCAAAA,IAAC,eAAA,EACC,UAAUQ,YAAYR,kCAAAA,IAAC,mBAAgB,OAAOO,MAAAA,CAAM,GACpD,SAECD,SAAAA,CACH;AAEJ;"}
|
|
@@ -9,7 +9,8 @@ function InvenTreeTable({
|
|
|
9
9
|
props,
|
|
10
10
|
context
|
|
11
11
|
}) {
|
|
12
|
-
|
|
12
|
+
var _a, _b;
|
|
13
|
+
if (!((_a = context == null ? void 0 : context.tables) == null ? void 0 : _a.renderTable)) {
|
|
13
14
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(Alert, { title: "Plugin Version Error", color: "red", children: [
|
|
14
15
|
'The <InvenTreeTable> component cannot be rendered because the plugin context is missing the "renderTable" function.',
|
|
15
16
|
/* @__PURE__ */ jsxRuntimeExports.jsx("br", {}),
|
|
@@ -21,11 +22,11 @@ function InvenTreeTable({
|
|
|
21
22
|
/* @__PURE__ */ jsxRuntimeExports.jsx("br", {}),
|
|
22
23
|
/* @__PURE__ */ jsxRuntimeExports.jsx("b", { children: "UI Version:" }),
|
|
23
24
|
" ",
|
|
24
|
-
context
|
|
25
|
+
((_b = context == null ? void 0 : context.version) == null ? void 0 : _b.inventree) || "unknown",
|
|
25
26
|
/* @__PURE__ */ jsxRuntimeExports.jsx("br", {})
|
|
26
27
|
] });
|
|
27
28
|
}
|
|
28
|
-
return context
|
|
29
|
+
return context == null ? void 0 : context.tables.renderTable({
|
|
29
30
|
url,
|
|
30
31
|
tableState,
|
|
31
32
|
tableData,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvenTreeTable.js","sources":["../../lib/components/InvenTreeTable.tsx"],"sourcesContent":["import { Alert } from '@mantine/core';\nimport {\n INVENTREE_PLUGIN_VERSION,\n type InvenTreePluginContext\n} from '../types/Plugins';\nimport type {\n InvenTreeTableProps,\n TableColumn,\n TableState\n} from '../types/Tables';\n\n/**\n * Wrapper function which allows plugins to render an InvenTree component instance directly,\n * in a similar way to the standard InvenTreeTable component.\n *\n * Note: The InventreePluginContext \"context\" object must be provided when rendering the table\n *\n */\n\nexport default function InvenTreeTable({\n url,\n tableState,\n tableData,\n columns,\n props,\n context\n}: {\n url?: string;\n tableState: TableState;\n tableData?: any[];\n columns: TableColumn<any>[];\n props: InvenTreeTableProps;\n context: InvenTreePluginContext;\n}) {\n if (!context?.tables?.renderTable) {\n return (\n <Alert title='Plugin Version Error' color='red'>\n {\n 'The <InvenTreeTable> component cannot be rendered because the plugin context is missing the \"renderTable\" function.'\n }\n <br />\n {\n 'This means that the InvenTree UI library version is incompatible with this plugin version.'\n }\n <br />\n <b>Plugin Version:</b> {INVENTREE_PLUGIN_VERSION}\n <br />\n <b>UI Version:</b> {context?.version?.inventree || 'unknown'}\n <br />\n </Alert>\n );\n }\n\n return context?.tables.renderTable({\n url: url,\n tableState: tableState,\n tableData: tableData,\n columns: columns,\n props: props,\n api: context.api,\n navigate: context.navigate\n });\n}\n"],"names":["InvenTreeTable","url","tableState","tableData","columns","props","context","tables","renderTable","jsxs","jsx","INVENTREE_PLUGIN_VERSION","version","inventree","api","navigate"],"mappings":";;AAAA,MAAA,QAAA,OAAA,aAAA,EAAA;AAmBA,SAAwBA,eAAe;AAAA,EACrCC;AAAAA,EACAC;AAAAA,EACAC;AAAAA,EACAC;AAAAA,EACAC;AAAAA,EACAC;AAQF,GAAG
|
|
1
|
+
{"version":3,"file":"InvenTreeTable.js","sources":["../../lib/components/InvenTreeTable.tsx"],"sourcesContent":["import { Alert } from '@mantine/core';\nimport {\n INVENTREE_PLUGIN_VERSION,\n type InvenTreePluginContext\n} from '../types/Plugins';\nimport type {\n InvenTreeTableProps,\n TableColumn,\n TableState\n} from '../types/Tables';\n\n/**\n * Wrapper function which allows plugins to render an InvenTree component instance directly,\n * in a similar way to the standard InvenTreeTable component.\n *\n * Note: The InventreePluginContext \"context\" object must be provided when rendering the table\n *\n */\n\nexport default function InvenTreeTable({\n url,\n tableState,\n tableData,\n columns,\n props,\n context\n}: {\n url?: string;\n tableState: TableState;\n tableData?: any[];\n columns: TableColumn<any>[];\n props: InvenTreeTableProps;\n context: InvenTreePluginContext;\n}) {\n if (!context?.tables?.renderTable) {\n return (\n <Alert title='Plugin Version Error' color='red'>\n {\n 'The <InvenTreeTable> component cannot be rendered because the plugin context is missing the \"renderTable\" function.'\n }\n <br />\n {\n 'This means that the InvenTree UI library version is incompatible with this plugin version.'\n }\n <br />\n <b>Plugin Version:</b> {INVENTREE_PLUGIN_VERSION}\n <br />\n <b>UI Version:</b> {context?.version?.inventree || 'unknown'}\n <br />\n </Alert>\n );\n }\n\n return context?.tables.renderTable({\n url: url,\n tableState: tableState,\n tableData: tableData,\n columns: columns,\n props: props,\n api: context.api,\n navigate: context.navigate\n });\n}\n"],"names":["InvenTreeTable","url","tableState","tableData","columns","props","context","tables","renderTable","jsxs","jsx","INVENTREE_PLUGIN_VERSION","version","inventree","api","navigate"],"mappings":";;AAAA,MAAA,QAAA,OAAA,aAAA,EAAA;AAmBA,SAAwBA,eAAe;AAAA,EACrCC;AAAAA,EACAC;AAAAA,EACAC;AAAAA,EACAC;AAAAA,EACAC;AAAAA,EACAC;AAQF,GAAG;;AACD,MAAI,GAACA,wCAASC,WAATD,mBAAiBE,cAAa;AACjC,WACEC,kCAAAA,KAAC,OAAA,EAAM,OAAM,wBAAuB,OAAM,OAEtC,UAAA;AAAA,MAAA;AAAA,4CAED,MAAA,EAAE;AAAA,MAED;AAAA,4CAED,MAAA,EAAE;AAAA,MACHC,kCAAAA,IAAC,OAAE,UAAA,kBAAA,CAAe;AAAA,MAAI;AAAA,MAAEC;AAAAA,4CACvB,MAAA,EAAE;AAAA,MACHD,kCAAAA,IAAC,OAAE,UAAA,cAAA,CAAW;AAAA,MAAI;AAAA,QAAEJ,wCAASM,YAATN,mBAAkBO,cAAa;AAAA,4CAClD,MAAA,CAAA,CAAE;AAAA,IAAA,GACL;AAAA,EAEJ;AAEA,SAAOP,mCAASC,OAAOC,YAAY;AAAA,IACjCP;AAAAA,IACAC;AAAAA,IACAC;AAAAA,IACAC;AAAAA,IACAC;AAAAA,IACAS,KAAKR,QAAQQ;AAAAA,IACbC,UAAUT,QAAQS;AAAAA,EAAAA;AAEtB;"}
|
|
@@ -92,8 +92,9 @@ function RowActions({
|
|
|
92
92
|
}, [actions]);
|
|
93
93
|
function RowActionIcon(action) {
|
|
94
94
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(Tooltip, { withinPortal: true, label: action.tooltip ?? action.title, position: "left", children: /* @__PURE__ */ jsxRuntimeExports.jsx(Menu.Item, { color: action.color, leftSection: action.icon, onClick: (event) => {
|
|
95
|
+
var _a;
|
|
95
96
|
cancelEvent(event);
|
|
96
|
-
action.onClick
|
|
97
|
+
(_a = action.onClick) == null ? void 0 : _a.call(action, event);
|
|
97
98
|
setOpened(false);
|
|
98
99
|
}, disabled: action.disabled || false, children: action.title }) }, action.title);
|
|
99
100
|
}
|
|
@@ -103,7 +104,7 @@ function RowActions({
|
|
|
103
104
|
{
|
|
104
105
|
id: "7L01XJ"
|
|
105
106
|
}
|
|
106
|
-
), children: /* @__PURE__ */ jsxRuntimeExports.jsx(ActionIcon, { "aria-label": `row-action-menu-${index ?? ""}`, onClick: openMenu, disabled, variant: "
|
|
107
|
+
), children: /* @__PURE__ */ jsxRuntimeExports.jsx(ActionIcon, { "aria-label": `row-action-menu-${index ?? ""}`, onClick: openMenu, disabled, variant: "transparent", size: "sm", children: /* @__PURE__ */ jsxRuntimeExports.jsx(IconDots, {}) }, `row-action-menu-${index ?? ""}`) }) }),
|
|
107
108
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Menu.Dropdown, { children: visibleActions.map((action) => /* @__PURE__ */ jsxRuntimeExports.jsx(RowActionIcon, { ...action }, action.title)) })
|
|
108
109
|
] });
|
|
109
110
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RowActions.js","sources":["../../lib/components/RowActions.tsx"],"sourcesContent":["import { t } from '@lingui/core/macro';\nimport { ActionIcon, Menu, Tooltip } from '@mantine/core';\nimport {\n IconArrowRight,\n IconCircleX,\n IconCopy,\n IconDots,\n IconEdit,\n IconTrash\n} from '@tabler/icons-react';\nimport { type ReactNode, useMemo, useState } from 'react';\nimport { cancelEvent } from '../functions/Events';\nimport { getDetailUrl } from '../functions/Navigation';\nimport { navigateToLink } from '../functions/Navigation';\nimport type { RowAction, RowViewProps } from '../types/Tables';\n\nexport type { RowAction, RowViewProps } from '../types/Tables';\n\n// Component for viewing a row in a table\nexport function RowViewAction(props: RowViewProps): RowAction {\n return {\n ...props,\n color: undefined,\n icon: <IconArrowRight />,\n onClick: (event: any) => {\n const url = getDetailUrl(props.modelType, props.modelId);\n navigateToLink(url, props.navigate, event);\n }\n };\n}\n\n// Component for duplicating a row in a table\nexport function RowDuplicateAction(props: RowAction): RowAction {\n return {\n ...props,\n title: t`Duplicate`,\n color: 'green',\n icon: <IconCopy />\n };\n}\n\n// Component for editing a row in a table\nexport function RowEditAction(props: RowAction): RowAction {\n return {\n ...props,\n title: t`Edit`,\n color: 'blue',\n icon: <IconEdit />\n };\n}\n\n// Component for deleting a row in a table\nexport function RowDeleteAction(props: RowAction): RowAction {\n return {\n ...props,\n title: t`Delete`,\n color: 'red',\n icon: <IconTrash />\n };\n}\n\n// Component for cancelling a row in a table\nexport function RowCancelAction(props: RowAction): RowAction {\n return {\n ...props,\n title: t`Cancel`,\n color: 'red',\n icon: <IconCircleX />\n };\n}\n\n/**\n * Component for displaying actions for a row in a table.\n * Displays a simple dropdown menu with a list of actions.\n */\nexport function RowActions({\n title,\n actions,\n disabled = false,\n index\n}: {\n title?: string;\n disabled?: boolean;\n actions: RowAction[];\n index?: number;\n}): ReactNode {\n // Prevent default event handling\n // Ref: https://icflorescu.github.io/mantine-datatable/examples/links-or-buttons-inside-clickable-rows-or-cells\n function openMenu(event: any) {\n cancelEvent(event);\n setOpened(!opened);\n }\n\n const [opened, setOpened] = useState(false);\n\n const visibleActions = useMemo(() => {\n return actions.filter((action) => !action.hidden);\n }, [actions]);\n\n // Render a single action icon\n function RowActionIcon(action: Readonly<RowAction>) {\n return (\n <Tooltip\n withinPortal={true}\n label={action.tooltip ?? action.title}\n key={action.title}\n position='left'\n >\n <Menu.Item\n color={action.color}\n leftSection={action.icon}\n onClick={(event) => {\n // Prevent clicking on the action from selecting the row itself\n cancelEvent(event);\n action.onClick?.(event);\n setOpened(false);\n }}\n disabled={action.disabled || false}\n >\n {action.title}\n </Menu.Item>\n </Tooltip>\n );\n }\n\n return (\n visibleActions.length > 0 && (\n <Menu\n withinPortal={true}\n disabled={disabled}\n position='bottom-end'\n opened={opened}\n onChange={setOpened}\n >\n <Menu.Target>\n <Tooltip withinPortal={true} label={title || t`Actions`}>\n <ActionIcon\n key={`row-action-menu-${index ?? ''}`}\n aria-label={`row-action-menu-${index ?? ''}`}\n onClick={openMenu}\n disabled={disabled}\n variant='
|
|
1
|
+
{"version":3,"file":"RowActions.js","sources":["../../lib/components/RowActions.tsx"],"sourcesContent":["import { t } from '@lingui/core/macro';\nimport { ActionIcon, Menu, Tooltip } from '@mantine/core';\nimport {\n IconArrowRight,\n IconCircleX,\n IconCopy,\n IconDots,\n IconEdit,\n IconTrash\n} from '@tabler/icons-react';\nimport { type ReactNode, useMemo, useState } from 'react';\nimport { cancelEvent } from '../functions/Events';\nimport { getDetailUrl } from '../functions/Navigation';\nimport { navigateToLink } from '../functions/Navigation';\nimport type { RowAction, RowViewProps } from '../types/Tables';\n\nexport type { RowAction, RowViewProps } from '../types/Tables';\n\n// Component for viewing a row in a table\nexport function RowViewAction(props: RowViewProps): RowAction {\n return {\n ...props,\n color: undefined,\n icon: <IconArrowRight />,\n onClick: (event: any) => {\n const url = getDetailUrl(props.modelType, props.modelId);\n navigateToLink(url, props.navigate, event);\n }\n };\n}\n\n// Component for duplicating a row in a table\nexport function RowDuplicateAction(props: RowAction): RowAction {\n return {\n ...props,\n title: t`Duplicate`,\n color: 'green',\n icon: <IconCopy />\n };\n}\n\n// Component for editing a row in a table\nexport function RowEditAction(props: RowAction): RowAction {\n return {\n ...props,\n title: t`Edit`,\n color: 'blue',\n icon: <IconEdit />\n };\n}\n\n// Component for deleting a row in a table\nexport function RowDeleteAction(props: RowAction): RowAction {\n return {\n ...props,\n title: t`Delete`,\n color: 'red',\n icon: <IconTrash />\n };\n}\n\n// Component for cancelling a row in a table\nexport function RowCancelAction(props: RowAction): RowAction {\n return {\n ...props,\n title: t`Cancel`,\n color: 'red',\n icon: <IconCircleX />\n };\n}\n\n/**\n * Component for displaying actions for a row in a table.\n * Displays a simple dropdown menu with a list of actions.\n */\nexport function RowActions({\n title,\n actions,\n disabled = false,\n index\n}: {\n title?: string;\n disabled?: boolean;\n actions: RowAction[];\n index?: number;\n}): ReactNode {\n // Prevent default event handling\n // Ref: https://icflorescu.github.io/mantine-datatable/examples/links-or-buttons-inside-clickable-rows-or-cells\n function openMenu(event: any) {\n cancelEvent(event);\n setOpened(!opened);\n }\n\n const [opened, setOpened] = useState(false);\n\n const visibleActions = useMemo(() => {\n return actions.filter((action) => !action.hidden);\n }, [actions]);\n\n // Render a single action icon\n function RowActionIcon(action: Readonly<RowAction>) {\n return (\n <Tooltip\n withinPortal={true}\n label={action.tooltip ?? action.title}\n key={action.title}\n position='left'\n >\n <Menu.Item\n color={action.color}\n leftSection={action.icon}\n onClick={(event) => {\n // Prevent clicking on the action from selecting the row itself\n cancelEvent(event);\n action.onClick?.(event);\n setOpened(false);\n }}\n disabled={action.disabled || false}\n >\n {action.title}\n </Menu.Item>\n </Tooltip>\n );\n }\n\n return (\n visibleActions.length > 0 && (\n <Menu\n withinPortal={true}\n disabled={disabled}\n position='bottom-end'\n opened={opened}\n onChange={setOpened}\n >\n <Menu.Target>\n <Tooltip withinPortal={true} label={title || t`Actions`}>\n <ActionIcon\n key={`row-action-menu-${index ?? ''}`}\n aria-label={`row-action-menu-${index ?? ''}`}\n onClick={openMenu}\n disabled={disabled}\n variant='transparent'\n size='sm'\n >\n <IconDots />\n </ActionIcon>\n </Tooltip>\n </Menu.Target>\n <Menu.Dropdown>\n {visibleActions.map((action) => (\n <RowActionIcon key={action.title} {...action} />\n ))}\n </Menu.Dropdown>\n </Menu>\n )\n );\n}\n"],"names":["RowViewAction","props","color","undefined","icon","onClick","event","url","getDetailUrl","modelType","modelId","navigateToLink","navigate","RowDuplicateAction","title","_i18n","_","id","RowEditAction","RowDeleteAction","RowCancelAction","RowActions","actions","disabled","index","openMenu","cancelEvent","setOpened","opened","useState","visibleActions","useMemo","filter","action","hidden","RowActionIcon","jsx","tooltip","length","jsxs","map"],"mappings":"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"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { j as jsxRuntimeExports } from "../_virtual/jsx-runtime.js";
|
|
2
|
+
const Text = window["MantineCore"].Text;
|
|
3
|
+
const darken = window["MantineCore"].darken;
|
|
4
|
+
const getThemeColor = window["MantineCore"].getThemeColor;
|
|
5
|
+
const useMantineTheme = window["MantineCore"].useMantineTheme;
|
|
6
|
+
const useMemo = window["React"].useMemo;
|
|
7
|
+
const useThematicGradient = () => {
|
|
8
|
+
const theme = useMantineTheme();
|
|
9
|
+
const primary = useMemo(() => {
|
|
10
|
+
return getThemeColor(theme.primaryColor, theme);
|
|
11
|
+
}, [theme]);
|
|
12
|
+
const secondary = useMemo(() => darken(primary, 0.25), [primary]);
|
|
13
|
+
return useMemo(() => {
|
|
14
|
+
return {
|
|
15
|
+
primary,
|
|
16
|
+
secondary
|
|
17
|
+
};
|
|
18
|
+
}, [primary, secondary]);
|
|
19
|
+
};
|
|
20
|
+
function StylishText({
|
|
21
|
+
children,
|
|
22
|
+
size
|
|
23
|
+
}) {
|
|
24
|
+
const {
|
|
25
|
+
primary,
|
|
26
|
+
secondary
|
|
27
|
+
} = useThematicGradient();
|
|
28
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { fw: 700, size: size ?? "xl", variant: "gradient", gradient: {
|
|
29
|
+
from: primary.toString(),
|
|
30
|
+
to: secondary.toString()
|
|
31
|
+
}, children });
|
|
32
|
+
}
|
|
33
|
+
export {
|
|
34
|
+
StylishText
|
|
35
|
+
};
|
|
36
|
+
//# sourceMappingURL=StylishText.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StylishText.js","sources":["../../lib/components/StylishText.tsx"],"sourcesContent":["import {\n type MantineSize,\n Text,\n darken,\n getThemeColor,\n useMantineTheme\n} from '@mantine/core';\nimport { useMemo } from 'react';\nimport type { JSX } from 'react';\n\n// Hook that memoizes the gradient color based on the primary color of the theme\nconst useThematicGradient = () => {\n const theme = useMantineTheme();\n\n const primary = useMemo(() => {\n return getThemeColor(theme.primaryColor, theme);\n }, [theme]);\n\n const secondary = useMemo(() => darken(primary, 0.25), [primary]);\n\n return useMemo(() => {\n return { primary, secondary };\n }, [primary, secondary]);\n};\n\n// A stylish text component that uses the primary color of the theme\nexport function StylishText({\n children,\n size\n}: Readonly<{\n children: JSX.Element | string;\n size?: MantineSize;\n}>) {\n const { primary, secondary } = useThematicGradient();\n\n return (\n <Text\n fw={700}\n size={size ?? 'xl'}\n variant='gradient'\n gradient={{ from: primary.toString(), to: secondary.toString() }}\n >\n {children}\n </Text>\n );\n}\n"],"names":["useThematicGradient","theme","useMantineTheme","primary","useMemo","getThemeColor","primaryColor","secondary","darken","StylishText","children","size","jsx","from","toString","to"],"mappings":";AAAA,MAAA,OAAA,OAAA,aAAA,EAAA;;;;AAOA,MAAA,UAAA,OAAA,OAAA,EAAA;AAIA,MAAMA,sBAAsBA,MAAM;AAChC,QAAMC,QAAQC,gBAAAA;AAEd,QAAMC,UAAUC,QAAQ,MAAM;AAC5B,WAAOC,cAAcJ,MAAMK,cAAcL,KAAK;AAAA,EAChD,GAAG,CAACA,KAAK,CAAC;AAEV,QAAMM,YAAYH,QAAQ,MAAMI,OAAOL,SAAS,IAAI,GAAG,CAACA,OAAO,CAAC;AAEhE,SAAOC,QAAQ,MAAM;AACnB,WAAO;AAAA,MAAED;AAAAA,MAASI;AAAAA,IAAAA;AAAAA,EACpB,GAAG,CAACJ,SAASI,SAAS,CAAC;AACzB;AAGO,SAASE,YAAY;AAAA,EAC1BC;AAAAA,EACAC;AAID,GAAG;AACF,QAAM;AAAA,IAAER;AAAAA,IAASI;AAAAA,EAAAA,IAAcP,oBAAAA;AAE/B,SACEY,sCAAC,QACC,IAAI,KACJ,MAAMD,QAAQ,MACd,SAAQ,YACR,UAAU;AAAA,IAAEE,MAAMV,QAAQW,SAAAA;AAAAA,IAAYC,IAAIR,UAAUO,SAAAA;AAAAA,EAAS,GAE5DJ,SAAAA,CACH;AAEJ;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const flex: string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DetailDrawer.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { To } from 'react-router-dom';
|
|
2
|
+
import { UiSizeType } from '../../types/Core';
|
|
3
|
+
/**
|
|
4
|
+
* @param title - drawer title
|
|
5
|
+
* @param position - drawer position
|
|
6
|
+
* @param renderContent - function used to render the drawer content
|
|
7
|
+
* @param urlPrefix - set an additional url segment, useful when multiple drawers are rendered on one page (e.g. "user/")
|
|
8
|
+
*/
|
|
9
|
+
export interface DrawerProps {
|
|
10
|
+
title: string;
|
|
11
|
+
position?: 'right' | 'left';
|
|
12
|
+
renderContent: (id?: string) => React.ReactNode;
|
|
13
|
+
urlPrefix?: string;
|
|
14
|
+
size?: UiSizeType;
|
|
15
|
+
closeOnEscape?: boolean;
|
|
16
|
+
}
|
|
17
|
+
export declare function DetailDrawerComponent({ title, position, size, closeOnEscape, renderContent }: Readonly<DrawerProps>): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export declare function DetailDrawer(props: Readonly<DrawerProps>): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare function DetailDrawerLink({ to, text }: Readonly<{
|
|
20
|
+
to: To;
|
|
21
|
+
text: string;
|
|
22
|
+
}>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { j as jsxRuntimeExports } from "../../_virtual/jsx-runtime.js";
|
|
2
|
+
import { Link } from "../../node_modules/react-router-dom/dist/index.js";
|
|
3
|
+
import { useShallow } from "../../node_modules/zustand/esm/react/shallow.js";
|
|
4
|
+
import { useLocalLibState } from "../../states/LocalLibState.js";
|
|
5
|
+
import { StylishText } from "../StylishText.js";
|
|
6
|
+
import { flex } from "./DetailDrawer.css.js";
|
|
7
|
+
import { Routes, Route, useNavigate, useParams } from "../../node_modules/react-router/dist/index.js";
|
|
8
|
+
import IconChevronLeft from "../../node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js";
|
|
9
|
+
const ActionIcon = window["MantineCore"].ActionIcon;
|
|
10
|
+
const Divider = window["MantineCore"].Divider;
|
|
11
|
+
const Drawer = window["MantineCore"].Drawer;
|
|
12
|
+
const Group = window["MantineCore"].Group;
|
|
13
|
+
const Stack = window["MantineCore"].Stack;
|
|
14
|
+
const Text = window["MantineCore"].Text;
|
|
15
|
+
const useCallback = window["React"].useCallback;
|
|
16
|
+
const useMemo = window["React"].useMemo;
|
|
17
|
+
function DetailDrawerComponent({
|
|
18
|
+
title,
|
|
19
|
+
position = "right",
|
|
20
|
+
size,
|
|
21
|
+
closeOnEscape = true,
|
|
22
|
+
renderContent
|
|
23
|
+
}) {
|
|
24
|
+
const navigate = useNavigate();
|
|
25
|
+
const {
|
|
26
|
+
id
|
|
27
|
+
} = useParams();
|
|
28
|
+
const content = renderContent(id);
|
|
29
|
+
const opened = useMemo(() => !!id && !!content, [id, content]);
|
|
30
|
+
const [detailDrawerStack, addDetailDrawer] = useLocalLibState(useShallow((state) => [state.detailDrawerStack, state.addDetailDrawer]));
|
|
31
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Drawer, { opened, onClose: () => {
|
|
32
|
+
navigate("../");
|
|
33
|
+
addDetailDrawer(false);
|
|
34
|
+
}, position, closeOnEscape, size, classNames: {
|
|
35
|
+
root: flex,
|
|
36
|
+
body: flex
|
|
37
|
+
}, scrollAreaComponent: Stack, title: /* @__PURE__ */ jsxRuntimeExports.jsxs(Group, { children: [
|
|
38
|
+
detailDrawerStack > 0 && /* @__PURE__ */ jsxRuntimeExports.jsx(ActionIcon, { variant: "outline", onClick: () => {
|
|
39
|
+
navigate(-1);
|
|
40
|
+
addDetailDrawer(-1);
|
|
41
|
+
}, children: /* @__PURE__ */ jsxRuntimeExports.jsx(IconChevronLeft, {}) }),
|
|
42
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(StylishText, { size: "xl", children: title })
|
|
43
|
+
] }), children: /* @__PURE__ */ jsxRuntimeExports.jsxs(Stack, { gap: "xs", className: flex, children: [
|
|
44
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Divider, {}),
|
|
45
|
+
content
|
|
46
|
+
] }) });
|
|
47
|
+
}
|
|
48
|
+
function DetailDrawer(props) {
|
|
49
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Routes, { children: /* @__PURE__ */ jsxRuntimeExports.jsx(Route, { path: ":id?/", element: /* @__PURE__ */ jsxRuntimeExports.jsx(DetailDrawerComponent, { ...props }) }) });
|
|
50
|
+
}
|
|
51
|
+
function DetailDrawerLink({
|
|
52
|
+
to,
|
|
53
|
+
text
|
|
54
|
+
}) {
|
|
55
|
+
const addDetailDrawer = useLocalLibState(useShallow((state) => state.addDetailDrawer));
|
|
56
|
+
const onNavigate = useCallback(() => {
|
|
57
|
+
addDetailDrawer(1);
|
|
58
|
+
}, [addDetailDrawer]);
|
|
59
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Link, { to, onClick: onNavigate, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { children: text }) });
|
|
60
|
+
}
|
|
61
|
+
export {
|
|
62
|
+
DetailDrawer,
|
|
63
|
+
DetailDrawerComponent,
|
|
64
|
+
DetailDrawerLink
|
|
65
|
+
};
|
|
66
|
+
//# sourceMappingURL=DetailDrawer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DetailDrawer.js","sources":["../../../lib/components/nav/DetailDrawer.tsx"],"sourcesContent":["import { ActionIcon, Divider, Drawer, Group, Stack, Text } from '@mantine/core';\nimport { IconChevronLeft } from '@tabler/icons-react';\nimport { useCallback, useMemo } from 'react';\nimport { Link, Route, Routes, useNavigate, useParams } from 'react-router-dom';\nimport type { To } from 'react-router-dom';\n\nimport type { UiSizeType } from '../../types/Core';\n\nimport { useShallow } from 'zustand/react/shallow';\nimport { useLocalLibState } from '../../states/LocalLibState';\nimport { StylishText } from '../StylishText';\nimport * as classes from './DetailDrawer.css';\n\n/**\n * @param title - drawer title\n * @param position - drawer position\n * @param renderContent - function used to render the drawer content\n * @param urlPrefix - set an additional url segment, useful when multiple drawers are rendered on one page (e.g. \"user/\")\n */\nexport interface DrawerProps {\n title: string;\n position?: 'right' | 'left';\n renderContent: (id?: string) => React.ReactNode;\n urlPrefix?: string;\n size?: UiSizeType;\n closeOnEscape?: boolean;\n}\n\nexport function DetailDrawerComponent({\n title,\n position = 'right',\n size,\n closeOnEscape = true,\n renderContent\n}: Readonly<DrawerProps>) {\n const navigate = useNavigate();\n const { id } = useParams();\n\n const content = renderContent(id);\n const opened = useMemo(() => !!id && !!content, [id, content]);\n\n const [detailDrawerStack, addDetailDrawer] = useLocalLibState(\n useShallow((state) => [state.detailDrawerStack, state.addDetailDrawer])\n );\n\n return (\n <Drawer\n opened={opened}\n onClose={() => {\n navigate('../');\n addDetailDrawer(false);\n }}\n position={position}\n closeOnEscape={closeOnEscape}\n size={size}\n classNames={{ root: classes.flex, body: classes.flex }}\n scrollAreaComponent={Stack}\n title={\n <Group>\n {detailDrawerStack > 0 && (\n <ActionIcon\n variant='outline'\n onClick={() => {\n navigate(-1);\n addDetailDrawer(-1);\n }}\n >\n <IconChevronLeft />\n </ActionIcon>\n )}\n <StylishText size='xl'>{title}</StylishText>\n </Group>\n }\n >\n <Stack gap={'xs'} className={classes.flex}>\n <Divider />\n {content}\n </Stack>\n </Drawer>\n );\n}\n\nexport function DetailDrawer(props: Readonly<DrawerProps>) {\n return (\n <Routes>\n <Route path=':id?/' element={<DetailDrawerComponent {...props} />} />\n </Routes>\n );\n}\n\nexport function DetailDrawerLink({\n to,\n text\n}: Readonly<{ to: To; text: string }>) {\n const addDetailDrawer = useLocalLibState(\n useShallow((state) => state.addDetailDrawer)\n );\n\n const onNavigate = useCallback(() => {\n addDetailDrawer(1);\n }, [addDetailDrawer]);\n\n return (\n <Link to={to} onClick={onNavigate}>\n <Text>{text}</Text>\n </Link>\n );\n}\n"],"names":["DetailDrawerComponent","title","position","size","closeOnEscape","renderContent","navigate","useNavigate","id","useParams","content","opened","useMemo","detailDrawerStack","addDetailDrawer","useLocalLibState","useShallow","state","jsx","root","classes","body","flex","Stack","jsxs","DetailDrawer","props","DetailDrawerLink","to","text","onNavigate","useCallback"],"mappings":";;;;;;;;AAAA,MAAA,aAAA,OAAA,aAAA,EAAA;;;;;;AAEA,MAAA,cAAA,OAAA,OAAA,EAAA;;AA0BO,SAASA,sBAAsB;AAAA,EACpCC;AAAAA,EACAC,WAAW;AAAA,EACXC;AAAAA,EACAC,gBAAgB;AAAA,EAChBC;AACqB,GAAG;AACxB,QAAMC,WAAWC,YAAAA;AACjB,QAAM;AAAA,IAAEC;AAAAA,EAAAA,IAAOC,UAAAA;AAEf,QAAMC,UAAUL,cAAcG,EAAE;AAChC,QAAMG,SAASC,QAAQ,MAAM,CAAC,CAACJ,MAAM,CAAC,CAACE,SAAS,CAACF,IAAIE,OAAO,CAAC;AAE7D,QAAM,CAACG,mBAAmBC,eAAe,IAAIC,iBAC3CC,WAAYC,CAAAA,UAAU,CAACA,MAAMJ,mBAAmBI,MAAMH,eAAe,CAAC,CACxE;AAEA,SACEI,kCAAAA,IAAC,QAAA,EACC,QACA,SAAS,MAAM;AACbZ,aAAS,KAAK;AACdQ,oBAAgB,KAAK;AAAA,EACvB,GACA,UACA,eACA,MACA,YAAY;AAAA,IAAEK,MAAMC;AAAAA,IAAcC,MAAMD;AAAAA,EAAQE,GAChD,qBAAqBC,OACrB,8CACG,OAAA,EACEV,UAAAA;AAAAA,IAAAA,oBAAoB,KACnBK,sCAAC,YAAA,EACC,SAAQ,WACR,SAAS,MAAM;AACbZ,eAAS,EAAE;AACXQ,sBAAgB,EAAE;AAAA,IACpB,GAEA,UAAAI,kCAAAA,IAAC,iBAAA,CAAA,CAAe,EAAA,CAClB;AAAA,IAEFA,kCAAAA,IAAC,aAAA,EAAY,MAAK,MAAMjB,UAAAA,MAAAA,CAAM;AAAA,EAAA,GAChC,GAGF,UAAAuB,kCAAAA,KAAC,OAAA,EAAM,KAAK,MAAM,WAAWJ,MAC3B,UAAA;AAAA,IAAAF,kCAAAA,IAAC,SAAA,EAAO;AAAA,IACPR;AAAAA,EAAAA,EAAAA,CACH,EAAA,CACF;AAEJ;AAEO,SAASe,aAAaC,OAA8B;AACzD,SACER,kCAAAA,IAAC,QAAA,EACC,UAAAA,kCAAAA,IAAC,OAAA,EAAM,MAAK,SAAQ,SAASA,kCAAAA,IAAC,uBAAA,KAA0BQ,MAAAA,IAAU,GACpE;AAEJ;AAEO,SAASC,iBAAiB;AAAA,EAC/BC;AAAAA,EACAC;AACkC,GAAG;AACrC,QAAMf,kBAAkBC,iBACtBC,WAAYC,CAAAA,UAAUA,MAAMH,eAAe,CAC7C;AAEA,QAAMgB,aAAaC,YAAY,MAAM;AACnCjB,oBAAgB,CAAC;AAAA,EACnB,GAAG,CAACA,eAAe,CAAC;AAEpB,SACEI,kCAAAA,IAAC,QAAK,IAAQ,SAASY,YACrB,UAAAZ,kCAAAA,IAAC,MAAA,EAAMW,gBAAK,EAAA,CACd;AAEJ;"}
|
|
@@ -119,6 +119,7 @@ export declare enum ApiEndpoints {
|
|
|
119
119
|
stock_merge = "stock/merge/",
|
|
120
120
|
stock_assign = "stock/assign/",
|
|
121
121
|
stock_status = "stock/status/",
|
|
122
|
+
stock_convert = "stock/:id/convert/",
|
|
122
123
|
stock_install = "stock/:id/install/",
|
|
123
124
|
stock_uninstall = "stock/:id/uninstall/",
|
|
124
125
|
stock_serialize = "stock/:id/serialize/",
|
|
@@ -119,6 +119,7 @@ var ApiEndpoints = /* @__PURE__ */ ((ApiEndpoints2) => {
|
|
|
119
119
|
ApiEndpoints2["stock_merge"] = "stock/merge/";
|
|
120
120
|
ApiEndpoints2["stock_assign"] = "stock/assign/";
|
|
121
121
|
ApiEndpoints2["stock_status"] = "stock/status/";
|
|
122
|
+
ApiEndpoints2["stock_convert"] = "stock/:id/convert/";
|
|
122
123
|
ApiEndpoints2["stock_install"] = "stock/:id/install/";
|
|
123
124
|
ApiEndpoints2["stock_uninstall"] = "stock/:id/uninstall/";
|
|
124
125
|
ApiEndpoints2["stock_serialize"] = "stock/:id/serialize/";
|