@rjsf/utils 5.11.1 → 5.11.2
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/dist/index.d.ts +0 -1
- package/dist/utils.cjs.development.js +15 -6
- package/dist/utils.cjs.development.js.map +1 -1
- package/dist/utils.cjs.production.min.js +1 -1
- package/dist/utils.cjs.production.min.js.map +1 -1
- package/dist/utils.esm.js +13 -5
- package/dist/utils.esm.js.map +1 -1
- package/dist/utils.umd.development.js +17 -9
- package/dist/utils.umd.development.js.map +1 -1
- package/dist/utils.umd.production.min.js +1 -1
- package/dist/utils.umd.production.min.js.map +1 -1
- package/package.json +3 -2
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
(function (global, factory) {
|
|
2
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('lodash-es/isPlainObject'), require('lodash-es/isEqualWith'), require('lodash-es/get'), require('lodash-es/isEmpty'), require('jsonpointer'), require('lodash-es/omit'), require('lodash-es/has'), require('lodash-es/isObject'), require('lodash-es/isString'), require('lodash-es/reduce'), require('lodash-es/times'), require('lodash-es/set'), require('lodash-es/
|
|
3
|
-
typeof define === 'function' && define.amd ? define(['exports', 'lodash-es/isPlainObject', 'lodash-es/isEqualWith', 'lodash-es/get', 'lodash-es/isEmpty', 'jsonpointer', 'lodash-es/omit', 'lodash-es/has', 'lodash-es/isObject', 'lodash-es/isString', 'lodash-es/reduce', 'lodash-es/times', 'lodash-es/set', 'lodash-es/
|
|
4
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["@rjsf/utils"] = {}, global.isPlainObject, global.isEqualWith, global.get, global.isEmpty, global.jsonpointer, global.omit, global.has, global.isObject$1, global.isString, global.reduce, global.times, global.set, global.
|
|
5
|
-
})(this, (function (exports, isPlainObject, isEqualWith, get, isEmpty, jsonpointer, omit, has, isObject$1, isString, reduce, times, set,
|
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('lodash-es/isPlainObject'), require('lodash-es/isEqualWith'), require('lodash-es/get'), require('lodash-es/isEmpty'), require('jsonpointer'), require('lodash-es/omit'), require('lodash-es/has'), require('lodash-es/isObject'), require('lodash-es/isString'), require('lodash-es/reduce'), require('lodash-es/times'), require('lodash-es/set'), require('lodash-es/transform'), require('json-schema-merge-allof'), require('lodash-es/union'), require('lodash-es/isEqual'), require('lodash-es'), require('lodash-es/cloneDeep'), require('react/jsx-runtime'), require('react'), require('react-is'), require('lodash-es/toPath'), require('lodash-es/forEach')) :
|
|
3
|
+
typeof define === 'function' && define.amd ? define(['exports', 'lodash-es/isPlainObject', 'lodash-es/isEqualWith', 'lodash-es/get', 'lodash-es/isEmpty', 'jsonpointer', 'lodash-es/omit', 'lodash-es/has', 'lodash-es/isObject', 'lodash-es/isString', 'lodash-es/reduce', 'lodash-es/times', 'lodash-es/set', 'lodash-es/transform', 'json-schema-merge-allof', 'lodash-es/union', 'lodash-es/isEqual', 'lodash-es', 'lodash-es/cloneDeep', 'react/jsx-runtime', 'react', 'react-is', 'lodash-es/toPath', 'lodash-es/forEach'], factory) :
|
|
4
|
+
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["@rjsf/utils"] = {}, global.isPlainObject, global.isEqualWith, global.get, global.isEmpty, global.jsonpointer, global.omit, global.has, global.isObject$1, global.isString, global.reduce, global.times, global.set, global.transform, global.mergeAllOf, global.union, global.isEqual, global.lodashEs, global.cloneDeep, global.jsxRuntime, global.React, global.ReactIs, global.toPath, global.forEach));
|
|
5
|
+
})(this, (function (exports, isPlainObject, isEqualWith, get, isEmpty, jsonpointer, omit, has, isObject$1, isString, reduce, times, set, transform, mergeAllOf, union, isEqual, lodashEs, cloneDeep, jsxRuntime, react, ReactIs, toPath, forEach) { 'use strict';
|
|
6
6
|
|
|
7
7
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
8
8
|
|
|
@@ -18,13 +18,14 @@
|
|
|
18
18
|
var reduce__default = /*#__PURE__*/_interopDefaultLegacy(reduce);
|
|
19
19
|
var times__default = /*#__PURE__*/_interopDefaultLegacy(times);
|
|
20
20
|
var set__default = /*#__PURE__*/_interopDefaultLegacy(set);
|
|
21
|
-
var
|
|
21
|
+
var transform__default = /*#__PURE__*/_interopDefaultLegacy(transform);
|
|
22
22
|
var mergeAllOf__default = /*#__PURE__*/_interopDefaultLegacy(mergeAllOf);
|
|
23
23
|
var union__default = /*#__PURE__*/_interopDefaultLegacy(union);
|
|
24
24
|
var isEqual__default = /*#__PURE__*/_interopDefaultLegacy(isEqual);
|
|
25
25
|
var cloneDeep__default = /*#__PURE__*/_interopDefaultLegacy(cloneDeep);
|
|
26
26
|
var ReactIs__default = /*#__PURE__*/_interopDefaultLegacy(ReactIs);
|
|
27
27
|
var toPath__default = /*#__PURE__*/_interopDefaultLegacy(toPath);
|
|
28
|
+
var forEach__default = /*#__PURE__*/_interopDefaultLegacy(forEach);
|
|
28
29
|
|
|
29
30
|
/** Determines whether a `thing` is an object for the purposes of RSJF. In this case, `thing` is an object if it has
|
|
30
31
|
* the type `object` but is NOT null, an array or a File.
|
|
@@ -631,12 +632,19 @@
|
|
|
631
632
|
};
|
|
632
633
|
}
|
|
633
634
|
if (PROPERTIES_KEY in resolvedSchema) {
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
});
|
|
635
|
+
const updatedProps = transform__default["default"](resolvedSchema[PROPERTIES_KEY], (result, value, key) => {
|
|
636
|
+
result[key] = resolveAllReferences(value, rootSchema);
|
|
637
|
+
}, {});
|
|
638
|
+
resolvedSchema = {
|
|
639
|
+
...resolvedSchema,
|
|
640
|
+
[PROPERTIES_KEY]: updatedProps
|
|
641
|
+
};
|
|
637
642
|
}
|
|
638
643
|
if (ITEMS_KEY in resolvedSchema && !Array.isArray(resolvedSchema.items) && typeof resolvedSchema.items !== 'boolean') {
|
|
639
|
-
resolvedSchema
|
|
644
|
+
resolvedSchema = {
|
|
645
|
+
...resolvedSchema,
|
|
646
|
+
items: resolveAllReferences(resolvedSchema.items, rootSchema)
|
|
647
|
+
};
|
|
640
648
|
}
|
|
641
649
|
return resolvedSchema;
|
|
642
650
|
}
|