@jsonforms/core 3.2.1 → 3.3.0-alpha.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.
|
@@ -21,6 +21,7 @@ var isArray = require('lodash/isArray');
|
|
|
21
21
|
var reduce = require('lodash/reduce');
|
|
22
22
|
var toPairs = require('lodash/toPairs');
|
|
23
23
|
var includes = require('lodash/includes');
|
|
24
|
+
var isUndefined = require('lodash/isUndefined');
|
|
24
25
|
var find = require('lodash/find');
|
|
25
26
|
var range = require('lodash/range');
|
|
26
27
|
var has = require('lodash/has');
|
|
@@ -48,6 +49,7 @@ var isArray__default = /*#__PURE__*/_interopDefaultLegacy(isArray);
|
|
|
48
49
|
var reduce__default = /*#__PURE__*/_interopDefaultLegacy(reduce);
|
|
49
50
|
var toPairs__default = /*#__PURE__*/_interopDefaultLegacy(toPairs);
|
|
50
51
|
var includes__default = /*#__PURE__*/_interopDefaultLegacy(includes);
|
|
52
|
+
var isUndefined__default = /*#__PURE__*/_interopDefaultLegacy(isUndefined);
|
|
51
53
|
var find__default = /*#__PURE__*/_interopDefaultLegacy(find);
|
|
52
54
|
var range__default = /*#__PURE__*/_interopDefaultLegacy(range);
|
|
53
55
|
var has__default = /*#__PURE__*/_interopDefaultLegacy(has);
|
|
@@ -1005,6 +1007,15 @@ var optionIs = function (optionName, optionValue) {
|
|
|
1005
1007
|
return !isEmpty__default["default"](options) && options[optionName] === optionValue;
|
|
1006
1008
|
};
|
|
1007
1009
|
};
|
|
1010
|
+
var hasOption = function (optionName) {
|
|
1011
|
+
return function (uischema) {
|
|
1012
|
+
if (isEmpty__default["default"](uischema)) {
|
|
1013
|
+
return false;
|
|
1014
|
+
}
|
|
1015
|
+
var options = uischema.options;
|
|
1016
|
+
return !isEmpty__default["default"](options) && !isUndefined__default["default"](options[optionName]);
|
|
1017
|
+
};
|
|
1018
|
+
};
|
|
1008
1019
|
var scopeEndsWith = function (expected) {
|
|
1009
1020
|
return function (uischema) {
|
|
1010
1021
|
if (isEmpty__default["default"](expected) || !isControl(uischema)) {
|
|
@@ -1215,6 +1226,7 @@ var index$1 = /*#__PURE__*/Object.freeze({
|
|
|
1215
1226
|
formatIs: formatIs,
|
|
1216
1227
|
uiTypeIs: uiTypeIs,
|
|
1217
1228
|
optionIs: optionIs,
|
|
1229
|
+
hasOption: hasOption,
|
|
1218
1230
|
scopeEndsWith: scopeEndsWith,
|
|
1219
1231
|
scopeEndIs: scopeEndIs,
|
|
1220
1232
|
and: and,
|
|
@@ -2678,6 +2690,7 @@ exports.getUISchemas = getUISchemas;
|
|
|
2678
2690
|
exports.getUiSchema = getUiSchema;
|
|
2679
2691
|
exports.hasCategory = hasCategory;
|
|
2680
2692
|
exports.hasEnableRule = hasEnableRule;
|
|
2693
|
+
exports.hasOption = hasOption;
|
|
2681
2694
|
exports.hasShowRule = hasShowRule;
|
|
2682
2695
|
exports.hasType = hasType;
|
|
2683
2696
|
exports.i18nReducer = i18nReducer;
|