bi-components-library 1.1.58 → 1.1.60

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.es.js CHANGED
@@ -22349,21 +22349,27 @@ function qb(e, t, n, r, a = {}, i, s, u, o, l) {
22349
22349
  }
22350
22350
  })), l && Object.keys(l).length > 0) {
22351
22351
  const m = new Set(
22352
- t.filter((x) => x.type === "upload" && x.key).map((x) => x.key)
22353
- ), y = {}, T = /* @__PURE__ */ new Set();
22354
- Object.entries(l).forEach(([x, A]) => {
22355
- Array.isArray(A) && A.some((k, _) => `${x}_${_}` in h) && T.add(x);
22356
- }), Object.entries(l).forEach(([x, A]) => {
22357
- if (!m.has(x))
22358
- if (Array.isArray(A)) {
22359
- if (T.has(x)) return;
22360
- A.forEach((S, k) => {
22361
- S != null && String(S).trim() !== "" && (y[`${x}_${k}`] = String(S));
22362
- });
22363
- } else A != null && String(A).trim() !== "" && (t.find((k) => k.key === x && k.type === "report-url") ? y[`${x}__url`] = String(A) : y[x] = String(A));
22364
- }), Object.entries(y).forEach(([x, A]) => {
22365
- !(x in h) && !c.has(x) && (h[x] = A);
22366
- });
22352
+ t.filter((T) => T.type === "upload" && T.key).map((T) => T.key)
22353
+ ), y = {};
22354
+ Object.entries(l).forEach(([T, x]) => {
22355
+ if (!Array.isArray(x)) return;
22356
+ let A = 0;
22357
+ for (let k = 0; k < x.length; k++)
22358
+ `${T}_${k}` in h && A++;
22359
+ let S = -1;
22360
+ for (let k = 0; k < x.length; k++)
22361
+ g.current.has(`${T}_${k}`) && (S = k);
22362
+ if (console.log(`[hooks][multi-variable] key=${T} nodeValues.length=${x.length} domCount=${A} everMaxIdx=${S}`), S >= A && A < x.length)
22363
+ for (let k = A; k < x.length; k++)
22364
+ c.add(`${T}_${k}`), console.log(`[hooks][multi-variable] 标记已删除: ${T}_${k}`);
22365
+ }), Object.entries(l).forEach(([T, x]) => {
22366
+ m.has(T) || (Array.isArray(x) ? x.forEach((A, S) => {
22367
+ A != null && String(A).trim() !== "" && (y[`${T}_${S}`] = String(A));
22368
+ }) : x != null && String(x).trim() !== "" && (t.find((S) => S.key === T && S.type === "report-url") ? y[`${T}__url`] = String(x) : y[T] = String(x)));
22369
+ }), console.log("[hooks][merge] expandedNodeValues=", JSON.stringify(y)), console.log("[hooks][merge] variableValues(before)=", JSON.stringify(h)), console.log("[hooks][merge] clearedVariableKeys=", [...c]), Object.entries(y).forEach(([T, x]) => {
22370
+ const A = T in h, S = c.has(T);
22371
+ !A && !S ? h[T] = x : console.log(`[hooks][merge] 跳过 ${T}: inVariableValues=${A}(${h[T]}), inCleared=${S}`);
22372
+ }), console.log("[hooks][merge] variableValues(after)=", JSON.stringify(h));
22367
22373
  }
22368
22374
  if ($b(
22369
22375
  e,