@trackunit/iris-app 1.7.8 → 1.7.11
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 +30 -0
- package/package.json +6 -6
- package/src/generators/extend/files/WIDGET_EXTENSION/extension-manifest.ts__template__ +1 -1
- package/src/generators/preset/files/.cursor/rules/react-core-hooks.mdc +1 -1
- package/src/generators/preset/files/.cursor/rules/widget-extensions.mdc +10 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,33 @@
|
|
|
1
|
+
## 1.7.11 (2025-10-06)
|
|
2
|
+
|
|
3
|
+
### 🧱 Updated Dependencies
|
|
4
|
+
|
|
5
|
+
- Updated iris-app-build-utilities to 1.7.11
|
|
6
|
+
- Updated iris-app-webpack-plugin to 1.7.11
|
|
7
|
+
- Updated iris-app-api to 1.7.11
|
|
8
|
+
- Updated react-test-setup to 1.4.10
|
|
9
|
+
- Updated shared-utils to 1.9.10
|
|
10
|
+
|
|
11
|
+
## 1.7.10 (2025-10-03)
|
|
12
|
+
|
|
13
|
+
### 🧱 Updated Dependencies
|
|
14
|
+
|
|
15
|
+
- Updated iris-app-build-utilities to 1.7.10
|
|
16
|
+
- Updated iris-app-webpack-plugin to 1.7.10
|
|
17
|
+
- Updated iris-app-api to 1.7.10
|
|
18
|
+
- Updated react-test-setup to 1.4.9
|
|
19
|
+
- Updated shared-utils to 1.9.9
|
|
20
|
+
|
|
21
|
+
## 1.7.9 (2025-10-02)
|
|
22
|
+
|
|
23
|
+
### 🧱 Updated Dependencies
|
|
24
|
+
|
|
25
|
+
- Updated iris-app-build-utilities to 1.7.9
|
|
26
|
+
- Updated iris-app-webpack-plugin to 1.7.9
|
|
27
|
+
- Updated iris-app-api to 1.7.9
|
|
28
|
+
- Updated react-test-setup to 1.4.8
|
|
29
|
+
- Updated shared-utils to 1.9.8
|
|
30
|
+
|
|
1
31
|
## 1.7.8 (2025-10-01)
|
|
2
32
|
|
|
3
33
|
### 🧱 Updated Dependencies
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trackunit/iris-app",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.11",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"generators": "./generators.json",
|
|
@@ -32,12 +32,12 @@
|
|
|
32
32
|
"@npmcli/arborist": "^7.3.1",
|
|
33
33
|
"webpack-bundle-analyzer": "^4.8.0",
|
|
34
34
|
"win-ca": "^3.5.1",
|
|
35
|
-
"@trackunit/iris-app-build-utilities": "1.7.
|
|
36
|
-
"@trackunit/shared-utils": "1.9.
|
|
37
|
-
"@trackunit/iris-app-api": "1.7.
|
|
38
|
-
"@trackunit/iris-app-webpack-plugin": "1.7.
|
|
35
|
+
"@trackunit/iris-app-build-utilities": "1.7.11",
|
|
36
|
+
"@trackunit/shared-utils": "1.9.10",
|
|
37
|
+
"@trackunit/iris-app-api": "1.7.11",
|
|
38
|
+
"@trackunit/iris-app-webpack-plugin": "1.7.11",
|
|
39
39
|
"tslib": "^2.6.2",
|
|
40
|
-
"@trackunit/react-test-setup": "1.4.
|
|
40
|
+
"@trackunit/react-test-setup": "1.4.10"
|
|
41
41
|
},
|
|
42
42
|
"types": "./src/index.d.ts",
|
|
43
43
|
"type": "commonjs"
|
|
@@ -146,7 +146,7 @@ const config = useWidgetConfig();
|
|
|
146
146
|
|
|
147
147
|
**`useWidgetConfigAsync()`** - Access widget configuration (asynchronous)
|
|
148
148
|
```typescript
|
|
149
|
-
const {
|
|
149
|
+
const { getData, setData } = useWidgetConfigAsync();
|
|
150
150
|
const config = await getConfig();
|
|
151
151
|
```
|
|
152
152
|
|
|
@@ -66,7 +66,7 @@ const widgetExtensionManifest: WidgetExtensionManifest = {
|
|
|
66
66
|
description: "Displays chart data for analysis",
|
|
67
67
|
},
|
|
68
68
|
|
|
69
|
-
supportedLocations: ["MY_HOME", "
|
|
69
|
+
supportedLocations: ["MY_HOME", "PLAYGROUND"],
|
|
70
70
|
|
|
71
71
|
supportedFilters: { // Optional: Enable filter support
|
|
72
72
|
TIME_RANGE: { include: ["ALL"] },
|
|
@@ -115,6 +115,8 @@ export const App = () => {
|
|
|
115
115
|
isEditMode,
|
|
116
116
|
openEditMode,
|
|
117
117
|
closeEditMode
|
|
118
|
+
pollInterval,
|
|
119
|
+
setLoadingState
|
|
118
120
|
} = useWidgetConfig();
|
|
119
121
|
|
|
120
122
|
if (isEditMode) {
|
|
@@ -122,10 +124,10 @@ export const App = () => {
|
|
|
122
124
|
}
|
|
123
125
|
|
|
124
126
|
return (
|
|
125
|
-
<
|
|
127
|
+
<WidgetBody>
|
|
126
128
|
<h2>{title}</h2>
|
|
127
129
|
{/* Widget content */}
|
|
128
|
-
</
|
|
130
|
+
</WidgetBody>
|
|
129
131
|
);
|
|
130
132
|
};
|
|
131
133
|
```
|
|
@@ -276,7 +278,7 @@ import { useWidgetConfig } from '@trackunit/react-core-hooks';
|
|
|
276
278
|
import { useQuery } from '@apollo/client';
|
|
277
279
|
|
|
278
280
|
export const App = () => {
|
|
279
|
-
const { filters, timeRange, data } = useWidgetConfig();
|
|
281
|
+
const { filters, timeRange, data, pollInterval, setLoadingState} = useWidgetConfig();
|
|
280
282
|
|
|
281
283
|
const { data: kpiData, loading } = useQuery(MY_KPI_QUERY, {
|
|
282
284
|
variables: {
|
|
@@ -288,9 +290,12 @@ export const App = () => {
|
|
|
288
290
|
},
|
|
289
291
|
},
|
|
290
292
|
},
|
|
293
|
+
pollInterval
|
|
291
294
|
});
|
|
292
295
|
|
|
293
|
-
|
|
296
|
+
useEffect(() => {
|
|
297
|
+
void setLoadingState({ hasData: !!kpiData, isLoading: loading });
|
|
298
|
+
}, [data, loading, setLoadingState]);
|
|
294
299
|
|
|
295
300
|
return (
|
|
296
301
|
<div className="kpi-widget">
|