@vunk/form 1.1.39 → 1.1.41

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.
@@ -3,7 +3,7 @@ import { bindPropsFactory } from '@vunk/core/shared/utils-vue';
3
3
  import { defineComponent, computed, resolveComponent, openBlock, createBlock, mergeProps, createSlots, withCtx, renderSlot, renderList, resolveDynamicComponent } from 'vue';
4
4
  import { createFormItemBindProps } from '@vunk/form/shared/element-plus';
5
5
  import { useComputedReadonly } from '@vunk/form/composables';
6
- import { isPlainObject, isNotEmptyObject } from '@vunk/core/shared/utils-object';
6
+ import { isPlainObject } from '@vunk/core/shared/utils-object';
7
7
  import { PATTERN_OPTIONS } from '@vunk/form/shared/rules';
8
8
 
9
9
  var __defProp = Object.defineProperty;
@@ -119,7 +119,12 @@ const _sfc_main = defineComponent({
119
119
  }
120
120
  }
121
121
  data = data.filter((rule) => {
122
- return rule && isNotEmptyObject(rule);
122
+ if (!rule)
123
+ return;
124
+ if (isPlainObject(rule)) {
125
+ const enableKeys = Object.keys(rule).filter((key) => !key.startsWith("data-"));
126
+ return enableKeys.length > 0;
127
+ }
123
128
  });
124
129
  data.forEach((rule) => {
125
130
  setDefaultMessage(rule);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vunk/form",
3
- "version": "1.1.39",
3
+ "version": "1.1.41",
4
4
  "description": "",
5
5
  "main": "index.esm.js",
6
6
  "scripts": {