postcss 8.3.9 → 8.3.11
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.
Potentially problematic release.
This version of postcss might be problematic. Click here for more details.
- package/lib/previous-map.js +10 -13
- package/lib/processor.js +1 -1
- package/package.json +3 -3
package/lib/previous-map.js
CHANGED
@@ -48,23 +48,20 @@ class PreviousMap {
|
|
48
48
|
}
|
49
49
|
|
50
50
|
getAnnotationURL(sourceMapString) {
|
51
|
-
return sourceMapString
|
52
|
-
.match(/\/\*\s*# sourceMappingURL=((?:(?!sourceMappingURL=).)*)\*\//)[1]
|
53
|
-
.trim()
|
51
|
+
return sourceMapString.replace(/^\/\*\s*# sourceMappingURL=/, '').trim()
|
54
52
|
}
|
55
53
|
|
56
54
|
loadAnnotation(css) {
|
57
|
-
let
|
58
|
-
|
59
|
-
)
|
55
|
+
let comments = css.match(/\/\*\s*# sourceMappingURL=/gm)
|
56
|
+
if (!comments) return
|
60
57
|
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
58
|
+
// sourceMappingURLs from comments, strings, etc.
|
59
|
+
let start = css.lastIndexOf(comments.pop())
|
60
|
+
let end = css.indexOf('*/', start)
|
61
|
+
|
62
|
+
if (start > -1 && end > -1) {
|
63
|
+
// Locate the last sourceMappingURL to avoid pickin
|
64
|
+
this.annotation = this.getAnnotationURL(css.substring(start, end))
|
68
65
|
}
|
69
66
|
}
|
70
67
|
|
package/lib/processor.js
CHANGED
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "postcss",
|
3
|
-
"version": "8.3.
|
3
|
+
"version": "8.3.11",
|
4
4
|
"description": "Tool for transforming styles with JS plugins",
|
5
5
|
"engines": {
|
6
6
|
"node": "^10 || ^12 || >=14"
|
@@ -64,8 +64,8 @@
|
|
64
64
|
"url": "https://github.com/postcss/postcss/issues"
|
65
65
|
},
|
66
66
|
"dependencies": {
|
67
|
-
"nanoid": "^3.1.
|
68
|
-
"picocolors": "^0.
|
67
|
+
"nanoid": "^3.1.30",
|
68
|
+
"picocolors": "^1.0.0",
|
69
69
|
"source-map-js": "^0.6.2"
|
70
70
|
},
|
71
71
|
"browser": {
|