@symbo.ls/scratch 2.34.1 → 2.34.2

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.
@@ -25,21 +25,21 @@ __export(sprite_exports, {
25
25
  });
26
26
  module.exports = __toCommonJS(sprite_exports);
27
27
 
28
- // ../../../domql/packages/utils/dist/esm/env.js
28
+ // ../../../domql/packages/utils/env.js
29
29
  var NODE_ENV = "development";
30
30
  var isProduction = (env = NODE_ENV) => env === "production";
31
31
  var isNotProduction = (env = NODE_ENV) => !isProduction(env);
32
32
 
33
- // ../../../domql/packages/utils/dist/esm/globals.js
33
+ // ../../../domql/packages/utils/globals.js
34
34
  var window2 = globalThis;
35
35
  var document2 = window2.document;
36
36
 
37
- // ../../../domql/packages/utils/dist/esm/node.js
37
+ // ../../../domql/packages/utils/node.js
38
38
  var isDOMNode = (obj) => {
39
39
  return typeof window2 !== "undefined" && (obj instanceof window2.Node || obj instanceof window2.Window || obj === window2 || obj === document);
40
40
  };
41
41
 
42
- // ../../../domql/packages/utils/dist/esm/types.js
42
+ // ../../../domql/packages/utils/types.js
43
43
  var isString = (arg) => typeof arg === "string";
44
44
  var isFunction = (arg) => typeof arg === "function";
45
45
  var isNull = (arg) => arg === null;
@@ -52,7 +52,7 @@ var isUndefined = (arg) => {
52
52
  return arg === void 0;
53
53
  };
54
54
 
55
- // ../../../domql/packages/utils/dist/esm/array.js
55
+ // ../../../domql/packages/utils/array.js
56
56
  var mergeArray = (arr, exclude = []) => {
57
57
  return arr.reduce(
58
58
  (a, c) => deepMerge(a, deepClone(c, { exclude }), exclude),
@@ -60,30 +60,11 @@ var mergeArray = (arr, exclude = []) => {
60
60
  );
61
61
  };
62
62
 
63
- // ../../../domql/packages/utils/dist/esm/object.js
64
- var __defProp2 = Object.defineProperty;
65
- var __defProps = Object.defineProperties;
66
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
67
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
68
- var __hasOwnProp2 = Object.prototype.hasOwnProperty;
69
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
70
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
71
- var __spreadValues = (a, b) => {
72
- for (var prop in b || (b = {}))
73
- if (__hasOwnProp2.call(b, prop))
74
- __defNormalProp(a, prop, b[prop]);
75
- if (__getOwnPropSymbols)
76
- for (var prop of __getOwnPropSymbols(b)) {
77
- if (__propIsEnum.call(b, prop))
78
- __defNormalProp(a, prop, b[prop]);
79
- }
80
- return a;
81
- };
82
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
63
+ // ../../../domql/packages/utils/object.js
83
64
  var deepMerge = (element, extend, excludeFrom = [], level = Infinity) => {
84
65
  for (const e in extend) {
85
- const hasOwnProperty2 = Object.prototype.hasOwnProperty.call(extend, e);
86
- if (!hasOwnProperty2 || excludeFrom.includes(e) || e.startsWith("__"))
66
+ const hasOwnProperty = Object.prototype.hasOwnProperty.call(extend, e);
67
+ if (!hasOwnProperty || excludeFrom.includes(e) || e.startsWith("__"))
87
68
  continue;
88
69
  const elementProp = element[e];
89
70
  const extendProp = extend[e];
@@ -118,8 +99,8 @@ var deepClone = (obj, options = {}) => {
118
99
  if (visited.has(obj)) {
119
100
  return visited.get(obj);
120
101
  }
121
- const clone2 = contentWindow ? isArray(obj) ? new contentWindow.Array() : new contentWindow.Object() : isArray(obj) ? [] : {};
122
- visited.set(obj, clone2);
102
+ const clone = contentWindow ? isArray(obj) ? new contentWindow.Array() : new contentWindow.Object() : isArray(obj) ? [] : {};
103
+ visited.set(obj, clone);
123
104
  for (const key in obj) {
124
105
  if (!Object.prototype.hasOwnProperty.call(obj, key)) continue;
125
106
  if (exclude.includes(key) || key.startsWith("__") || key === "__proto__")
@@ -128,15 +109,15 @@ var deepClone = (obj, options = {}) => {
128
109
  if (cleanUndefined && isUndefined(value) || cleanNull && isNull(value))
129
110
  continue;
130
111
  if (isDOMNode(value)) {
131
- clone2[key] = value;
112
+ clone[key] = value;
132
113
  continue;
133
114
  }
134
115
  if (handleExtend && key === "extend" && isArray(value)) {
135
- clone2[key] = mergeArray(value, exclude);
116
+ clone[key] = mergeArray(value, exclude);
136
117
  continue;
137
118
  }
138
119
  if (isFunction(value) && options.window) {
139
- clone2[key] = contentWindow.eval("(" + value.toString() + ")");
120
+ clone[key] = contentWindow.eval("(" + value.toString() + ")");
140
121
  continue;
141
122
  }
142
123
  if ((value == null ? void 0 : value.__ref) && (value == null ? void 0 : value.node)) {
@@ -147,17 +128,18 @@ var deepClone = (obj, options = {}) => {
147
128
  }
148
129
  if (isObjectLike(value)) {
149
130
  if (!Object.prototype.hasOwnProperty.call(obj, key)) continue;
150
- clone2[key] = deepClone(value, __spreadProps(__spreadValues({}, options), {
131
+ clone[key] = deepClone(value, {
132
+ ...options,
151
133
  visited
152
- }));
134
+ });
153
135
  } else {
154
- clone2[key] = value;
136
+ clone[key] = value;
155
137
  }
156
138
  }
157
- return clone2;
139
+ return clone;
158
140
  };
159
141
 
160
- // ../../../domql/packages/utils/dist/esm/cookie.js
142
+ // ../../../domql/packages/utils/cookie.js
161
143
  var isMobile = (() => typeof navigator === "undefined" ? false : /Mobi/.test(navigator.userAgent))();
162
144
 
163
145
  // src/defaultConfig/index.js