@xiaohaih/condition-core
Advanced tools
Comparing version 0.5.0 to 0.5.1
# @xiaohaih/condition-core | ||
## 0.5.1 | ||
### Patch Changes | ||
- 删除 realtimeFlag 内部已做值相同时忽略后续逻辑的处理 | ||
## 0.5.0 | ||
@@ -4,0 +10,0 @@ |
{ | ||
"name": "@xiaohaih/condition-core", | ||
"version": "0.5.0", | ||
"version": "0.5.1", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.cjs.js", |
@@ -55,5 +55,5 @@ import { | ||
// 防止触发搜索时, query 产生变化内部重复赋值 | ||
const { flag: realtimeFlag, updateFlag: updateRealtimeFlag } = useDisableInCurrentCycle(); | ||
// const { flag: realtimeFlag, updateFlag: updateRealtimeFlag } = useDisableInCurrentCycle(); | ||
// 防止触发搜索时, backfill 产生变化内部重复赋值 | ||
const { flag: backfillFlag, updateFlag: updateBackfillFlag } = useDisableInCurrentCycle(); | ||
// const { flag: backfillFlag, updateFlag: updateBackfillFlag } = useDisableInCurrentCycle(); | ||
@@ -63,8 +63,8 @@ const option = defineCommonMethod({ | ||
const { multiple } = props; | ||
updateRealtimeFlag(); | ||
updateBackfillFlag(); | ||
// updateRealtimeFlag(); | ||
// updateBackfillFlag(); | ||
checked.value = (props.resetToInitialValue && initialValue.value?.slice()) || (multiple ? [] : ''); | ||
}, | ||
updateWrapperQuery() { | ||
updateRealtimeFlag(); | ||
// updateRealtimeFlag(); | ||
wrapper && Object.entries(getQuery()).forEach(([k, v]) => wrapper.updateQueryValue(k, v, props.field)); | ||
@@ -83,2 +83,5 @@ }, | ||
option.updateWrapperQuery(); | ||
// fix: 初始更新值且外部也设置值时 | ||
// 会导致内部无法同步到最新值 | ||
// realtimeFlag.value = true; | ||
} | ||
@@ -110,3 +113,3 @@ | ||
// 仅在值发生变化时同步 忽视空值不一致的问题 | ||
if (!realtimeFlag.value) return; | ||
// if (!realtimeFlag.value) return; | ||
const _val = props.backfillToValue(val, _field, props.query); | ||
@@ -150,3 +153,3 @@ if (_field.toString() !== __field.toString() || isEqualExcludeEmptyValue(_val, checked.value)) return; | ||
([_depend, _dependFields], [__depend, __dependFields]) => { | ||
if (!realtimeFlag.value) return; | ||
// if (!realtimeFlag.value) return; | ||
// 是否启用依赖, 相同时启用才走后续逻辑, 不同时直接走后续逻辑 | ||
@@ -153,0 +156,0 @@ if (_depend === __depend && !_depend) return; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
3
68189
20
1111
1