@symbo.ls/scratch 3.0.2 → 3.1.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.
@@ -83,7 +83,7 @@ var require_cjs = __commonJS({
83
83
  var isString2 = (arg) => typeof arg === "string";
84
84
  var isNumber2 = (arg) => typeof arg === "number";
85
85
  var isArray2 = (arg) => Array.isArray(arg);
86
- var STATE_METHODS2 = [
86
+ var STATE_METHODS3 = [
87
87
  "update",
88
88
  "parse",
89
89
  "clean",
@@ -117,8 +117,8 @@ var require_cjs = __commonJS({
117
117
  "removePathCollection",
118
118
  "getByPath"
119
119
  ];
120
- var PROPS_METHODS2 = ["update", "__element"];
121
- var METHODS2 = [
120
+ var PROPS_METHODS3 = ["update", "__element"];
121
+ var METHODS3 = [
122
122
  "set",
123
123
  "reset",
124
124
  "update",
@@ -146,13 +146,84 @@ var require_cjs = __commonJS({
146
146
  "nextElement",
147
147
  "previousElement"
148
148
  ];
149
- var METHODS_EXL2 = [
149
+ var METHODS_EXL3 = [
150
150
  ...["node", "context", "extends", "__element", "__ref"],
151
- ...METHODS2,
152
- ...STATE_METHODS2,
153
- ...PROPS_METHODS2
151
+ ...METHODS3,
152
+ ...STATE_METHODS3,
153
+ ...PROPS_METHODS3
154
154
  ];
155
155
  var isMobile2 = (() => typeof navigator === "undefined" ? false : /Mobi/.test(navigator.userAgent))();
156
+ var STATE_METHODS22 = [
157
+ "update",
158
+ "parse",
159
+ "clean",
160
+ "create",
161
+ "destroy",
162
+ "add",
163
+ "toggle",
164
+ "remove",
165
+ "apply",
166
+ "set",
167
+ "reset",
168
+ "replace",
169
+ "quietReplace",
170
+ "quietUpdate",
171
+ "applyReplace",
172
+ "applyFunction",
173
+ "keys",
174
+ "values",
175
+ "ref",
176
+ "rootUpdate",
177
+ "parentUpdate",
178
+ "parent",
179
+ "__element",
180
+ "__depends",
181
+ "__ref",
182
+ "__children",
183
+ "root",
184
+ "setByPath",
185
+ "setPathCollection",
186
+ "removeByPath",
187
+ "removePathCollection",
188
+ "getByPath"
189
+ ];
190
+ var PROPS_METHODS22 = ["update", "__element"];
191
+ var METHODS22 = [
192
+ "set",
193
+ "reset",
194
+ "update",
195
+ "remove",
196
+ "updateContent",
197
+ "removeContent",
198
+ "lookup",
199
+ "lookdown",
200
+ "lookdownAll",
201
+ "getRef",
202
+ "getPath",
203
+ "setNodeStyles",
204
+ "spotByPath",
205
+ "keys",
206
+ "parse",
207
+ "setProps",
208
+ "parseDeep",
209
+ "variables",
210
+ "if",
211
+ "log",
212
+ "verbose",
213
+ "warn",
214
+ "error",
215
+ "call",
216
+ "nextElement",
217
+ "previousElement"
218
+ ];
219
+ var METHODS_EXL22 = [
220
+ ...["node", "context", "extends", "__element", "__ref"],
221
+ ...METHODS22,
222
+ ...STATE_METHODS22,
223
+ ...PROPS_METHODS22
224
+ ];
225
+ var window32 = globalThis;
226
+ var document32 = window32.document;
156
227
  async function toggleFullscreen(opts) {
157
228
  if (!document.fullscreenElement) {
158
229
  try {
@@ -342,16 +413,16 @@ __export(transforms_exports, {
342
413
  });
343
414
  module.exports = __toCommonJS(transforms_exports);
344
415
 
345
- // ../../node_modules/@domql/utils/globals.js
416
+ // ../../../domql/packages/utils/globals.js
346
417
  var window2 = globalThis;
347
418
  var document2 = window2.document;
348
419
 
349
- // ../../node_modules/@domql/utils/node.js
420
+ // ../../../domql/packages/utils/node.js
350
421
  var isDOMNode = (obj) => {
351
422
  return typeof window2 !== "undefined" && (obj instanceof window2.Node || obj instanceof window2.Window || obj === window2 || obj === document);
352
423
  };
353
424
 
354
- // ../../node_modules/@domql/utils/types.js
425
+ // ../../../domql/packages/utils/types.js
355
426
  var isObject = (arg) => {
356
427
  if (arg === null) return false;
357
428
  return typeof arg === "object" && arg.constructor === Object;
@@ -369,7 +440,7 @@ var isUndefined = (arg) => {
369
440
  return arg === void 0;
370
441
  };
371
442
 
372
- // ../../node_modules/@domql/utils/array.js
443
+ // ../../../domql/packages/utils/array.js
373
444
  var unstackArrayOfObjects = (arr, exclude = []) => {
374
445
  return arr.reduce(
375
446
  (a, c) => deepMerge(a, deepClone(c, { exclude }), exclude),
@@ -377,7 +448,7 @@ var unstackArrayOfObjects = (arr, exclude = []) => {
377
448
  );
378
449
  };
379
450
 
380
- // ../../node_modules/@domql/utils/keys.js
451
+ // ../../../domql/packages/utils/keys.js
381
452
  var STATE_METHODS = [
382
453
  "update",
383
454
  "parse",
@@ -448,7 +519,7 @@ var METHODS_EXL = [
448
519
  ...PROPS_METHODS
449
520
  ];
450
521
 
451
- // ../../node_modules/@domql/utils/object.js
522
+ // ../../../domql/packages/utils/object.js
452
523
  var merge = (element, obj, excludeFrom = []) => {
453
524
  for (const e in obj) {
454
525
  const hasOwnProperty = Object.prototype.hasOwnProperty.call(obj, e);
@@ -529,9 +600,84 @@ var deepClone = (obj, options = {}) => {
529
600
  return clone;
530
601
  };
531
602
 
532
- // ../../node_modules/@domql/utils/cookie.js
603
+ // ../../../domql/packages/utils/cookie.js
533
604
  var isMobile = (() => typeof navigator === "undefined" ? false : /Mobi/.test(navigator.userAgent))();
534
605
 
606
+ // ../../../domql/packages/event/dist/esm/keys.js
607
+ var STATE_METHODS2 = [
608
+ "update",
609
+ "parse",
610
+ "clean",
611
+ "create",
612
+ "destroy",
613
+ "add",
614
+ "toggle",
615
+ "remove",
616
+ "apply",
617
+ "set",
618
+ "reset",
619
+ "replace",
620
+ "quietReplace",
621
+ "quietUpdate",
622
+ "applyReplace",
623
+ "applyFunction",
624
+ "keys",
625
+ "values",
626
+ "ref",
627
+ "rootUpdate",
628
+ "parentUpdate",
629
+ "parent",
630
+ "__element",
631
+ "__depends",
632
+ "__ref",
633
+ "__children",
634
+ "root",
635
+ "setByPath",
636
+ "setPathCollection",
637
+ "removeByPath",
638
+ "removePathCollection",
639
+ "getByPath"
640
+ ];
641
+ var PROPS_METHODS2 = ["update", "__element"];
642
+ var METHODS2 = [
643
+ "set",
644
+ "reset",
645
+ "update",
646
+ "remove",
647
+ "updateContent",
648
+ "removeContent",
649
+ "lookup",
650
+ "lookdown",
651
+ "lookdownAll",
652
+ "getRef",
653
+ "getPath",
654
+ "setNodeStyles",
655
+ "spotByPath",
656
+ "keys",
657
+ "parse",
658
+ "setProps",
659
+ "parseDeep",
660
+ "variables",
661
+ "if",
662
+ "log",
663
+ "verbose",
664
+ "warn",
665
+ "error",
666
+ "call",
667
+ "nextElement",
668
+ "previousElement"
669
+ ];
670
+ var METHODS_EXL2 = [
671
+ ...["node", "context", "extends", "__element", "__ref"],
672
+ ...METHODS2,
673
+ ...STATE_METHODS2,
674
+ ...PROPS_METHODS2
675
+ ];
676
+
677
+ // ../../../domql/packages/event/dist/esm/globals.js
678
+ var window3 = globalThis;
679
+ var document3 = window3.document;
680
+
535
681
  // src/defaultConfig/index.js
536
682
  var defaultConfig_exports = {};
537
683
  __export(defaultConfig_exports, {
@@ -847,7 +993,7 @@ var getRgbTone = (rgb, tone) => {
847
993
  };
848
994
 
849
995
  // src/utils/sequence.js
850
- var import_utils6 = __toESM(require_cjs(), 1);
996
+ var import_utils5 = __toESM(require_cjs(), 1);
851
997
  var numToLetterMap = {
852
998
  "-6": "U",
853
999
  "-5": "V",
@@ -986,7 +1132,7 @@ var getSequenceValue = (value = "A", sequenceProps) => {
986
1132
  useVariable
987
1133
  } = sequenceProps;
988
1134
  if (isString(value) && value.slice(0, 2) === "--") return `var(${value})`;
989
- const prefix = `--${(0, import_utils6.toDashCase)(sequenceProps.type.replace(".", "-"))}-`;
1135
+ const prefix = `--${(0, import_utils5.toDashCase)(sequenceProps.type.replace(".", "-"))}-`;
990
1136
  const startsWithDashOrLetterRegex = /^-?[a-zA-Z]/i;
991
1137
  const startsWithDashOrLetter = startsWithDashOrLetterRegex.test(value);
992
1138
  if (value === "none" || value === "auto" || value === "unset" || value === "inherit" || value === "fit-content" || value === "min-content" || value === "max-content" || value.includes("calc") || value.includes("var") || !startsWithDashOrLetter) return value;
@@ -1141,10 +1287,10 @@ var getMediaColor = (value, globalTheme, config) => {
1141
1287
  };
1142
1288
 
1143
1289
  // src/system/font.js
1144
- var import_utils13 = __toESM(require_cjs(), 1);
1290
+ var import_utils12 = __toESM(require_cjs(), 1);
1145
1291
 
1146
1292
  // src/system/spacing.js
1147
- var import_utils17 = __toESM(require_cjs(), 1);
1293
+ var import_utils16 = __toESM(require_cjs(), 1);
1148
1294
  var getSequence = (sequenceProps) => {
1149
1295
  const CONFIG2 = getActiveConfig();
1150
1296
  const { SPACING: SPACING2 } = CONFIG2;
@@ -1157,7 +1303,7 @@ var getSpacingByKey = (value, propertyName = "padding", sequenceProps) => {
1157
1303
  if (isString(value) && (value.includes("calc") || value.includes("var"))) {
1158
1304
  return { [propertyName]: value };
1159
1305
  }
1160
- const stack = (0, import_utils17.arrayzeValue)(value);
1306
+ const stack = (0, import_utils16.arrayzeValue)(value);
1161
1307
  if (!isArray(stack)) return;
1162
1308
  if (stack.length > 1) {
1163
1309
  let suffix = "";
@@ -1250,11 +1396,11 @@ var getShadow = (value, globalTheme) => {
1250
1396
  };
1251
1397
 
1252
1398
  // src/system/timing.js
1253
- var import_utils21 = __toESM(require_cjs(), 1);
1399
+ var import_utils20 = __toESM(require_cjs(), 1);
1254
1400
  var getTimingFunction = (value) => {
1255
1401
  const CONFIG2 = getActiveConfig();
1256
1402
  const { TIMING: TIMING2 } = CONFIG2;
1257
- return TIMING2[value] || TIMING2[(0, import_utils21.toCamelCase)(value)] || value;
1403
+ return TIMING2[value] || TIMING2[(0, import_utils20.toCamelCase)(value)] || value;
1258
1404
  };
1259
1405
  var getTimingByKey = (value, property = "timing") => {
1260
1406
  const CONFIG2 = getActiveConfig();
@@ -1385,3 +1531,4 @@ var transformBorderRadius = (radius, props, propertyName) => {
1385
1531
  borderRadius: radius.split(" ").map((v, k) => getSpacingBasedOnRatio(props, propertyName, v)[propertyName]).join(" ")
1386
1532
  };
1387
1533
  };
1534
+ // @preserve-env
@@ -38,15 +38,15 @@ __export(color_exports, {
38
38
  });
39
39
  module.exports = __toCommonJS(color_exports);
40
40
 
41
- // ../../node_modules/@domql/utils/globals.js
41
+ // ../../../domql/packages/utils/globals.js
42
42
  var window2 = globalThis;
43
43
  var document2 = window2.document;
44
44
 
45
- // ../../node_modules/@domql/utils/types.js
45
+ // ../../../domql/packages/utils/types.js
46
46
  var isString = (arg) => typeof arg === "string";
47
47
  var isNumber = (arg) => typeof arg === "number";
48
48
 
49
- // ../../node_modules/@domql/utils/keys.js
49
+ // ../../../domql/packages/utils/keys.js
50
50
  var STATE_METHODS = [
51
51
  "update",
52
52
  "parse",
@@ -117,9 +117,84 @@ var METHODS_EXL = [
117
117
  ...PROPS_METHODS
118
118
  ];
119
119
 
120
- // ../../node_modules/@domql/utils/cookie.js
120
+ // ../../../domql/packages/utils/cookie.js
121
121
  var isMobile = (() => typeof navigator === "undefined" ? false : /Mobi/.test(navigator.userAgent))();
122
122
 
123
+ // ../../../domql/packages/event/dist/esm/keys.js
124
+ var STATE_METHODS2 = [
125
+ "update",
126
+ "parse",
127
+ "clean",
128
+ "create",
129
+ "destroy",
130
+ "add",
131
+ "toggle",
132
+ "remove",
133
+ "apply",
134
+ "set",
135
+ "reset",
136
+ "replace",
137
+ "quietReplace",
138
+ "quietUpdate",
139
+ "applyReplace",
140
+ "applyFunction",
141
+ "keys",
142
+ "values",
143
+ "ref",
144
+ "rootUpdate",
145
+ "parentUpdate",
146
+ "parent",
147
+ "__element",
148
+ "__depends",
149
+ "__ref",
150
+ "__children",
151
+ "root",
152
+ "setByPath",
153
+ "setPathCollection",
154
+ "removeByPath",
155
+ "removePathCollection",
156
+ "getByPath"
157
+ ];
158
+ var PROPS_METHODS2 = ["update", "__element"];
159
+ var METHODS2 = [
160
+ "set",
161
+ "reset",
162
+ "update",
163
+ "remove",
164
+ "updateContent",
165
+ "removeContent",
166
+ "lookup",
167
+ "lookdown",
168
+ "lookdownAll",
169
+ "getRef",
170
+ "getPath",
171
+ "setNodeStyles",
172
+ "spotByPath",
173
+ "keys",
174
+ "parse",
175
+ "setProps",
176
+ "parseDeep",
177
+ "variables",
178
+ "if",
179
+ "log",
180
+ "verbose",
181
+ "warn",
182
+ "error",
183
+ "call",
184
+ "nextElement",
185
+ "previousElement"
186
+ ];
187
+ var METHODS_EXL2 = [
188
+ ...["node", "context", "extends", "__element", "__ref"],
189
+ ...METHODS2,
190
+ ...STATE_METHODS2,
191
+ ...PROPS_METHODS2
192
+ ];
193
+
194
+ // ../../../domql/packages/event/dist/esm/globals.js
195
+ var window3 = globalThis;
196
+ var document3 = window3.document;
197
+
123
198
  // src/utils/color.js
124
199
  var ENV = "development";
125
200
  var colorStringToRgbaArray = (color) => {
@@ -235,7 +310,7 @@ var mixTwoRgba = (colorA, colorB, range = 0.5) => {
235
310
  var opacify = (color, opacity) => {
236
311
  const arr = colorStringToRgbaArray(color);
237
312
  if (!arr) {
238
- if (ENV === "test" || ENV === "development") console.warn(color + " color is not rgba");
313
+ if (ENV === "testing" || ENV === "development") console.warn(color + " color is not rgba");
239
314
  return;
240
315
  }
241
316
  arr[3] = opacity;
@@ -258,3 +333,4 @@ var getRgbTone = (rgb, tone) => {
258
333
  return newRgb;
259
334
  }
260
335
  };
336
+ // @preserve-env