@pixerate/editor 0.264.1 → 0.265.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/animation-editor/index.cjs +60 -61
- package/dist/animation-editor/index.js +4 -5
- package/dist/brushes/index.cjs +73 -60
- package/dist/brushes/index.d.cts +1 -0
- package/dist/brushes/index.d.ts +1 -0
- package/dist/brushes/index.js +17 -4
- package/dist/brushes/preview.d.cts +59 -0
- package/dist/brushes/preview.d.ts +59 -0
- package/dist/brushes/tools.d.cts +12 -5
- package/dist/brushes/tools.d.ts +12 -5
- package/dist/{brushstrokeRender-3MOI7PH4.js → brushstrokeRender-4UB6NRJW.js} +11 -4
- package/dist/{brushstrokeRender-SMMPIJF2.cjs → brushstrokeRender-JQ2XQRUD.cjs} +22 -15
- package/dist/canvas/brushstroke.d.cts +6 -1
- package/dist/canvas/brushstroke.d.ts +6 -1
- package/dist/canvas/index.cjs +16 -17
- package/dist/canvas/index.js +2 -3
- package/dist/{chunk-F3KKR6DD.cjs → chunk-5OE4ZZ6V.cjs} +30 -30
- package/dist/{chunk-BY5EBP26.cjs → chunk-677777GH.cjs} +3 -3
- package/dist/{chunk-G5ADO47G.cjs → chunk-7NQOGWLM.cjs} +3 -2
- package/dist/{chunk-WWI6FLH2.js → chunk-7PW6VCNW.js} +2 -2
- package/dist/{chunk-CECCP2V7.js → chunk-BLR4KWYQ.js} +1 -1
- package/dist/chunk-DEBIFWY6.cjs +77 -0
- package/dist/{chunk-KXNZNOEF.cjs → chunk-DGXTEPCU.cjs} +94 -94
- package/dist/{chunk-3CI7FRMK.js → chunk-DVPQFMH6.js} +13 -1
- package/dist/{chunk-EE7SAYBF.js → chunk-J4SGJCPW.js} +3 -3
- package/dist/{chunk-A2IS7EHE.cjs → chunk-JBZRVLXV.cjs} +14 -2
- package/dist/{chunk-V7MJ4HIN.cjs → chunk-NOP4Y5AB.cjs} +23 -23
- package/dist/{chunk-FQC5TDB6.cjs → chunk-O53MOGXG.cjs} +35 -35
- package/dist/{chunk-4OJC4MCD.js → chunk-Q6RVVJW6.js} +1 -1
- package/dist/{chunk-HAUDEVMC.js → chunk-WY23AUCA.js} +2 -2
- package/dist/{chunk-JEML4FSA.js → chunk-XDNWQMHY.js} +3 -2
- package/dist/{chunk-ROBSFJ6F.js → chunk-Z2Z2OHRM.js} +1 -1
- package/dist/{chunk-USJX5SW4.cjs → chunk-ZHRVCW3M.cjs} +12 -12
- package/dist/chunk-ZS7LB2MV.js +77 -0
- package/dist/image-editor/index.cjs +788 -790
- package/dist/image-editor/index.js +6 -8
- package/dist/paint-editor/index.cjs +88 -84
- package/dist/paint-editor/index.js +12 -8
- package/dist/vector/index.cjs +970 -971
- package/dist/vector/index.js +5 -6
- package/package.json +1 -1
- package/skills/pixerate-brushes/SKILL.md +7 -2
- package/dist/chunk-FJBQTZS4.js +0 -17
- package/dist/chunk-LRTR4ASZ.cjs +0 -17
package/dist/vector/index.js
CHANGED
|
@@ -26,7 +26,7 @@ import {
|
|
|
26
26
|
traceField,
|
|
27
27
|
traceVectorImage,
|
|
28
28
|
vectorTraceContours
|
|
29
|
-
} from "../chunk-
|
|
29
|
+
} from "../chunk-BLR4KWYQ.js";
|
|
30
30
|
import {
|
|
31
31
|
applyHomography,
|
|
32
32
|
homographyFromPoints,
|
|
@@ -53,7 +53,7 @@ import {
|
|
|
53
53
|
reverseMorphContour,
|
|
54
54
|
subpathToMorphContour,
|
|
55
55
|
turnMorphContour
|
|
56
|
-
} from "../chunk-
|
|
56
|
+
} from "../chunk-Z2Z2OHRM.js";
|
|
57
57
|
import {
|
|
58
58
|
DEFAULT_VECTOR_FONT,
|
|
59
59
|
IDENTITY_MATRIX,
|
|
@@ -529,10 +529,10 @@ import {
|
|
|
529
529
|
withVectorStrokes,
|
|
530
530
|
withVectorTargetPaint,
|
|
531
531
|
zigzagPaths
|
|
532
|
-
} from "../chunk-
|
|
532
|
+
} from "../chunk-7PW6VCNW.js";
|
|
533
533
|
import {
|
|
534
534
|
snapshotBrushLibrary
|
|
535
|
-
} from "../chunk-
|
|
535
|
+
} from "../chunk-J4SGJCPW.js";
|
|
536
536
|
import "../chunk-ACFSFUQH.js";
|
|
537
537
|
import {
|
|
538
538
|
createProvenance
|
|
@@ -559,8 +559,7 @@ import {
|
|
|
559
559
|
fitCubics,
|
|
560
560
|
parseSvgPath
|
|
561
561
|
} from "../chunk-PWBZH3FK.js";
|
|
562
|
-
import "../chunk-
|
|
563
|
-
import "../chunk-3CI7FRMK.js";
|
|
562
|
+
import "../chunk-DVPQFMH6.js";
|
|
564
563
|
import {
|
|
565
564
|
StickerError
|
|
566
565
|
} from "../chunk-SZTI6EER.js";
|
package/package.json
CHANGED
|
@@ -83,8 +83,13 @@ drawn.
|
|
|
83
83
|
- Give a brush a `colour.default` only when the medium has a typical colour (blue ballpoint,
|
|
84
84
|
yellow highlighter): choosing the brush sets it as the user's colour. Use a light / dark pair
|
|
85
85
|
when the right colour depends on the background (white chalk on a dark board, graphite on
|
|
86
|
-
paper), and a `palette` for the other usual colours.
|
|
87
|
-
|
|
86
|
+
paper), and a `palette` for the other usual colours. Dark inks need a pair too (navy / light
|
|
87
|
+
blue, near-black / near-white): a single dark default vanishes in a dark-scheme editor. Check
|
|
88
|
+
each side against the background it is for (3:1 at least). `colour.own` only for brushes that
|
|
89
|
+
must always paint their own (a rainbow marker).
|
|
90
|
+
- Previews and thumbnails pick their own colour against what they are drawn on (the brush's
|
|
91
|
+
default when it reads there, else a colour for the medium). Don't give a brush a default just
|
|
92
|
+
to make its preview visible: choosing the brush makes that default the user's colour.
|
|
88
93
|
- Stamp tips paint the sticker's shape in the paint colour; to keep a sticker's own colours, use
|
|
89
94
|
`marks` objects instead.
|
|
90
95
|
|
package/dist/chunk-FJBQTZS4.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
parseCssColor
|
|
3
|
-
} from "./chunk-3CI7FRMK.js";
|
|
4
|
-
import {
|
|
5
|
-
isDualColor,
|
|
6
|
-
resolveColor
|
|
7
|
-
} from "./chunk-VR6OGHU5.js";
|
|
8
|
-
|
|
9
|
-
// src/brushes/colour.ts
|
|
10
|
-
function brushColourHex(value, scheme) {
|
|
11
|
-
const css = typeof value === "string" || isDualColor(value) ? resolveColor(value, scheme) : null;
|
|
12
|
-
return css ? parseCssColor(css)?.hex.toLowerCase() ?? null : null;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
export {
|
|
16
|
-
brushColourHex
|
|
17
|
-
};
|
package/dist/chunk-LRTR4ASZ.cjs
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
|
-
|
|
3
|
-
var _chunkA2IS7EHEcjs = require('./chunk-A2IS7EHE.cjs');
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
var _chunkMLLTWAXHcjs = require('./chunk-MLLTWAXH.cjs');
|
|
8
|
-
|
|
9
|
-
// src/brushes/colour.ts
|
|
10
|
-
function brushColourHex(value, scheme) {
|
|
11
|
-
const css = typeof value === "string" || _chunkMLLTWAXHcjs.isDualColor.call(void 0, value) ? _chunkMLLTWAXHcjs.resolveColor.call(void 0, value, scheme) : null;
|
|
12
|
-
return css ? _nullishCoalesce(_optionalChain([_chunkA2IS7EHEcjs.parseCssColor.call(void 0, css), 'optionalAccess', _ => _.hex, 'access', _2 => _2.toLowerCase, 'call', _3 => _3()]), () => ( null)) : null;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
exports.brushColourHex = brushColourHex;
|