3h1-ui 3.0.0-next.243 → 3.0.0-next.244

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.
Files changed (3) hide show
  1. package/es/index.js +17 -17
  2. package/lib/index.js +17 -17
  3. package/package.json +3 -3
package/es/index.js CHANGED
@@ -12619,26 +12619,26 @@ function useFormEvents({
12619
12619
  const matched = updateData.find(
12620
12620
  (item) => item.field === schemaItem.field
12621
12621
  );
12622
- let merged = matched ? deepMerge$2(schemaItem, matched) : schemaItem;
12623
- const originalProps = merged.componentProps;
12624
- if (typeof originalProps === "function") {
12622
+ const merged = matched ? deepMerge$2(schemaItem, matched) : { ...schemaItem };
12623
+ let originalProps = merged.componentProps;
12624
+ if (typeof originalProps === "function" && merged.component === "Group") {
12625
12625
  const resultProps = originalProps(context);
12626
- if (merged.component === "Group" && resultProps && Array.isArray(resultProps.schemas)) {
12627
- const processedSchemas = processSchemas(
12628
- resultProps.schemas,
12629
- context
12630
- );
12631
- merged.componentProps = (ctx) => ({
12632
- ...originalProps(ctx),
12633
- schemas: processedSchemas
12634
- });
12626
+ if (Array.isArray(resultProps == null ? void 0 : resultProps.schemas)) {
12627
+ processSchemas(resultProps.schemas, context);
12628
+ merged.componentProps = (ctx) => {
12629
+ const finalProps = originalProps(ctx);
12630
+ return {
12631
+ ...finalProps,
12632
+ schemas: processSchemas(finalProps.schemas || [], ctx)
12633
+ };
12634
+ };
12635
12635
  }
12636
12636
  }
12637
- if (merged.componentProps && typeof originalProps === "object" && merged.component === "Group" && Array.isArray(originalProps.schemas)) {
12638
- merged.componentProps.schemas = processSchemas(
12639
- originalProps.schemas,
12640
- context
12641
- );
12637
+ if (typeof originalProps === "object" && merged.component === "Group" && Array.isArray(originalProps == null ? void 0 : originalProps.schemas)) {
12638
+ merged.componentProps = {
12639
+ ...originalProps,
12640
+ schemas: processSchemas(originalProps.schemas, context)
12641
+ };
12642
12642
  }
12643
12643
  return merged;
12644
12644
  });
package/lib/index.js CHANGED
@@ -12643,26 +12643,26 @@ function useFormEvents({
12643
12643
  const matched = updateData.find(
12644
12644
  (item) => item.field === schemaItem.field
12645
12645
  );
12646
- let merged = matched ? utils$1.deepMerge(schemaItem, matched) : schemaItem;
12647
- const originalProps = merged.componentProps;
12648
- if (typeof originalProps === "function") {
12646
+ const merged = matched ? utils$1.deepMerge(schemaItem, matched) : { ...schemaItem };
12647
+ let originalProps = merged.componentProps;
12648
+ if (typeof originalProps === "function" && merged.component === "Group") {
12649
12649
  const resultProps = originalProps(context);
12650
- if (merged.component === "Group" && resultProps && Array.isArray(resultProps.schemas)) {
12651
- const processedSchemas = processSchemas(
12652
- resultProps.schemas,
12653
- context
12654
- );
12655
- merged.componentProps = (ctx) => ({
12656
- ...originalProps(ctx),
12657
- schemas: processedSchemas
12658
- });
12650
+ if (Array.isArray(resultProps == null ? void 0 : resultProps.schemas)) {
12651
+ processSchemas(resultProps.schemas, context);
12652
+ merged.componentProps = (ctx) => {
12653
+ const finalProps = originalProps(ctx);
12654
+ return {
12655
+ ...finalProps,
12656
+ schemas: processSchemas(finalProps.schemas || [], ctx)
12657
+ };
12658
+ };
12659
12659
  }
12660
12660
  }
12661
- if (merged.componentProps && typeof originalProps === "object" && merged.component === "Group" && Array.isArray(originalProps.schemas)) {
12662
- merged.componentProps.schemas = processSchemas(
12663
- originalProps.schemas,
12664
- context
12665
- );
12661
+ if (typeof originalProps === "object" && merged.component === "Group" && Array.isArray(originalProps == null ? void 0 : originalProps.schemas)) {
12662
+ merged.componentProps = {
12663
+ ...originalProps,
12664
+ schemas: processSchemas(originalProps.schemas, context)
12665
+ };
12666
12666
  }
12667
12667
  return merged;
12668
12668
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "3h1-ui",
3
- "version": "3.0.0-next.243",
3
+ "version": "3.0.0-next.244",
4
4
  "description": "",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",
@@ -29,9 +29,9 @@
29
29
  "vue-json-pretty": "^2.2.3",
30
30
  "vxe-table": "4.3.6",
31
31
  "xe-utils": "^3.5.7",
32
- "@shy-plugins/tinymce": "^1.0.6",
32
+ "@shy-plugins/utils": "1.0.0-next.1",
33
33
  "@shy-plugins/use": "1.0.1-next.5",
34
- "@shy-plugins/utils": "1.0.0-next.1"
34
+ "@shy-plugins/tinymce": "^1.0.6"
35
35
  },
36
36
  "types": "es/ui/index.d.ts",
37
37
  "devDependencies": {