@atlaspack/packager-svg 2.12.1-dev.3368 → 2.12.1-dev.3401
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/lib/SVGPackager.js +3 -3
- package/package.json +6 -6
- package/src/SVGPackager.js +3 -3
package/lib/SVGPackager.js
CHANGED
|
@@ -88,13 +88,13 @@ var _default = exports.default = new (_plugin().Packager)({
|
|
|
88
88
|
async function replaceInlineAssetContent(bundleGraph, getInlineBundleContents, tree) {
|
|
89
89
|
const inlineNodes = [];
|
|
90
90
|
tree.walk(node => {
|
|
91
|
-
if (node.attrs && node.attrs['data-
|
|
91
|
+
if (node.attrs && node.attrs['data-parcel-key']) {
|
|
92
92
|
inlineNodes.push(node);
|
|
93
93
|
}
|
|
94
94
|
return node;
|
|
95
95
|
});
|
|
96
96
|
for (const node of inlineNodes) {
|
|
97
|
-
const newContent = await getAssetContent(bundleGraph, getInlineBundleContents, node.attrs['data-
|
|
97
|
+
const newContent = await getAssetContent(bundleGraph, getInlineBundleContents, node.attrs['data-parcel-key']);
|
|
98
98
|
if (newContent === null) {
|
|
99
99
|
continue;
|
|
100
100
|
}
|
|
@@ -109,7 +109,7 @@ async function replaceInlineAssetContent(bundleGraph, getInlineBundleContents, t
|
|
|
109
109
|
}
|
|
110
110
|
|
|
111
111
|
// remove attr from output
|
|
112
|
-
delete node.attrs['data-
|
|
112
|
+
delete node.attrs['data-parcel-key'];
|
|
113
113
|
}
|
|
114
114
|
return tree;
|
|
115
115
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaspack/packager-svg",
|
|
3
|
-
"version": "2.12.1-dev.
|
|
3
|
+
"version": "2.12.1-dev.3401+b483af77f",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -13,13 +13,13 @@
|
|
|
13
13
|
"source": "src/SVGPackager.js",
|
|
14
14
|
"engines": {
|
|
15
15
|
"node": ">= 16.0.0",
|
|
16
|
-
"
|
|
16
|
+
"parcel": "^2.12.1-dev.3401+b483af77f"
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@atlaspack/plugin": "2.12.1-dev.
|
|
20
|
-
"@atlaspack/types": "2.12.1-dev.
|
|
21
|
-
"@atlaspack/utils": "2.12.1-dev.
|
|
19
|
+
"@atlaspack/plugin": "2.12.1-dev.3401+b483af77f",
|
|
20
|
+
"@atlaspack/types": "2.12.1-dev.3401+b483af77f",
|
|
21
|
+
"@atlaspack/utils": "2.12.1-dev.3401+b483af77f",
|
|
22
22
|
"posthtml": "^0.16.4"
|
|
23
23
|
},
|
|
24
|
-
"gitHead": "
|
|
24
|
+
"gitHead": "b483af77f02d1258c8dad156e097b94f83671d8e"
|
|
25
25
|
}
|
package/src/SVGPackager.js
CHANGED
|
@@ -82,7 +82,7 @@ async function replaceInlineAssetContent(
|
|
|
82
82
|
) {
|
|
83
83
|
const inlineNodes = [];
|
|
84
84
|
tree.walk(node => {
|
|
85
|
-
if (node.attrs && node.attrs['data-
|
|
85
|
+
if (node.attrs && node.attrs['data-parcel-key']) {
|
|
86
86
|
inlineNodes.push(node);
|
|
87
87
|
}
|
|
88
88
|
return node;
|
|
@@ -92,7 +92,7 @@ async function replaceInlineAssetContent(
|
|
|
92
92
|
const newContent = await getAssetContent(
|
|
93
93
|
bundleGraph,
|
|
94
94
|
getInlineBundleContents,
|
|
95
|
-
node.attrs['data-
|
|
95
|
+
node.attrs['data-parcel-key'],
|
|
96
96
|
);
|
|
97
97
|
|
|
98
98
|
if (newContent === null) {
|
|
@@ -110,7 +110,7 @@ async function replaceInlineAssetContent(
|
|
|
110
110
|
}
|
|
111
111
|
|
|
112
112
|
// remove attr from output
|
|
113
|
-
delete node.attrs['data-
|
|
113
|
+
delete node.attrs['data-parcel-key'];
|
|
114
114
|
}
|
|
115
115
|
|
|
116
116
|
return tree;
|