smbls 3.4.11 → 3.5.0

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.
@@ -50,13 +50,11 @@ var utils = __toESM(require("./utilImports.js"), 1);
50
50
  var routerUtils = __toESM(require("@domql/router"), 1);
51
51
  // @preserve-env
52
52
  const prepareWindow = (context) => {
53
- if (typeof window === "undefined") window = globalThis || {};
54
- if (typeof document === "undefined") {
55
- if (!window.document) window.document = globalThis.document || { body: {} };
56
- document = window.document;
57
- }
58
- context.document = context.document || document;
59
- context.window = context.window || window;
53
+ const win = typeof window !== "undefined" ? window : globalThis || {};
54
+ if (!win.document) win.document = { body: {} };
55
+ const doc = typeof document !== "undefined" ? document : win.document;
56
+ context.document = context.document || doc;
57
+ context.window = context.window || win;
60
58
  return context.window;
61
59
  };
62
60
  function onlyDotsAndNumbers(str) {
@@ -1 +1 @@
1
- {"name":"smbls","version":"3.4.10"}
1
+ {"name":"smbls","version":"3.4.12"}
@@ -12,13 +12,11 @@ import * as utils from "./utilImports.js";
12
12
  import * as routerUtils from "@domql/router";
13
13
  // @preserve-env
14
14
  const prepareWindow = (context) => {
15
- if (typeof window === "undefined") window = globalThis || {};
16
- if (typeof document === "undefined") {
17
- if (!window.document) window.document = globalThis.document || { body: {} };
18
- document = window.document;
19
- }
20
- context.document = context.document || document;
21
- context.window = context.window || window;
15
+ const win = typeof window !== "undefined" ? window : globalThis || {};
16
+ if (!win.document) win.document = { body: {} };
17
+ const doc = typeof document !== "undefined" ? document : win.document;
18
+ context.document = context.document || doc;
19
+ context.window = context.window || win;
22
20
  return context.window;
23
21
  };
24
22
  function onlyDotsAndNumbers(str) {
@@ -502,13 +502,11 @@ var Smbls = (() => {
502
502
  var uikit = __toESM(__require("@symbo.ls/uikit"));
503
503
  var routerUtils = __toESM(__require("@domql/router"));
504
504
  var prepareWindow = (context) => {
505
- if (typeof window === "undefined") window = globalThis || {};
506
- if (typeof document === "undefined") {
507
- if (!window.document) window.document = globalThis.document || { body: {} };
508
- document = window.document;
509
- }
510
- context.document = context.document || document;
511
- context.window = context.window || window;
505
+ const win = typeof window !== "undefined" ? window : globalThis || {};
506
+ if (!win.document) win.document = { body: {} };
507
+ const doc = typeof document !== "undefined" ? document : win.document;
508
+ context.document = context.document || doc;
509
+ context.window = context.window || win;
512
510
  return context.window;
513
511
  };
514
512
  function onlyDotsAndNumbers(str) {
@@ -1063,13 +1061,11 @@ var Smbls = (() => {
1063
1061
  var uikit3 = __toESM(__require("@symbo.ls/uikit"), 1);
1064
1062
  var routerUtils2 = __toESM(__require("@domql/router"), 1);
1065
1063
  var prepareWindow2 = (context) => {
1066
- if (typeof window === "undefined") window = globalThis || {};
1067
- if (typeof document === "undefined") {
1068
- if (!window.document) window.document = globalThis.document || { body: {} };
1069
- document = window.document;
1070
- }
1071
- context.document = context.document || document;
1072
- context.window = context.window || window;
1064
+ const win = typeof window !== "undefined" ? window : globalThis || {};
1065
+ if (!win.document) win.document = { body: {} };
1066
+ const doc = typeof document !== "undefined" ? document : win.document;
1067
+ context.document = context.document || doc;
1068
+ context.window = context.window || win;
1073
1069
  return context.window;
1074
1070
  };
1075
1071
  function onlyDotsAndNumbers2(str) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "smbls",
3
- "version": "3.4.11",
3
+ "version": "3.5.0",
4
4
  "license": "MIT",
5
5
  "repository": "https://github.com/symbo-ls/smbls",
6
6
  "gitHead": "9fc1b79b41cdc725ca6b24aec64920a599634681",
@@ -28,20 +28,20 @@
28
28
  "src"
29
29
  ],
30
30
  "dependencies": {
31
- "@symbo.ls/emotion": "^3.4.11",
32
- "@domql/report": "^3.4.11",
33
- "@domql/router": "^3.4.11",
34
- "@domql/utils": "^3.4.11",
35
- "@symbo.ls/cli": "^3.4.11",
36
- "@symbo.ls/default-config": "^3.4.11",
37
- "@symbo.ls/fetch": "^3.4.11",
38
- "@symbo.ls/scratch": "^3.4.11",
39
- "@symbo.ls/sync": "^3.4.11",
40
- "@symbo.ls/uikit": "^3.4.11",
41
- "@symbo.ls/smbls-utils": "^3.4.11",
42
- "attrs-in-props": "^3.4.11",
43
- "css-in-props": "^3.4.11",
44
- "domql": "^3.4.11"
31
+ "@symbo.ls/emotion": "^3.5.0",
32
+ "@domql/report": "^3.5.0",
33
+ "@domql/router": "^3.5.0",
34
+ "@domql/utils": "^3.5.0",
35
+ "@symbo.ls/cli": "^3.5.0",
36
+ "@symbo.ls/default-config": "^3.5.0",
37
+ "@symbo.ls/fetch": "^3.5.0",
38
+ "@symbo.ls/scratch": "^3.5.0",
39
+ "@symbo.ls/sync": "^3.5.0",
40
+ "@symbo.ls/uikit": "^3.5.0",
41
+ "@symbo.ls/smbls-utils": "^3.5.0",
42
+ "attrs-in-props": "^3.5.0",
43
+ "css-in-props": "^3.5.0",
44
+ "domql": "^3.5.0"
45
45
  },
46
46
  "publishConfig": {},
47
47
  "scripts": {
package/src/prepare.js CHANGED
@@ -17,13 +17,11 @@ import * as routerUtils from '@domql/router'
17
17
  // @preserve-env
18
18
 
19
19
  export const prepareWindow = (context) => {
20
- if (typeof window === 'undefined') window = globalThis || {} // eslint-disable-line
21
- if (typeof document === 'undefined') {
22
- if (!window.document) window.document = globalThis.document || { body: {} }
23
- document = window.document // eslint-disable-line
24
- }
25
- context.document = context.document || document
26
- context.window = context.window || window
20
+ const win = typeof window !== 'undefined' ? window : globalThis || {}
21
+ if (!win.document) win.document = { body: {} }
22
+ const doc = typeof document !== 'undefined' ? document : win.document
23
+ context.document = context.document || doc
24
+ context.window = context.window || win
27
25
  return context.window
28
26
  }
29
27