@effing/canvas 0.24.0 → 0.24.2
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/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -72,6 +72,7 @@ var INHERITABLE_PROPS = [
|
|
|
72
72
|
"lineClamp",
|
|
73
73
|
"textBoxTrim",
|
|
74
74
|
"textBoxEdge",
|
|
75
|
+
"textShadow",
|
|
75
76
|
"WebkitTextStrokeWidth",
|
|
76
77
|
"WebkitTextStrokeColor"
|
|
77
78
|
];
|
|
@@ -2564,7 +2565,7 @@ function drawStrokeWithLetterSpacing(ctx, text, x, y, letterSpacing, strokeWidth
|
|
|
2564
2565
|
}
|
|
2565
2566
|
function drawTextShadow(ctx, text, x, y, shadow) {
|
|
2566
2567
|
const parts = shadow.match(
|
|
2567
|
-
/(-?\d+(?:\.\d+)?)\s*px?\s+(-?\d+(?:\.\d+)?)\s*px?\s+(-?\d+(?:\.\d+)?)\s*px?\s+(.*)/
|
|
2568
|
+
/(-?\d+(?:\.\d+)?)\s*(?:px)?\s+(-?\d+(?:\.\d+)?)\s*(?:px)?\s+(-?\d+(?:\.\d+)?)\s*(?:px)?\s+(.*)/
|
|
2568
2569
|
);
|
|
2569
2570
|
if (!parts) return;
|
|
2570
2571
|
ctx.save();
|