@design-edito/tools 0.1.37 → 0.1.39
Sign up to get free protection for your applications and to get access to all the features.
- package/agnostic/css/bem/index.js +2 -2
- package/agnostic/css/index.js +11 -11
- package/agnostic/errors/index.js +2 -2
- package/agnostic/html/hyper-json/cast/index.js +2 -2
- package/agnostic/html/hyper-json/index.js +3 -3
- package/agnostic/html/hyper-json/transformers/append/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/classList/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/join/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/length/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/print/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/push/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/querySelector/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/ref/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/replace/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/split/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toArray/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toBoolean/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toElement/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toNodeList/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toNull/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toNumber/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toRecord/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toRef/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toString/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toText/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/toTransformer/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/transformSelected/index.js +2 -2
- package/agnostic/html/hyper-json/transformers/trim/index.js +2 -2
- package/agnostic/html/hyper-json/tree/index.js +2 -2
- package/agnostic/html/hyper-json/utils/index.js +2 -2
- package/agnostic/html/index.js +20 -20
- package/agnostic/html/sanitize/index.js +6 -6
- package/agnostic/html/selector-to-element/index.js +6 -6
- package/agnostic/html/string-to-nodes/index.js +7 -7
- package/agnostic/misc/crossenv/index.js +2 -2
- package/agnostic/misc/elo/index.d.ts +31 -0
- package/agnostic/misc/elo/index.js +32 -0
- package/agnostic/misc/index.js +13 -13
- package/agnostic/misc/logs/index.js +2 -2
- package/agnostic/misc/logs/logger/index.d.ts +3 -0
- package/agnostic/misc/logs/logger/index.js +1 -1
- package/agnostic/misc/lorem-ipsum/index.js +5 -5
- package/agnostic/objects/index.js +3 -3
- package/agnostic/random/index.js +2 -2
- package/agnostic/regexps/index.d.ts +1 -0
- package/agnostic/regexps/index.js +1 -0
- package/agnostic/strings/index.js +7 -7
- package/agnostic/strings/replace-all/index.d.ts +1 -1
- package/agnostic/strings/replace-all/index.js +1 -1
- package/agnostic/time/index.js +3 -3
- package/chunks/chunk-6JRUZYTL.js +211 -0
- package/chunks/chunk-DCKTGQOX.js +29 -0
- package/chunks/chunk-GB4UQS6V.js +35 -0
- package/chunks/chunk-LOFELEU3.js +1108 -0
- package/chunks/chunk-LVXK54LL.js +27 -0
- package/chunks/chunk-MJQF3YZO.js +21 -0
- package/chunks/chunk-PPHUIOHO.js +28 -0
- package/chunks/chunk-QHGZBCFZ.js +1108 -0
- package/chunks/chunk-QN3UAKIU.js +21 -0
- package/chunks/chunk-RASMASS4.js +111 -0
- package/chunks/chunk-RHV7UOXD.js +211 -0
- package/chunks/chunk-S7MJLTCR.js +211 -0
- package/chunks/chunk-U6YRINXJ.js +22 -0
- package/chunks/chunk-YO5KOEJF.js +27 -0
- package/chunks/chunk-Z352MSRL.js +127 -0
- package/chunks/chunk-ZTDVUXPR.js +16 -0
- package/package.json +1 -1
@@ -0,0 +1,27 @@
|
|
1
|
+
import {
|
2
|
+
Cast,
|
3
|
+
Transformers,
|
4
|
+
Tree,
|
5
|
+
Utils
|
6
|
+
} from "./chunk-LOFELEU3.js";
|
7
|
+
import {
|
8
|
+
Serialize
|
9
|
+
} from "./chunk-ZCPGE7H7.js";
|
10
|
+
import {
|
11
|
+
Types
|
12
|
+
} from "./chunk-5GI5G45R.js";
|
13
|
+
|
14
|
+
// src/agnostic/html/hyper-json/index.ts
|
15
|
+
var HyperJson;
|
16
|
+
((HyperJson2) => {
|
17
|
+
HyperJson2.Cast = Cast;
|
18
|
+
HyperJson2.Serialize = Serialize;
|
19
|
+
HyperJson2.Transformers = Transformers;
|
20
|
+
HyperJson2.Tree = Tree;
|
21
|
+
HyperJson2.Types = Types;
|
22
|
+
HyperJson2.Utils = Utils;
|
23
|
+
})(HyperJson || (HyperJson = {}));
|
24
|
+
|
25
|
+
export {
|
26
|
+
HyperJson
|
27
|
+
};
|
@@ -0,0 +1,21 @@
|
|
1
|
+
import {
|
2
|
+
Logger
|
3
|
+
} from "./chunk-RASMASS4.js";
|
4
|
+
import {
|
5
|
+
styles
|
6
|
+
} from "./chunk-L3OCRR3V.js";
|
7
|
+
import {
|
8
|
+
makeTextBlock
|
9
|
+
} from "./chunk-H4PP6AHP.js";
|
10
|
+
|
11
|
+
// src/agnostic/misc/logs/index.ts
|
12
|
+
var Logs;
|
13
|
+
((Logs2) => {
|
14
|
+
Logs2.makeTextBlock = makeTextBlock;
|
15
|
+
Logs2.styles = styles;
|
16
|
+
Logs2.Logger = Logger;
|
17
|
+
})(Logs || (Logs = {}));
|
18
|
+
|
19
|
+
export {
|
20
|
+
Logs
|
21
|
+
};
|
@@ -0,0 +1,28 @@
|
|
1
|
+
import {
|
2
|
+
Sanitize
|
3
|
+
} from "./chunk-Z352MSRL.js";
|
4
|
+
import {
|
5
|
+
register
|
6
|
+
} from "./chunk-U6YRINXJ.js";
|
7
|
+
|
8
|
+
// src/agnostic/html/string-to-nodes/index.ts
|
9
|
+
function stringToNodes(dirtyStr, options) {
|
10
|
+
const actualDocument = options?.documentObj ?? window.document;
|
11
|
+
if (actualDocument === null) throw register.getError("no-window-document-on-runtime-please-provide" /* NO_DOCUMENT_PLEASE_PROVIDE */, "See documentObj in the options object");
|
12
|
+
const sanitizeOptions = {
|
13
|
+
...options?.sanitize,
|
14
|
+
documentObj: options?.sanitize?.documentObj ?? options?.documentObj
|
15
|
+
};
|
16
|
+
const str = options?.sanitize !== void 0 ? Sanitize.sanitize(dirtyStr, sanitizeOptions) : dirtyStr;
|
17
|
+
const wrapperDiv = actualDocument.createElement("div");
|
18
|
+
wrapperDiv.innerHTML = str;
|
19
|
+
const nodes = Array.from(wrapperDiv.childNodes).filter((node) => {
|
20
|
+
const allowedNodeTypes = [Node.ELEMENT_NODE, Node.TEXT_NODE];
|
21
|
+
return allowedNodeTypes.includes(node.nodeType);
|
22
|
+
});
|
23
|
+
return nodes;
|
24
|
+
}
|
25
|
+
|
26
|
+
export {
|
27
|
+
stringToNodes
|
28
|
+
};
|