@abgov/jsonforms-components 2.52.5 → 2.52.6
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/index.esm.js +31 -1
- package/package.json +1 -1
- package/renderer-catalog.json +2 -2
package/index.esm.js
CHANGED
|
@@ -9758,6 +9758,24 @@ const GoAInputBaseTableReview = props => {
|
|
|
9758
9758
|
}
|
|
9759
9759
|
let reviewText = data;
|
|
9760
9760
|
const isBoolean = typeof data === 'boolean';
|
|
9761
|
+
const getArrayDisplayValues = () => {
|
|
9762
|
+
var _itemSchema$oneOf;
|
|
9763
|
+
if (!Array.isArray(data)) {
|
|
9764
|
+
return [];
|
|
9765
|
+
}
|
|
9766
|
+
const itemSchema = schema == null ? void 0 : schema.items;
|
|
9767
|
+
const oneOf = (_itemSchema$oneOf = itemSchema == null ? void 0 : itemSchema.oneOf) != null ? _itemSchema$oneOf : [];
|
|
9768
|
+
const titleByConst = new Map();
|
|
9769
|
+
oneOf.forEach(option => {
|
|
9770
|
+
var _option$title;
|
|
9771
|
+
if (!(option != null && option.const)) return;
|
|
9772
|
+
titleByConst.set(option.const, (_option$title = option.title) != null ? _option$title : option.const);
|
|
9773
|
+
});
|
|
9774
|
+
return data.map(value => {
|
|
9775
|
+
const raw = typeof value === 'string' ? value : String(value);
|
|
9776
|
+
return titleByConst.get(raw) || raw;
|
|
9777
|
+
});
|
|
9778
|
+
};
|
|
9761
9779
|
if (isBoolean) {
|
|
9762
9780
|
var _uischema$options2, _uischema$options3;
|
|
9763
9781
|
let checkboxLabel = '';
|
|
@@ -9777,6 +9795,18 @@ const GoAInputBaseTableReview = props => {
|
|
|
9777
9795
|
}
|
|
9778
9796
|
}
|
|
9779
9797
|
}
|
|
9798
|
+
if (Array.isArray(data) && data.length > 0) {
|
|
9799
|
+
const displayValues = getArrayDisplayValues();
|
|
9800
|
+
reviewText = jsx("ul", {
|
|
9801
|
+
style: {
|
|
9802
|
+
margin: 0,
|
|
9803
|
+
paddingLeft: '1.25rem'
|
|
9804
|
+
},
|
|
9805
|
+
children: displayValues.map((value, index) => jsx("li", {
|
|
9806
|
+
children: value
|
|
9807
|
+
}, `${value}-${index}`))
|
|
9808
|
+
});
|
|
9809
|
+
}
|
|
9780
9810
|
// Helper to extract errors manually from global state, bypassing "touched" filter
|
|
9781
9811
|
const normalizePath = p => p.replace(/\[(\d+)\]/g, '.$1').replace(/^\./, '').replace(/\//g, '.');
|
|
9782
9812
|
const findMatchingError = currentErrors => {
|
|
@@ -9850,7 +9880,7 @@ const GoAInputBaseTableReview = props => {
|
|
|
9850
9880
|
children: "Change"
|
|
9851
9881
|
})]
|
|
9852
9882
|
}), jsxs(ReviewValue, {
|
|
9853
|
-
children: [typeof reviewText === 'string' || typeof reviewText === 'number' ? jsx("div", {
|
|
9883
|
+
children: [typeof reviewText === 'string' || typeof reviewText === 'number' || /*#__PURE__*/React.isValidElement(reviewText) ? jsx("div", {
|
|
9854
9884
|
"data-testid": `review-value-${label}`,
|
|
9855
9885
|
children: reviewText
|
|
9856
9886
|
}) : jsx(JsonFormsDispatch, {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abgov/jsonforms-components",
|
|
3
|
-
"version": "2.52.
|
|
3
|
+
"version": "2.52.6",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"description": "Government of Alberta - React renderers for JSON Forms based on the design system.",
|
|
6
6
|
"repository": "https://github.com/GovAlta/adsp-monorepo",
|
package/renderer-catalog.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": "1.0.0",
|
|
3
|
-
"generatedAt": "2026-03-
|
|
4
|
-
"sourceCommit": "
|
|
3
|
+
"generatedAt": "2026-03-12T17:06:12.099Z",
|
|
4
|
+
"sourceCommit": "8e70c36cadefa29ed84a8d37cfaab8454a468304",
|
|
5
5
|
"sourcePath": "libs/jsonforms-components/src/index.ts",
|
|
6
6
|
"rendererCount": 32,
|
|
7
7
|
"renderers": [
|