@design.estate/dees-domtools 2.0.40 → 2.0.42

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.
@@ -12792,7 +12792,7 @@ var deepEqualObjects = (object1, object2) => {
12792
12792
  return object1String === object2String;
12793
12793
  };
12794
12794
 
12795
- // node_modules/.pnpm/@push.rocks+webstore@2.0.9/node_modules/@push.rocks/webstore/dist_ts/index.js
12795
+ // node_modules/.pnpm/@push.rocks+webstore@2.0.13/node_modules/@push.rocks/webstore/dist_ts/index.js
12796
12796
  var dist_ts_exports11 = {};
12797
12797
  __export(dist_ts_exports11, {
12798
12798
  TypedrequestCache: () => TypedrequestCache,
@@ -13026,7 +13026,7 @@ replaceTraps((oldTraps) => ({
13026
13026
  has: (target, prop) => !!getMethod(target, prop) || oldTraps.has(target, prop)
13027
13027
  }));
13028
13028
 
13029
- // node_modules/.pnpm/@push.rocks+webstore@2.0.9/node_modules/@push.rocks/webstore/dist_ts/webstore.classes.webstore.js
13029
+ // node_modules/.pnpm/@push.rocks+webstore@2.0.13/node_modules/@push.rocks/webstore/dist_ts/webstore.classes.webstore.js
13030
13030
  var WebStore = class {
13031
13031
  constructor(optionsArg) {
13032
13032
  this.initCalled = false;
@@ -13084,7 +13084,7 @@ var WebStore = class {
13084
13084
  }
13085
13085
  };
13086
13086
 
13087
- // node_modules/.pnpm/@push.rocks+webstore@2.0.9/node_modules/@push.rocks/webstore/dist_ts/webstore.classes.typedrequestcache.js
13087
+ // node_modules/.pnpm/@push.rocks+webstore@2.0.13/node_modules/@push.rocks/webstore/dist_ts/webstore.classes.typedrequestcache.js
13088
13088
  var TypedrequestCache = class {
13089
13089
  constructor(domainArg = "default") {
13090
13090
  this.webstore = new WebStore({
@@ -14785,7 +14785,7 @@ var SmartRouter = class {
14785
14785
  }
14786
14786
  };
14787
14787
 
14788
- // node_modules/.pnpm/@push.rocks+smartstate@2.0.8/node_modules/@push.rocks/smartstate/dist_ts/index.js
14788
+ // node_modules/.pnpm/@push.rocks+smartstate@2.0.10/node_modules/@push.rocks/smartstate/dist_ts/index.js
14789
14789
  var dist_ts_exports19 = {};
14790
14790
  __export(dist_ts_exports19, {
14791
14791
  Smartstate: () => Smartstate,
@@ -14955,7 +14955,7 @@ var sha256FromString = async (stringArg) => {
14955
14955
  }
14956
14956
  };
14957
14957
 
14958
- // node_modules/.pnpm/@push.rocks+smartstate@2.0.8/node_modules/@push.rocks/smartstate/dist_ts/smartstate.classes.stateaction.js
14958
+ // node_modules/.pnpm/@push.rocks+smartstate@2.0.10/node_modules/@push.rocks/smartstate/dist_ts/smartstate.classes.stateaction.js
14959
14959
  var StateAction = class {
14960
14960
  constructor(statePartRef, actionDef) {
14961
14961
  this.statePartRef = statePartRef;
@@ -14966,12 +14966,30 @@ var StateAction = class {
14966
14966
  }
14967
14967
  };
14968
14968
 
14969
- // node_modules/.pnpm/@push.rocks+smartstate@2.0.8/node_modules/@push.rocks/smartstate/dist_ts/smartstate.classes.statepart.js
14969
+ // node_modules/.pnpm/@push.rocks+smartstate@2.0.10/node_modules/@push.rocks/smartstate/dist_ts/smartstate.classes.statepart.js
14970
14970
  var StatePart = class {
14971
- constructor(nameArg) {
14971
+ constructor(nameArg, webStoreOptions) {
14972
14972
  this.state = new dist_ts_exports4.rxjs.Subject();
14973
14973
  this.cumulativeDeferred = dist_ts_exports.cumulativeDefer();
14974
+ this.webStore = null;
14974
14975
  this.name = nameArg;
14976
+ if (webStoreOptions) {
14977
+ this.webStore = new dist_ts_exports11.WebStore(webStoreOptions);
14978
+ this.initWebStore();
14979
+ }
14980
+ }
14981
+ /**
14982
+ * initializes the webstore
14983
+ */
14984
+ async initWebStore() {
14985
+ if (this.webStore) {
14986
+ await this.webStore.init();
14987
+ const storedState = await this.webStore.get(String(this.name));
14988
+ if (storedState) {
14989
+ this.stateStore = storedState;
14990
+ this.notifyChange();
14991
+ }
14992
+ }
14975
14993
  }
14976
14994
  /**
14977
14995
  * gets the state from the state store
@@ -14983,9 +15001,12 @@ var StatePart = class {
14983
15001
  * sets the stateStore to the new state
14984
15002
  * @param newStateArg
14985
15003
  */
14986
- setState(newStateArg) {
15004
+ async setState(newStateArg) {
14987
15005
  this.stateStore = newStateArg;
14988
15006
  this.notifyChange();
15007
+ if (this.webStore) {
15008
+ await this.webStore.set(String(this.name), newStateArg);
15009
+ }
14989
15010
  }
14990
15011
  /**
14991
15012
  * notifies of a change on the state
@@ -15062,7 +15083,7 @@ var StatePart = class {
15062
15083
  }
15063
15084
  };
15064
15085
 
15065
- // node_modules/.pnpm/@push.rocks+smartstate@2.0.8/node_modules/@push.rocks/smartstate/dist_ts/smartstate.classes.smartstate.js
15086
+ // node_modules/.pnpm/@push.rocks+smartstate@2.0.10/node_modules/@push.rocks/smartstate/dist_ts/smartstate.classes.smartstate.js
15066
15087
  var Smartstate = class {
15067
15088
  constructor() {
15068
15089
  this.statePartMap = {};
@@ -16774,7 +16795,9 @@ var plugins3 = {
16774
16795
  smartdelay: dist_ts_exports2,
16775
16796
  smartpromise: dist_ts_exports,
16776
16797
  SweetScroll: import_sweet_scroll.default,
16777
- smartstate: dist_ts_exports19
16798
+ smartstate: dist_ts_exports19,
16799
+ smartrx: dist_ts_exports4,
16800
+ smarturl: dist_ts_exports20
16778
16801
  };
16779
16802
  export {
16780
16803
  DomTools2 as DomTools,