@jsonforms/core 3.0.0-beta.4 → 3.0.0-rc.1
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/docs/assets/js/search.json +1 -1
- package/docs/enums/ruleeffect.html +4 -4
- package/docs/globals.html +335 -110
- package/docs/index.html +43 -4
- package/docs/interfaces/andcondition.html +2 -2
- package/docs/interfaces/arraycontrolprops.html +21 -21
- package/docs/interfaces/arraylayoutprops.html +21 -21
- package/docs/interfaces/categorization.html +24 -16
- package/docs/interfaces/category.html +24 -16
- package/docs/interfaces/cellprops.html +12 -12
- package/docs/interfaces/combinatorrendererprops.html +18 -18
- package/docs/interfaces/composablecondition.html +2 -2
- package/docs/interfaces/condition.html +1 -1
- package/docs/interfaces/controlelement.html +21 -16
- package/docs/interfaces/controlprops.html +16 -16
- package/docs/interfaces/controlstate.html +2 -2
- package/docs/interfaces/controlwithdetailprops.html +17 -17
- package/docs/interfaces/dispatchcellprops.html +10 -10
- package/docs/interfaces/dispatchcellstateprops.html +10 -10
- package/docs/interfaces/dispatchpropsofarraycontrol.html +4 -4
- package/docs/interfaces/dispatchpropsofcontrol.html +1 -1
- package/docs/interfaces/dispatchpropsofmultienumcontrol.html +2 -2
- package/docs/interfaces/enumcellprops.html +13 -13
- package/docs/interfaces/enumoption.html +2 -2
- package/docs/interfaces/grouplayout.html +24 -12
- package/docs/interfaces/horizontallayout.html +4 -4
- package/docs/interfaces/internationalizable.html +4 -10
- package/docs/interfaces/jsonformsprops.html +24 -9
- package/docs/interfaces/labelable.html +184 -0
- package/docs/interfaces/labeldescription.html +2 -2
- package/docs/interfaces/labeled.html +182 -0
- package/docs/interfaces/labelelement.html +22 -4
- package/docs/interfaces/labelprops.html +339 -0
- package/docs/interfaces/layout.html +4 -4
- package/docs/interfaces/layoutprops.html +25 -10
- package/docs/interfaces/leafcondition.html +9 -8
- package/docs/interfaces/orcondition.html +2 -2
- package/docs/interfaces/ownpropsofcell.html +9 -9
- package/docs/interfaces/ownpropsofcontrol.html +9 -9
- package/docs/interfaces/ownpropsofenum.html +1 -1
- package/docs/interfaces/ownpropsofenumcell.html +10 -10
- package/docs/interfaces/ownpropsofjsonformsrenderer.html +8 -8
- package/docs/interfaces/ownpropsoflabel.html +286 -0
- package/docs/interfaces/ownpropsoflayout.html +9 -9
- package/docs/interfaces/ownpropsofmasterlistitem.html +6 -6
- package/docs/interfaces/ownpropsofrenderer.html +11 -8
- package/docs/interfaces/rendererprops.html +9 -9
- package/docs/interfaces/rule.html +2 -2
- package/docs/interfaces/schemabasedcondition.html +9 -8
- package/docs/interfaces/scopable.html +3 -9
- package/docs/interfaces/scoped.html +183 -0
- package/docs/interfaces/statepropsofarraycontrol.html +17 -17
- package/docs/interfaces/statepropsofarraylayout.html +17 -17
- package/docs/interfaces/statepropsofcell.html +11 -11
- package/docs/interfaces/statepropsofcombinator.html +17 -17
- package/docs/interfaces/statepropsofcontrol.html +15 -15
- package/docs/interfaces/statepropsofcontrolwithdetail.html +16 -16
- package/docs/interfaces/statepropsofenumcell.html +12 -12
- package/docs/interfaces/statepropsofjsonformsrenderer.html +23 -9
- package/docs/interfaces/statepropsoflabel.html +343 -0
- package/docs/interfaces/statepropsoflayout.html +24 -10
- package/docs/interfaces/statepropsofmasteritem.html +7 -7
- package/docs/interfaces/statepropsofrenderer.html +12 -9
- package/docs/interfaces/statepropsofscopedrenderer.html +12 -12
- package/docs/interfaces/testercontext.html +184 -0
- package/docs/interfaces/uischemaelement.html +3 -3
- package/docs/interfaces/verticallayout.html +4 -4
- package/docs/interfaces/withclassname.html +1 -1
- package/lib/i18n/i18nUtil.d.ts +9 -4
- package/lib/jsonforms-core.cjs.js +103 -49
- package/lib/jsonforms-core.cjs.js.map +1 -1
- package/lib/jsonforms-core.esm.js +89 -52
- package/lib/jsonforms-core.esm.js.map +1 -1
- package/lib/models/uischema.d.ts +35 -27
- package/lib/reducers/i18n.d.ts +1 -1
- package/lib/testers/testers.d.ts +15 -6
- package/lib/util/renderer.d.ts +18 -1
- package/lib/util/runtime.d.ts +1 -2
- package/lib/util/util.d.ts +6 -6
- package/package.json +2 -2
- package/src/i18n/i18nUtil.ts +24 -7
- package/src/models/uischema.ts +50 -27
- package/src/reducers/i18n.ts +1 -1
- package/src/testers/testers.ts +44 -34
- package/src/util/path.ts +9 -5
- package/src/util/renderer.ts +61 -28
- package/src/util/runtime.ts +1 -1
- package/src/util/util.ts +8 -8
- package/stats.html +1 -1
- package/test/testers.test.ts +95 -23
- package/test/util/renderer.test.ts +105 -7
|
@@ -337,6 +337,18 @@ var isGroup = function (layout) {
|
|
|
337
337
|
var isLayout = function (uischema) {
|
|
338
338
|
return uischema.elements !== undefined;
|
|
339
339
|
};
|
|
340
|
+
var isScopable = function (obj) {
|
|
341
|
+
return obj && typeof obj === 'object';
|
|
342
|
+
};
|
|
343
|
+
var isScoped = function (obj) {
|
|
344
|
+
return isScopable(obj) && typeof obj.scope === 'string';
|
|
345
|
+
};
|
|
346
|
+
var isLabelable = function (obj) {
|
|
347
|
+
return obj && typeof obj === 'object';
|
|
348
|
+
};
|
|
349
|
+
var isLabeled = function (obj) {
|
|
350
|
+
return isLabelable(obj) && ['string', 'boolean'].includes(typeof obj.label);
|
|
351
|
+
};
|
|
340
352
|
|
|
341
353
|
var move = function (array, index, delta) {
|
|
342
354
|
var newIndex = index + delta;
|
|
@@ -732,6 +744,18 @@ var getCombinedErrorMessage = function (errors, et, t, schema, uischema, path) {
|
|
|
732
744
|
}
|
|
733
745
|
return formatErrorMessage(errors.map(function (error) { return et(error, t, uischema); }));
|
|
734
746
|
};
|
|
747
|
+
var deriveLabelForUISchemaElement = function (uischema, t) {
|
|
748
|
+
if (uischema.label === false) {
|
|
749
|
+
return undefined;
|
|
750
|
+
}
|
|
751
|
+
if ((uischema.label === undefined || uischema.label === null || uischema.label === true) && !isInternationalized(uischema)) {
|
|
752
|
+
return undefined;
|
|
753
|
+
}
|
|
754
|
+
var stringifiedLabel = typeof uischema.label === 'string' ? uischema.label : JSON.stringify(uischema.label);
|
|
755
|
+
var i18nKeyPrefix = getI18nKeyPrefixBySchema(undefined, uischema);
|
|
756
|
+
var i18nKey = typeof i18nKeyPrefix === 'string' ? i18nKeyPrefix + ".label" : stringifiedLabel;
|
|
757
|
+
return t(i18nKey, stringifiedLabel, { uischema: uischema });
|
|
758
|
+
};
|
|
735
759
|
|
|
736
760
|
var defaultJsonFormsI18nState = {
|
|
737
761
|
locale: 'en',
|
|
@@ -800,7 +824,7 @@ var NOT_APPLICABLE = -1;
|
|
|
800
824
|
var isControl = function (uischema) {
|
|
801
825
|
return !isEmpty__default["default"](uischema) && uischema.scope !== undefined;
|
|
802
826
|
};
|
|
803
|
-
var schemaMatches = function (predicate) { return function (uischema, schema,
|
|
827
|
+
var schemaMatches = function (predicate) { return function (uischema, schema, context) {
|
|
804
828
|
if (isEmpty__default["default"](uischema) || !isControl(uischema)) {
|
|
805
829
|
return false;
|
|
806
830
|
}
|
|
@@ -813,27 +837,27 @@ var schemaMatches = function (predicate) { return function (uischema, schema, ro
|
|
|
813
837
|
}
|
|
814
838
|
var currentDataSchema = schema;
|
|
815
839
|
if (hasType(schema, 'object')) {
|
|
816
|
-
currentDataSchema = resolveSchema(schema, schemaPath, rootSchema);
|
|
840
|
+
currentDataSchema = resolveSchema(schema, schemaPath, context === null || context === void 0 ? void 0 : context.rootSchema);
|
|
817
841
|
}
|
|
818
842
|
if (currentDataSchema === undefined) {
|
|
819
843
|
return false;
|
|
820
844
|
}
|
|
821
|
-
return predicate(currentDataSchema, rootSchema);
|
|
845
|
+
return predicate(currentDataSchema, context === null || context === void 0 ? void 0 : context.rootSchema);
|
|
822
846
|
}; };
|
|
823
|
-
var schemaSubPathMatches = function (subPath, predicate) { return function (uischema, schema,
|
|
847
|
+
var schemaSubPathMatches = function (subPath, predicate) { return function (uischema, schema, context) {
|
|
824
848
|
if (isEmpty__default["default"](uischema) || !isControl(uischema)) {
|
|
825
849
|
return false;
|
|
826
850
|
}
|
|
827
851
|
var schemaPath = uischema.scope;
|
|
828
852
|
var currentDataSchema = schema;
|
|
829
853
|
if (hasType(schema, 'object')) {
|
|
830
|
-
currentDataSchema = resolveSchema(schema, schemaPath, rootSchema);
|
|
854
|
+
currentDataSchema = resolveSchema(schema, schemaPath, context === null || context === void 0 ? void 0 : context.rootSchema);
|
|
831
855
|
}
|
|
832
856
|
currentDataSchema = get__default["default"](currentDataSchema, subPath);
|
|
833
857
|
if (currentDataSchema === undefined) {
|
|
834
858
|
return false;
|
|
835
859
|
}
|
|
836
|
-
return predicate(currentDataSchema, rootSchema);
|
|
860
|
+
return predicate(currentDataSchema, context === null || context === void 0 ? void 0 : context.rootSchema);
|
|
837
861
|
}; };
|
|
838
862
|
var schemaTypeIs = function (expectedType) {
|
|
839
863
|
return schemaMatches(function (schema) { return !isEmpty__default["default"](schema) && hasType(schema, expectedType); });
|
|
@@ -871,23 +895,23 @@ var and = function () {
|
|
|
871
895
|
for (var _i = 0; _i < arguments.length; _i++) {
|
|
872
896
|
testers[_i] = arguments[_i];
|
|
873
897
|
}
|
|
874
|
-
return function (uischema, schema,
|
|
898
|
+
return function (uischema, schema, context) { return testers.reduce(function (acc, tester) { return acc && tester(uischema, schema, context); }, true); };
|
|
875
899
|
};
|
|
876
900
|
var or = function () {
|
|
877
901
|
var testers = [];
|
|
878
902
|
for (var _i = 0; _i < arguments.length; _i++) {
|
|
879
903
|
testers[_i] = arguments[_i];
|
|
880
904
|
}
|
|
881
|
-
return function (uischema, schema,
|
|
905
|
+
return function (uischema, schema, context) { return testers.reduce(function (acc, tester) { return acc || tester(uischema, schema, context); }, false); };
|
|
882
906
|
};
|
|
883
|
-
var rankWith = function (rank, tester) { return function (uischema, schema,
|
|
884
|
-
if (tester(uischema, schema,
|
|
907
|
+
var rankWith = function (rank, tester) { return function (uischema, schema, context) {
|
|
908
|
+
if (tester(uischema, schema, context)) {
|
|
885
909
|
return rank;
|
|
886
910
|
}
|
|
887
911
|
return NOT_APPLICABLE;
|
|
888
912
|
}; };
|
|
889
|
-
var withIncreasedRank = function (by, rankedTester) { return function (uischema, schema,
|
|
890
|
-
var rank = rankedTester(uischema, schema,
|
|
913
|
+
var withIncreasedRank = function (by, rankedTester) { return function (uischema, schema, context) {
|
|
914
|
+
var rank = rankedTester(uischema, schema, context);
|
|
891
915
|
if (rank === NOT_APPLICABLE) {
|
|
892
916
|
return NOT_APPLICABLE;
|
|
893
917
|
}
|
|
@@ -940,16 +964,14 @@ var traverse = function (any, pred, rootSchema) {
|
|
|
940
964
|
}
|
|
941
965
|
return false;
|
|
942
966
|
};
|
|
943
|
-
var isObjectArrayWithNesting = function (uischema, schema,
|
|
944
|
-
|
|
967
|
+
var isObjectArrayWithNesting = function (uischema, schema, context) {
|
|
968
|
+
var _a;
|
|
969
|
+
if (!uiTypeIs('Control')(uischema, schema, context)) {
|
|
945
970
|
return false;
|
|
946
971
|
}
|
|
947
972
|
var schemaPath = uischema.scope;
|
|
948
|
-
var resolvedSchema = resolveSchema(schema, schemaPath, rootSchema !== null &&
|
|
949
|
-
var
|
|
950
|
-
object: 2,
|
|
951
|
-
array: 1
|
|
952
|
-
};
|
|
973
|
+
var resolvedSchema = resolveSchema(schema, schemaPath, (_a = context === null || context === void 0 ? void 0 : context.rootSchema) !== null && _a !== void 0 ? _a : schema);
|
|
974
|
+
var objectDepth = 0;
|
|
953
975
|
if (resolvedSchema !== undefined && resolvedSchema.items !== undefined) {
|
|
954
976
|
if (traverse(resolvedSchema.items, function (val) {
|
|
955
977
|
if (val === schema) {
|
|
@@ -958,16 +980,20 @@ var isObjectArrayWithNesting = function (uischema, schema, rootSchema) {
|
|
|
958
980
|
if (val.$ref !== undefined) {
|
|
959
981
|
return false;
|
|
960
982
|
}
|
|
961
|
-
if (
|
|
983
|
+
if (val.anyOf || val.oneOf) {
|
|
962
984
|
return true;
|
|
963
985
|
}
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
986
|
+
if (hasType(val, 'object')) {
|
|
987
|
+
objectDepth++;
|
|
988
|
+
if (objectDepth === 2) {
|
|
989
|
+
return true;
|
|
990
|
+
}
|
|
967
991
|
}
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
992
|
+
if (hasType(val, 'array')) {
|
|
993
|
+
return true;
|
|
994
|
+
}
|
|
995
|
+
return false;
|
|
996
|
+
}, context === null || context === void 0 ? void 0 : context.rootSchema)) {
|
|
971
997
|
return true;
|
|
972
998
|
}
|
|
973
999
|
if (uischema.options && uischema.options.detail) {
|
|
@@ -1016,7 +1042,7 @@ var hasCategory = function (categorization) {
|
|
|
1016
1042
|
var categorizationHasCategory = function (uischema) {
|
|
1017
1043
|
return hasCategory(uischema);
|
|
1018
1044
|
};
|
|
1019
|
-
var not = function (tester) { return function (uischema, schema,
|
|
1045
|
+
var not = function (tester) { return function (uischema, schema, context) { return !tester(uischema, schema, context); }; };
|
|
1020
1046
|
|
|
1021
1047
|
var index$1 = /*#__PURE__*/Object.freeze({
|
|
1022
1048
|
__proto__: null,
|
|
@@ -1181,11 +1207,14 @@ var toDataPath = function (schemaPath) {
|
|
|
1181
1207
|
return toDataPathSegments(schemaPath).join('.');
|
|
1182
1208
|
};
|
|
1183
1209
|
var composeWithUi = function (scopableUi, path) {
|
|
1210
|
+
if (!isScoped(scopableUi)) {
|
|
1211
|
+
return path !== null && path !== void 0 ? path : '';
|
|
1212
|
+
}
|
|
1184
1213
|
var segments = toDataPathSegments(scopableUi.scope);
|
|
1185
|
-
if (isEmpty__default["default"](segments)
|
|
1186
|
-
return '';
|
|
1214
|
+
if (isEmpty__default["default"](segments)) {
|
|
1215
|
+
return path !== null && path !== void 0 ? path : '';
|
|
1187
1216
|
}
|
|
1188
|
-
return
|
|
1217
|
+
return compose(path, segments.join('.'));
|
|
1189
1218
|
};
|
|
1190
1219
|
var encode = function (segment) { return segment === null || segment === void 0 ? void 0 : segment.replace(/~/g, '~0').replace(/\//g, '~1'); };
|
|
1191
1220
|
var decode = function (pointerSegment) { return pointerSegment === null || pointerSegment === void 0 ? void 0 : pointerSegment.replace(/~1/g, '/').replace(/~0/, '~'); };
|
|
@@ -1440,12 +1469,12 @@ var Resolve = {
|
|
|
1440
1469
|
schema: resolveSchema,
|
|
1441
1470
|
data: resolveData
|
|
1442
1471
|
};
|
|
1443
|
-
var
|
|
1472
|
+
var fromScoped = function (scopable) {
|
|
1444
1473
|
return toDataPathSegments(scopable.scope).join('.');
|
|
1445
1474
|
};
|
|
1446
1475
|
var Paths = {
|
|
1447
1476
|
compose: compose,
|
|
1448
|
-
|
|
1477
|
+
fromScoped: fromScoped
|
|
1449
1478
|
};
|
|
1450
1479
|
var Runtime = {
|
|
1451
1480
|
isEnabled: function (uischema, data, ajv) {
|
|
@@ -1753,32 +1782,28 @@ var mapStateToLayoutProps = function (state, ownProps) {
|
|
|
1753
1782
|
var config = getConfig(state);
|
|
1754
1783
|
var enabled = isInherentlyEnabled(state, ownProps, uischema, undefined,
|
|
1755
1784
|
rootData, config);
|
|
1785
|
+
var t = getTranslator()(state);
|
|
1786
|
+
var label = isLabelable(uischema) ? deriveLabelForUISchemaElement(uischema, t) : undefined;
|
|
1756
1787
|
return __assign(__assign({}, layoutDefaultProps), { renderers: ownProps.renderers || getRenderers(state), cells: ownProps.cells || getCells(state), visible: visible,
|
|
1757
|
-
enabled: enabled, path: ownProps.path, data: data, uischema: ownProps.uischema, schema: ownProps.schema, direction: (_a = ownProps.direction) !== null && _a !== void 0 ? _a : getDirection(uischema), config: config
|
|
1788
|
+
enabled: enabled, path: ownProps.path, data: data, uischema: ownProps.uischema, schema: ownProps.schema, direction: (_a = ownProps.direction) !== null && _a !== void 0 ? _a : getDirection(uischema), config: config,
|
|
1789
|
+
label: label });
|
|
1758
1790
|
};
|
|
1759
1791
|
var mapStateToJsonFormsRendererProps = function (state, ownProps) {
|
|
1760
|
-
var uischema = ownProps.uischema;
|
|
1761
|
-
if (uischema === undefined) {
|
|
1762
|
-
if (ownProps.schema) {
|
|
1763
|
-
uischema = findUISchema(state.jsonforms.uischemas, ownProps.schema, undefined, ownProps.path, undefined, undefined, state.jsonforms.core.schema);
|
|
1764
|
-
}
|
|
1765
|
-
else {
|
|
1766
|
-
uischema = getUiSchema(state);
|
|
1767
|
-
}
|
|
1768
|
-
}
|
|
1769
1792
|
return {
|
|
1770
|
-
renderers: ownProps.renderers || get__default["default"](state.jsonforms, 'renderers')
|
|
1771
|
-
cells: ownProps.cells || get__default["default"](state.jsonforms, 'cells')
|
|
1793
|
+
renderers: ownProps.renderers || get__default["default"](state.jsonforms, 'renderers'),
|
|
1794
|
+
cells: ownProps.cells || get__default["default"](state.jsonforms, 'cells'),
|
|
1772
1795
|
schema: ownProps.schema || getSchema(state),
|
|
1773
1796
|
rootSchema: getSchema(state),
|
|
1774
|
-
uischema: uischema,
|
|
1775
|
-
path: ownProps.path
|
|
1797
|
+
uischema: ownProps.uischema || getUiSchema(state),
|
|
1798
|
+
path: ownProps.path,
|
|
1799
|
+
enabled: ownProps.enabled,
|
|
1800
|
+
config: getConfig(state)
|
|
1776
1801
|
};
|
|
1777
1802
|
};
|
|
1778
1803
|
var controlDefaultProps = __assign(__assign({}, layoutDefaultProps), { errors: [] });
|
|
1779
1804
|
var mapStateToCombinatorRendererProps = function (state, ownProps, keyword) {
|
|
1780
1805
|
var _a;
|
|
1781
|
-
var _b = mapStateToControlProps(state, ownProps), data = _b.data, schema = _b.schema, props = __rest(_b, ["data", "schema"]);
|
|
1806
|
+
var _b = mapStateToControlProps(state, ownProps), data = _b.data, schema = _b.schema, rootSchema = _b.rootSchema, props = __rest(_b, ["data", "schema", "rootSchema"]);
|
|
1782
1807
|
var ajv = state.jsonforms.core.ajv;
|
|
1783
1808
|
var structuralKeywords = [
|
|
1784
1809
|
'required',
|
|
@@ -1795,7 +1820,11 @@ var mapStateToCombinatorRendererProps = function (state, ownProps, keyword) {
|
|
|
1795
1820
|
var indexOfFittingSchema;
|
|
1796
1821
|
for (var i = 0; i < ((_a = schema[keyword]) === null || _a === void 0 ? void 0 : _a.length); i++) {
|
|
1797
1822
|
try {
|
|
1798
|
-
var
|
|
1823
|
+
var _schema = schema[keyword][i];
|
|
1824
|
+
if (_schema.$ref) {
|
|
1825
|
+
_schema = Resolve.schema(rootSchema, _schema.$ref, rootSchema);
|
|
1826
|
+
}
|
|
1827
|
+
var valFn = ajv.compile(_schema);
|
|
1799
1828
|
valFn(data);
|
|
1800
1829
|
if (dataIsValid(valFn.errors)) {
|
|
1801
1830
|
indexOfFittingSchema = i;
|
|
@@ -1807,7 +1836,8 @@ var mapStateToCombinatorRendererProps = function (state, ownProps, keyword) {
|
|
|
1807
1836
|
}
|
|
1808
1837
|
}
|
|
1809
1838
|
return __assign(__assign({ data: data,
|
|
1810
|
-
schema: schema
|
|
1839
|
+
schema: schema,
|
|
1840
|
+
rootSchema: rootSchema }, props), { indexOfFittingSchema: indexOfFittingSchema, uischemas: getUISchemas(state) });
|
|
1811
1841
|
};
|
|
1812
1842
|
var mapStateToAllOfProps = function (state, ownProps) {
|
|
1813
1843
|
return mapStateToCombinatorRendererProps(state, ownProps, 'allOf');
|
|
@@ -1828,6 +1858,24 @@ var mapStateToArrayLayoutProps = function (state, ownProps) {
|
|
|
1828
1858
|
return __assign(__assign({}, props), { path: path,
|
|
1829
1859
|
uischema: uischema, schema: resolvedSchema, data: props.data ? props.data.length : 0, errors: allErrors, minItems: schema.minItems });
|
|
1830
1860
|
};
|
|
1861
|
+
var mapStateToLabelProps = function (state, props) {
|
|
1862
|
+
var uischema = props.uischema;
|
|
1863
|
+
var visible = props.visible === undefined || hasShowRule(uischema)
|
|
1864
|
+
? isVisible(props.uischema, getData(state), props.path, getAjv(state))
|
|
1865
|
+
: props.visible;
|
|
1866
|
+
var text = uischema.text;
|
|
1867
|
+
var t = getTranslator()(state);
|
|
1868
|
+
var i18nKeyPrefix = getI18nKeyPrefixBySchema(undefined, uischema);
|
|
1869
|
+
var i18nKey = i18nKeyPrefix ? i18nKeyPrefix + ".text" : text !== null && text !== void 0 ? text : '';
|
|
1870
|
+
var i18nText = t(i18nKey, text, { uischema: uischema });
|
|
1871
|
+
return {
|
|
1872
|
+
text: i18nText,
|
|
1873
|
+
visible: visible,
|
|
1874
|
+
config: getConfig(state),
|
|
1875
|
+
renderers: props.renderers || getRenderers(state),
|
|
1876
|
+
cells: props.cells || getCells(state),
|
|
1877
|
+
};
|
|
1878
|
+
};
|
|
1831
1879
|
|
|
1832
1880
|
var mapStateToCellProps = function (state, ownProps) {
|
|
1833
1881
|
var id = ownProps.id, schema = ownProps.schema, path = ownProps.path, uischema = ownProps.uischema, renderers = ownProps.renderers, cells = ownProps.cells;
|
|
@@ -2315,6 +2363,7 @@ exports.defaultJsonFormsI18nState = defaultJsonFormsI18nState;
|
|
|
2315
2363
|
exports.defaultMapDispatchToControlProps = defaultMapDispatchToControlProps;
|
|
2316
2364
|
exports.defaultMapStateToEnumCellProps = defaultMapStateToEnumCellProps;
|
|
2317
2365
|
exports.defaultTranslator = defaultTranslator;
|
|
2366
|
+
exports.deriveLabelForUISchemaElement = deriveLabelForUISchemaElement;
|
|
2318
2367
|
exports.deriveTypes = deriveTypes;
|
|
2319
2368
|
exports.encode = encode;
|
|
2320
2369
|
exports.enumToEnumOptionMapper = enumToEnumOptionMapper;
|
|
@@ -2379,6 +2428,8 @@ exports.isGroup = isGroup;
|
|
|
2379
2428
|
exports.isInherentlyEnabled = isInherentlyEnabled;
|
|
2380
2429
|
exports.isIntegerControl = isIntegerControl;
|
|
2381
2430
|
exports.isInternationalized = isInternationalized;
|
|
2431
|
+
exports.isLabelable = isLabelable;
|
|
2432
|
+
exports.isLabeled = isLabeled;
|
|
2382
2433
|
exports.isLayout = isLayout;
|
|
2383
2434
|
exports.isMultiLineControl = isMultiLineControl;
|
|
2384
2435
|
exports.isNumberControl = isNumberControl;
|
|
@@ -2391,6 +2442,8 @@ exports.isOneOfControl = isOneOfControl;
|
|
|
2391
2442
|
exports.isOneOfEnumControl = isOneOfEnumControl;
|
|
2392
2443
|
exports.isPrimitiveArrayControl = isPrimitiveArrayControl;
|
|
2393
2444
|
exports.isRangeControl = isRangeControl;
|
|
2445
|
+
exports.isScopable = isScopable;
|
|
2446
|
+
exports.isScoped = isScoped;
|
|
2394
2447
|
exports.isStringControl = isStringControl;
|
|
2395
2448
|
exports.isTimeControl = isTimeControl;
|
|
2396
2449
|
exports.isVisible = isVisible;
|
|
@@ -2412,6 +2465,7 @@ exports.mapStateToControlWithDetailProps = mapStateToControlWithDetailProps;
|
|
|
2412
2465
|
exports.mapStateToDispatchCellProps = mapStateToDispatchCellProps;
|
|
2413
2466
|
exports.mapStateToEnumControlProps = mapStateToEnumControlProps;
|
|
2414
2467
|
exports.mapStateToJsonFormsRendererProps = mapStateToJsonFormsRendererProps;
|
|
2468
|
+
exports.mapStateToLabelProps = mapStateToLabelProps;
|
|
2415
2469
|
exports.mapStateToLayoutProps = mapStateToLayoutProps;
|
|
2416
2470
|
exports.mapStateToMasterListItemProps = mapStateToMasterListItemProps;
|
|
2417
2471
|
exports.mapStateToMultiEnumControlProps = mapStateToMultiEnumControlProps;
|