@glissade/core 0.52.0-pre.0 → 0.52.1-pre.0
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/track.js +7 -1
- package/package.json +1 -1
package/dist/track.js
CHANGED
|
@@ -412,11 +412,17 @@ const HEX_RE = /^#([0-9a-f]{3}|[0-9a-f]{4}|[0-9a-f]{6}|[0-9a-f]{8})$/i;
|
|
|
412
412
|
const RGB_RE = /^rgba?\(\s*([\d.]+)\s*[, ]\s*([\d.]+)\s*[, ]\s*([\d.]+)\s*(?:[,/]\s*([\d.]+%?)\s*)?\)$/i;
|
|
413
413
|
var ColorParseError = class extends Error {
|
|
414
414
|
constructor(input) {
|
|
415
|
-
super(`cannot parse color '${input}' (supported: #rgb[a], #rrggbb[aa], rgb()/rgba())`);
|
|
415
|
+
super(`cannot parse color '${input}' (supported: transparent, #rgb[a], #rrggbb[aa], rgb()/rgba())`);
|
|
416
416
|
this.name = "ColorParseError";
|
|
417
417
|
}
|
|
418
418
|
};
|
|
419
419
|
function parseColor(input) {
|
|
420
|
+
if (/^transparent$/i.test(input)) return {
|
|
421
|
+
r: 0,
|
|
422
|
+
g: 0,
|
|
423
|
+
b: 0,
|
|
424
|
+
a: 0
|
|
425
|
+
};
|
|
420
426
|
const hex = HEX_RE.exec(input);
|
|
421
427
|
if (hex) {
|
|
422
428
|
let h = hex[1];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@glissade/core",
|
|
3
|
-
"version": "0.52.
|
|
3
|
+
"version": "0.52.1-pre.0",
|
|
4
4
|
"description": "glissade core: signals, tracks, timeline document, evaluation, easing, springs, seeded RNG. Zero DOM/Node dependencies.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"engines": {
|