@nsshunt/stsuxvue 1.0.16 → 1.0.18
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.
- package/dist/stsuxvue.mjs +41 -27
- package/dist/stsuxvue.mjs.map +1 -1
- package/dist/stsuxvue.umd.js +41 -27
- package/dist/stsuxvue.umd.js.map +1 -1
- package/package.json +9 -12
package/dist/stsuxvue.mjs
CHANGED
|
@@ -5756,7 +5756,7 @@ var Filter = /* @__PURE__ */ function() {
|
|
|
5756
5756
|
}();
|
|
5757
5757
|
var ansi_to_html = Filter;
|
|
5758
5758
|
const Convert = /* @__PURE__ */ getDefaultExportFromCjs(ansi_to_html);
|
|
5759
|
-
/*! @license DOMPurify 3.2.
|
|
5759
|
+
/*! @license DOMPurify 3.2.2 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.2/LICENSE */
|
|
5760
5760
|
const {
|
|
5761
5761
|
entries,
|
|
5762
5762
|
setPrototypeOf,
|
|
@@ -5927,11 +5927,20 @@ var EXPRESSIONS = /* @__PURE__ */ Object.freeze({
|
|
|
5927
5927
|
});
|
|
5928
5928
|
const NODE_TYPE = {
|
|
5929
5929
|
element: 1,
|
|
5930
|
+
attribute: 2,
|
|
5930
5931
|
text: 3,
|
|
5932
|
+
cdataSection: 4,
|
|
5933
|
+
entityReference: 5,
|
|
5934
|
+
// Deprecated
|
|
5935
|
+
entityNode: 6,
|
|
5931
5936
|
// Deprecated
|
|
5932
5937
|
progressingInstruction: 7,
|
|
5933
5938
|
comment: 8,
|
|
5934
|
-
document: 9
|
|
5939
|
+
document: 9,
|
|
5940
|
+
documentType: 10,
|
|
5941
|
+
documentFragment: 11,
|
|
5942
|
+
notation: 12
|
|
5943
|
+
// Deprecated
|
|
5935
5944
|
};
|
|
5936
5945
|
const getGlobal = function getGlobal2() {
|
|
5937
5946
|
return typeof window === "undefined" ? null : window;
|
|
@@ -5960,10 +5969,23 @@ const _createTrustedTypesPolicy = function _createTrustedTypesPolicy2(trustedTyp
|
|
|
5960
5969
|
return null;
|
|
5961
5970
|
}
|
|
5962
5971
|
};
|
|
5972
|
+
const _createHooksMap = function _createHooksMap2() {
|
|
5973
|
+
return {
|
|
5974
|
+
afterSanitizeAttributes: [],
|
|
5975
|
+
afterSanitizeElements: [],
|
|
5976
|
+
afterSanitizeShadowDOM: [],
|
|
5977
|
+
beforeSanitizeAttributes: [],
|
|
5978
|
+
beforeSanitizeElements: [],
|
|
5979
|
+
beforeSanitizeShadowDOM: [],
|
|
5980
|
+
uponSanitizeAttribute: [],
|
|
5981
|
+
uponSanitizeElement: [],
|
|
5982
|
+
uponSanitizeShadowNode: []
|
|
5983
|
+
};
|
|
5984
|
+
};
|
|
5963
5985
|
function createDOMPurify() {
|
|
5964
5986
|
let window2 = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : getGlobal();
|
|
5965
5987
|
const DOMPurify = (root) => createDOMPurify(root);
|
|
5966
|
-
DOMPurify.version = "3.2.
|
|
5988
|
+
DOMPurify.version = "3.2.2";
|
|
5967
5989
|
DOMPurify.removed = [];
|
|
5968
5990
|
if (!window2 || !window2.document || window2.document.nodeType !== NODE_TYPE.document) {
|
|
5969
5991
|
DOMPurify.isSupported = false;
|
|
@@ -6008,7 +6030,7 @@ function createDOMPurify() {
|
|
|
6008
6030
|
const {
|
|
6009
6031
|
importNode
|
|
6010
6032
|
} = originalDocument;
|
|
6011
|
-
let hooks =
|
|
6033
|
+
let hooks = _createHooksMap();
|
|
6012
6034
|
DOMPurify.isSupported = typeof entries === "function" && typeof getParentNode === "function" && implementation && implementation.createHTMLDocument !== void 0;
|
|
6013
6035
|
const {
|
|
6014
6036
|
MUSTACHE_EXPR: MUSTACHE_EXPR2,
|
|
@@ -6294,7 +6316,7 @@ function createDOMPurify() {
|
|
|
6294
6316
|
});
|
|
6295
6317
|
}
|
|
6296
6318
|
element.removeAttribute(name);
|
|
6297
|
-
if (name === "is"
|
|
6319
|
+
if (name === "is") {
|
|
6298
6320
|
if (RETURN_DOM || RETURN_DOM_FRAGMENT) {
|
|
6299
6321
|
try {
|
|
6300
6322
|
_forceRemove(element);
|
|
@@ -6358,23 +6380,20 @@ function createDOMPurify() {
|
|
|
6358
6380
|
const _isNode = function _isNode2(value) {
|
|
6359
6381
|
return typeof Node === "function" && value instanceof Node;
|
|
6360
6382
|
};
|
|
6361
|
-
function
|
|
6362
|
-
|
|
6363
|
-
return;
|
|
6364
|
-
}
|
|
6365
|
-
arrayForEach(hooks[entryPoint], (hook) => {
|
|
6383
|
+
function _executeHooks(hooks2, currentNode, data) {
|
|
6384
|
+
arrayForEach(hooks2, (hook) => {
|
|
6366
6385
|
hook.call(DOMPurify, currentNode, data, CONFIG);
|
|
6367
6386
|
});
|
|
6368
6387
|
}
|
|
6369
6388
|
const _sanitizeElements = function _sanitizeElements2(currentNode) {
|
|
6370
6389
|
let content = null;
|
|
6371
|
-
|
|
6390
|
+
_executeHooks(hooks.beforeSanitizeElements, currentNode, null);
|
|
6372
6391
|
if (_isClobbered(currentNode)) {
|
|
6373
6392
|
_forceRemove(currentNode);
|
|
6374
6393
|
return true;
|
|
6375
6394
|
}
|
|
6376
6395
|
const tagName = transformCaseFunc(currentNode.nodeName);
|
|
6377
|
-
|
|
6396
|
+
_executeHooks(hooks.uponSanitizeElement, currentNode, {
|
|
6378
6397
|
tagName,
|
|
6379
6398
|
allowedTags: ALLOWED_TAGS
|
|
6380
6399
|
});
|
|
@@ -6434,7 +6453,7 @@ function createDOMPurify() {
|
|
|
6434
6453
|
currentNode.textContent = content;
|
|
6435
6454
|
}
|
|
6436
6455
|
}
|
|
6437
|
-
|
|
6456
|
+
_executeHooks(hooks.afterSanitizeElements, currentNode, null);
|
|
6438
6457
|
return false;
|
|
6439
6458
|
};
|
|
6440
6459
|
const _isValidAttribute = function _isValidAttribute2(lcTag, lcName, value) {
|
|
@@ -6468,7 +6487,7 @@ function createDOMPurify() {
|
|
|
6468
6487
|
return tagName !== "annotation-xml" && stringMatch(tagName, CUSTOM_ELEMENT2);
|
|
6469
6488
|
};
|
|
6470
6489
|
const _sanitizeAttributes = function _sanitizeAttributes2(currentNode) {
|
|
6471
|
-
|
|
6490
|
+
_executeHooks(hooks.beforeSanitizeAttributes, currentNode, null);
|
|
6472
6491
|
const {
|
|
6473
6492
|
attributes
|
|
6474
6493
|
} = currentNode;
|
|
@@ -6496,7 +6515,7 @@ function createDOMPurify() {
|
|
|
6496
6515
|
hookEvent.attrValue = value;
|
|
6497
6516
|
hookEvent.keepAttr = true;
|
|
6498
6517
|
hookEvent.forceKeepAttr = void 0;
|
|
6499
|
-
|
|
6518
|
+
_executeHooks(hooks.uponSanitizeAttribute, currentNode, hookEvent);
|
|
6500
6519
|
value = hookEvent.attrValue;
|
|
6501
6520
|
if (SANITIZE_NAMED_PROPS && (lcName === "id" || lcName === "name")) {
|
|
6502
6521
|
_removeAttribute(name, currentNode);
|
|
@@ -6555,14 +6574,14 @@ function createDOMPurify() {
|
|
|
6555
6574
|
} catch (_) {
|
|
6556
6575
|
}
|
|
6557
6576
|
}
|
|
6558
|
-
|
|
6577
|
+
_executeHooks(hooks.afterSanitizeAttributes, currentNode, null);
|
|
6559
6578
|
};
|
|
6560
6579
|
const _sanitizeShadowDOM = function _sanitizeShadowDOM2(fragment) {
|
|
6561
6580
|
let shadowNode = null;
|
|
6562
6581
|
const shadowIterator = _createNodeIterator(fragment);
|
|
6563
|
-
|
|
6582
|
+
_executeHooks(hooks.beforeSanitizeShadowDOM, fragment, null);
|
|
6564
6583
|
while (shadowNode = shadowIterator.nextNode()) {
|
|
6565
|
-
|
|
6584
|
+
_executeHooks(hooks.uponSanitizeShadowNode, shadowNode, null);
|
|
6566
6585
|
if (_sanitizeElements(shadowNode)) {
|
|
6567
6586
|
continue;
|
|
6568
6587
|
}
|
|
@@ -6571,7 +6590,7 @@ function createDOMPurify() {
|
|
|
6571
6590
|
}
|
|
6572
6591
|
_sanitizeAttributes(shadowNode);
|
|
6573
6592
|
}
|
|
6574
|
-
|
|
6593
|
+
_executeHooks(hooks.afterSanitizeShadowDOM, fragment, null);
|
|
6575
6594
|
};
|
|
6576
6595
|
DOMPurify.sanitize = function(dirty) {
|
|
6577
6596
|
let cfg = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
|
|
@@ -6692,21 +6711,16 @@ function createDOMPurify() {
|
|
|
6692
6711
|
if (typeof hookFunction !== "function") {
|
|
6693
6712
|
return;
|
|
6694
6713
|
}
|
|
6695
|
-
hooks[entryPoint] = hooks[entryPoint] || [];
|
|
6696
6714
|
arrayPush(hooks[entryPoint], hookFunction);
|
|
6697
6715
|
};
|
|
6698
6716
|
DOMPurify.removeHook = function(entryPoint) {
|
|
6699
|
-
|
|
6700
|
-
return arrayPop(hooks[entryPoint]);
|
|
6701
|
-
}
|
|
6717
|
+
return arrayPop(hooks[entryPoint]);
|
|
6702
6718
|
};
|
|
6703
6719
|
DOMPurify.removeHooks = function(entryPoint) {
|
|
6704
|
-
|
|
6705
|
-
hooks[entryPoint] = [];
|
|
6706
|
-
}
|
|
6720
|
+
hooks[entryPoint] = [];
|
|
6707
6721
|
};
|
|
6708
6722
|
DOMPurify.removeAllHooks = function() {
|
|
6709
|
-
hooks =
|
|
6723
|
+
hooks = _createHooksMap();
|
|
6710
6724
|
};
|
|
6711
6725
|
return DOMPurify;
|
|
6712
6726
|
}
|