@whitesev/utils 1.4.2 → 1.4.3

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.umd.js CHANGED
@@ -3063,7 +3063,7 @@
3063
3063
  UtilsCore.init(option);
3064
3064
  }
3065
3065
  /** 版本号 */
3066
- version = "2024.6.10";
3066
+ version = "2024.6.11";
3067
3067
  addStyle(cssText) {
3068
3068
  if (typeof cssText !== "string") {
3069
3069
  throw new Error("Utils.addStyle 参数cssText 必须为String类型");
@@ -4662,6 +4662,7 @@
4662
4662
  */
4663
4663
  characterDataOldValue: void 0,
4664
4664
  },
4665
+ immediate: false,
4665
4666
  };
4666
4667
  observer_config = UtilsContext.assign(default_obverser_config, observer_config);
4667
4668
  let windowMutationObserver = window.MutationObserver ||
@@ -4690,6 +4691,10 @@
4690
4691
  /* 未知 */
4691
4692
  console.error("Utils.mutationObserver 未知参数", arguments);
4692
4693
  }
4694
+ if (observer_config.immediate) {
4695
+ /* 主动触发一次 */
4696
+ observer_config.callback([], mutationObserver);
4697
+ }
4693
4698
  return mutationObserver;
4694
4699
  }
4695
4700
  /**