diff --git a/packages/uni-h5/dist/uni-h5.cjs.js b/packages/uni-h5/dist/uni-h5.cjs.js index 121c3cf038b32b5be3e3da8ddd2af00b92b88309..2918d869ed08ccd754016a9b5cda6d73d6e16481 100644 --- a/packages/uni-h5/dist/uni-h5.cjs.js +++ b/packages/uni-h5/dist/uni-h5.cjs.js @@ -5024,7 +5024,7 @@ function decodeEntities(htmlString) { return wrap.innerText || wrap.textContent; }); } -function parseNodes(nodes, parentNode) { +function parseNodes(nodes, parentNode, scopeId) { nodes.forEach(function(node) { if (!shared.isPlainObject(node)) { return; @@ -5051,6 +5051,7 @@ function parseNodes(nodes, parentNode) { Array.isArray(value) && (value = value.join(" ")); case "style": elem.setAttribute(name, value); + scopeId && elem.setAttribute(scopeId, ""); break; default: if (tagAttrs.indexOf(name) !== -1) { @@ -5087,12 +5088,13 @@ var index$p = /* @__PURE__ */ defineBuiltInComponent({ }, props: props$f, setup(props2) { + const vm = vue.getCurrentInstance(); const rootRef = vue.ref(null); function _renderNodes(nodes) { if (typeof nodes === "string") { nodes = parseHtml(nodes); } - const nodeList = parseNodes(nodes, document.createDocumentFragment()); + const nodeList = parseNodes(nodes, document.createDocumentFragment(), (vm == null ? void 0 : vm.root.type).__scopeId || ""); rootRef.value.firstElementChild.innerHTML = ""; rootRef.value.firstElementChild.appendChild(nodeList); } diff --git a/packages/uni-h5/dist/uni-h5.es.js b/packages/uni-h5/dist/uni-h5.es.js index 507c76848e35809eb7e9c3ebde26b112f62e8f11..42f177195c710a25a4552918b303e3585973c13c 100644 --- a/packages/uni-h5/dist/uni-h5.es.js +++ b/packages/uni-h5/dist/uni-h5.es.js @@ -11365,7 +11365,7 @@ function decodeEntities(htmlString) { return wrap.innerText || wrap.textContent; }); } -function parseNodes(nodes, parentNode) { +function parseNodes(nodes, parentNode, scopeId) { nodes.forEach(function(node) { if (!isPlainObject(node)) { return; @@ -11392,6 +11392,7 @@ function parseNodes(nodes, parentNode) { Array.isArray(value) && (value = value.join(" ")); case "style": elem.setAttribute(name, value); + scopeId && elem.setAttribute(scopeId, ""); break; default: if (tagAttrs.indexOf(name) !== -1) { @@ -11428,12 +11429,13 @@ var index$m = /* @__PURE__ */ defineBuiltInComponent({ }, props: props$m, setup(props2) { + const vm = getCurrentInstance(); const rootRef = ref(null); function _renderNodes(nodes) { if (typeof nodes === "string") { nodes = parseHtml(nodes); } - const nodeList = parseNodes(nodes, document.createDocumentFragment()); + const nodeList = parseNodes(nodes, document.createDocumentFragment(), (vm == null ? void 0 : vm.root.type).__scopeId || ""); rootRef.value.firstElementChild.innerHTML = ""; rootRef.value.firstElementChild.appendChild(nodeList); } diff --git a/packages/uni-stat/dist/uni-stat.cjs.js b/packages/uni-stat/dist/uni-stat.cjs.js index f6f27a002d724721a353dda60d8dbfad5e9bf7c8..0a05590377f7abccd4d87a15eac6c6981fabb86f 100644 --- a/packages/uni-stat/dist/uni-stat.cjs.js +++ b/packages/uni-stat/dist/uni-stat.cjs.js @@ -1,6 +1,6 @@ 'use strict'; -var version = "3.0.0-alpha-3021020211012003"; +var version = "3.0.0-alpha-3021020211012004"; const STAT_VERSION = version; const STAT_URL = 'https://tongji.dcloud.io/uni/stat'; diff --git a/packages/uni-stat/dist/uni-stat.es.js b/packages/uni-stat/dist/uni-stat.es.js index 2efce242d51f142f693e6f78cce06f50943c1b17..64ddc8f5eba3848b524178e2252ac1ff7b2145e3 100644 --- a/packages/uni-stat/dist/uni-stat.es.js +++ b/packages/uni-stat/dist/uni-stat.es.js @@ -1,4 +1,4 @@ -var version = "3.0.0-alpha-3021020211012003"; +var version = "3.0.0-alpha-3021020211012004"; const STAT_VERSION = version; const STAT_URL = 'https://tongji.dcloud.io/uni/stat';