@react-typed-forms/schemas 15.1.0 → 15.1.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/lib/index.cjs +14 -8
- package/lib/index.cjs.map +1 -1
- package/lib/index.js +11 -8
- package/lib/index.js.map +1 -1
- package/package.json +1 -1
- package/src/controlRender.tsx +10 -8
package/lib/index.cjs
CHANGED
|
@@ -2408,8 +2408,9 @@ var DefaultSchemaInterface = /*#__PURE__*/function () {
|
|
|
2408
2408
|
}();
|
|
2409
2409
|
var defaultSchemaInterface = new DefaultSchemaInterface();
|
|
2410
2410
|
|
|
2411
|
-
var _excluded = ["
|
|
2412
|
-
_excluded2 = ["
|
|
2411
|
+
var _excluded = ["styleClass", "labelClass", "layoutClass"],
|
|
2412
|
+
_excluded2 = ["parentDataNode"],
|
|
2413
|
+
_excluded3 = ["definition", "control", "formOptions", "style", "allowedOptions", "schemaInterface", "styleClass"];
|
|
2413
2414
|
var AppendAdornmentPriority = 0;
|
|
2414
2415
|
var WrapAdornmentPriority = 1000;
|
|
2415
2416
|
/**
|
|
@@ -2584,9 +2585,12 @@ function useControlRendererComponent(controlOrFormNode, renderer, options, paren
|
|
|
2584
2585
|
hiddenControl: myOptionsControl.fields.hidden,
|
|
2585
2586
|
dataContext: dataContext
|
|
2586
2587
|
});
|
|
2587
|
-
var
|
|
2588
|
-
|
|
2589
|
-
|
|
2588
|
+
var styleClass = _options.styleClass,
|
|
2589
|
+
labelClass = _options.labelClass,
|
|
2590
|
+
layoutClass = _options.layoutClass,
|
|
2591
|
+
inheritableOptions = _objectWithoutPropertiesLoose(_options, _excluded);
|
|
2592
|
+
var childOptions = _extends({}, inheritableOptions, myOptions, {
|
|
2593
|
+
elementIndex: undefined
|
|
2590
2594
|
});
|
|
2591
2595
|
react.useEffect(function () {
|
|
2592
2596
|
if (control && typeof myOptions.disabled === "boolean" && control.disabled != myOptions.disabled) control.disabled = myOptions.disabled;
|
|
@@ -2610,13 +2614,15 @@ function useControlRendererComponent(controlOrFormNode, renderer, options, paren
|
|
|
2610
2614
|
var overrideClasses = getGroupClassOverrides(c);
|
|
2611
2615
|
var _ref4 = options != null ? options : {},
|
|
2612
2616
|
parentDataNode = _ref4.parentDataNode,
|
|
2613
|
-
renderOptions = _objectWithoutPropertiesLoose(_ref4,
|
|
2617
|
+
renderOptions = _objectWithoutPropertiesLoose(_ref4, _excluded2);
|
|
2614
2618
|
var dContext = (_ref5 = parentDataNode != null ? parentDataNode : dataContext.dataNode) != null ? _ref5 : dataContext.parentNode;
|
|
2619
|
+
var allChildOptions = _extends({}, childOptions, overrideClasses, renderOptions);
|
|
2620
|
+
console.log(allChildOptions, overrideClasses);
|
|
2615
2621
|
return /*#__PURE__*/jsxRuntime.jsx(NewControlRenderer, {
|
|
2616
2622
|
definition: child,
|
|
2617
2623
|
renderer: renderer,
|
|
2618
2624
|
parentDataNode: dContext,
|
|
2619
|
-
options:
|
|
2625
|
+
options: allChildOptions
|
|
2620
2626
|
}, k);
|
|
2621
2627
|
},
|
|
2622
2628
|
createDataProps: dataProps,
|
|
@@ -2697,7 +2703,7 @@ function defaultDataProps(_ref9) {
|
|
|
2697
2703
|
_ref9$schemaInterface = _ref9.schemaInterface,
|
|
2698
2704
|
schemaInterface = _ref9$schemaInterface === void 0 ? defaultSchemaInterface : _ref9$schemaInterface,
|
|
2699
2705
|
styleClass = _ref9.styleClass,
|
|
2700
|
-
props = _objectWithoutPropertiesLoose(_ref9,
|
|
2706
|
+
props = _objectWithoutPropertiesLoose(_ref9, _excluded3);
|
|
2701
2707
|
var dataNode = props.dataContext.dataNode;
|
|
2702
2708
|
var field = dataNode.schema.field;
|
|
2703
2709
|
var className = rendererClass(styleClass, definition.styleClass);
|