@pixerate/editor 0.259.0 → 0.260.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/agent/index.cjs +2 -2
- package/dist/agent/index.js +1 -1
- package/dist/animation-editor/index.cjs +61 -59
- package/dist/animation-editor/index.js +5 -3
- package/dist/brushes/index.cjs +52 -52
- package/dist/brushes/index.js +6 -6
- package/dist/{brushstrokeRender-JI4W6F2G.js → brushstrokeRender-25Q5BEY6.js} +17 -7
- package/dist/{brushstrokeRender-MQ6PSDM5.cjs → brushstrokeRender-N6UPZSQS.cjs} +31 -21
- package/dist/canvas/brushTypes.d.cts +5 -0
- package/dist/canvas/brushTypes.d.ts +5 -0
- package/dist/canvas/drawController.d.cts +15 -1
- package/dist/canvas/drawController.d.ts +15 -1
- package/dist/canvas/index.cjs +136 -102
- package/dist/canvas/index.js +35 -1
- package/dist/{chunk-3PPJRMIG.js → chunk-3O47TPGX.js} +197 -18
- package/dist/{chunk-5Q5MLXAD.cjs → chunk-3TQW5MPW.cjs} +23 -23
- package/dist/{chunk-JBBJE76O.cjs → chunk-3ZRNK3RO.cjs} +1138 -85
- package/dist/{chunk-YSGW7VV4.cjs → chunk-43NT242D.cjs} +1401 -228
- package/dist/{chunk-SMTUQWGY.js → chunk-5IW65VQ6.js} +1 -1
- package/dist/{chunk-YQ4PQTBB.js → chunk-6NZL24W4.js} +9 -1
- package/dist/{chunk-O3ZVZSNJ.cjs → chunk-7AUQ2UJ3.cjs} +137 -129
- package/dist/{chunk-4M4E3N6X.js → chunk-CQVTGBQI.js} +1 -1
- package/dist/{chunk-SSFMWJDK.js → chunk-D4TE5JNW.js} +1192 -19
- package/dist/{chunk-AORZ5M5C.js → chunk-EHALWBBD.js} +1 -1
- package/dist/{chunk-6WCQ35GI.cjs → chunk-NHA26O5X.cjs} +2 -2
- package/dist/{chunk-DPYAO5U6.cjs → chunk-PVJMTLPJ.cjs} +197 -18
- package/dist/{chunk-MQGQTKVW.cjs → chunk-PYTJBVW5.cjs} +29 -29
- package/dist/{chunk-IXQZHCOF.js → chunk-QAR2N7HZ.js} +1 -1
- package/dist/{chunk-5P4JEOIV.js → chunk-TMDDMJCR.js} +2 -2
- package/dist/{chunk-RSIKDWOP.cjs → chunk-TZOX7KWV.cjs} +15 -15
- package/dist/{chunk-IPUTIUGQ.cjs → chunk-UVZ7RQOE.cjs} +1 -1
- package/dist/{chunk-A7GJ6BXI.js → chunk-WJ4WQJCC.js} +1062 -9
- package/dist/{chunk-ICTPLVSR.js → chunk-X2EXYY4J.js} +1 -1
- package/dist/{chunk-WQCNC4DK.js → chunk-XC6DPRYI.js} +695 -4
- package/dist/{chunk-KBYB7OWB.cjs → chunk-YHDHFJUC.cjs} +776 -85
- package/dist/{chunk-P3PZ63M3.cjs → chunk-YLUIFXSL.cjs} +35 -35
- package/dist/commands/index.cjs +2 -2
- package/dist/commands/index.js +1 -1
- package/dist/image-editor/index.cjs +1385 -2484
- package/dist/image-editor/index.js +139 -1238
- package/dist/image-editor/selection-worker.cjs +3 -4
- package/dist/image-editor/selection-worker.js +1 -2
- package/dist/paint/index.cjs +3 -5
- package/dist/paint/index.js +40 -42
- package/dist/paint-editor/contract.d.cts +29 -0
- package/dist/paint-editor/contract.d.ts +29 -0
- package/dist/paint-editor/dab-stroke.d.cts +5 -0
- package/dist/paint-editor/dab-stroke.d.ts +5 -0
- package/dist/paint-editor/index.cjs +402 -258
- package/dist/paint-editor/index.d.cts +1 -0
- package/dist/paint-editor/index.d.ts +1 -0
- package/dist/paint-editor/index.js +197 -53
- package/dist/paint-editor/stamp-tip.d.cts +17 -0
- package/dist/paint-editor/stamp-tip.d.ts +17 -0
- package/dist/paint-editor/ui.d.cts +21 -1
- package/dist/paint-editor/ui.d.ts +21 -1
- package/dist/raster/index.cjs +2 -4
- package/dist/raster/index.js +6 -8
- package/dist/vector/brushstroke.d.cts +6 -0
- package/dist/vector/brushstroke.d.ts +6 -0
- package/dist/vector/controller.d.cts +11 -2
- package/dist/vector/controller.d.ts +11 -2
- package/dist/vector/index.cjs +990 -973
- package/dist/vector/index.js +28 -11
- package/package.json +1 -1
- package/skills/pixerate-brushes/SKILL.md +1 -1
- package/skills/pixerate-canvas/SKILL.md +3 -1
- package/skills/pixerate-vector/SKILL.md +2 -2
- package/dist/chunk-2VJAVXLI.js +0 -192
- package/dist/chunk-62Z5WLRA.js +0 -700
- package/dist/chunk-BOHDJJ2O.cjs +0 -192
- package/dist/chunk-NKGB64CW.cjs +0 -700
- package/dist/chunk-SS53NNZO.cjs +0 -1066
- package/dist/chunk-ZNA3IQZF.js +0 -1066
|
@@ -104,6 +104,8 @@ export interface VectorEditorOptions {
|
|
|
104
104
|
* profile decides which). Share one with the paint editor so a brush saved there paints here.
|
|
105
105
|
*/
|
|
106
106
|
brushLibrary?: Pick<BrushLibrary, 'list' | 'subscribe'>;
|
|
107
|
+
/** The app's colour scheme, which picks the side of a brush's light / dark default colour (default light). */
|
|
108
|
+
colorScheme?: 'light' | 'dark';
|
|
107
109
|
/** History to record into, e.g. one shared with the rest of the app (default: a new one). */
|
|
108
110
|
history?: HistoryManager;
|
|
109
111
|
/** Starting tool (default `select`). */
|
|
@@ -789,6 +791,7 @@ export declare class VectorEditorController {
|
|
|
789
791
|
private committing;
|
|
790
792
|
private revision;
|
|
791
793
|
private state;
|
|
794
|
+
private colorScheme;
|
|
792
795
|
constructor(options?: VectorEditorOptions);
|
|
793
796
|
/** Listens to the history (once; again after `destroy`). */
|
|
794
797
|
private connect;
|
|
@@ -1117,7 +1120,8 @@ export declare class VectorEditorController {
|
|
|
1117
1120
|
* Adds a brushstroke to the selected (or given) paths: a stroke layer that paints the path with
|
|
1118
1121
|
* brush `brushId` (a preset, or a saved brush of the brush library: `listBrushstrokeBrushes`), `size` document
|
|
1119
1122
|
* units across (default the brush's own), an optional `pressure` profile along the length, in
|
|
1120
|
-
* `color` (default the
|
|
1123
|
+
* `color` (default the brush's own default colour, unless `keepColour`; else the top stroke's
|
|
1124
|
+
* paint, else black) at `opacity`. At the top of the stroke
|
|
1121
1125
|
* stack or at `index`. A `seed` gives it the brush's character (jitter and the grain of `paper`,
|
|
1122
1126
|
* `null` for none); without one it renders plain. One undo step.
|
|
1123
1127
|
*/
|
|
@@ -1125,13 +1129,15 @@ export declare class VectorEditorController {
|
|
|
1125
1129
|
ids?: readonly string[];
|
|
1126
1130
|
index?: number;
|
|
1127
1131
|
color?: string;
|
|
1132
|
+
keepColour?: boolean;
|
|
1128
1133
|
opacity?: number;
|
|
1129
1134
|
}): VectorActionResult;
|
|
1130
1135
|
/**
|
|
1131
1136
|
* Changes brushstroke layer `index` (in the stroke stack, 0 is the bottom) of the selected (or
|
|
1132
1137
|
* given) paths: another brush, size, pressure profile (null removes it), colour or opacity, the
|
|
1133
1138
|
* character `seed` (null removes it: plain dabs) or the `paper` (replaced whole: `null` for no
|
|
1134
|
-
* grain, `{}` for the default paper).
|
|
1139
|
+
* grain, `{}` for the default paper). Another brush without a `color` takes that brush's default
|
|
1140
|
+
* colour, if it has one, unless `keepColour`. Fails, changing nothing, when that layer is not a
|
|
1135
1141
|
* brushstroke. With `merge`, consecutive edits fold into one undo step.
|
|
1136
1142
|
*/
|
|
1137
1143
|
setBrushstroke(index: number, patch: {
|
|
@@ -1139,6 +1145,7 @@ export declare class VectorEditorController {
|
|
|
1139
1145
|
size?: number | null;
|
|
1140
1146
|
pressure?: number[] | null;
|
|
1141
1147
|
color?: string;
|
|
1148
|
+
keepColour?: boolean;
|
|
1142
1149
|
opacity?: number;
|
|
1143
1150
|
seed?: number | null;
|
|
1144
1151
|
paper?: VectorBrushstrokePaper | null;
|
|
@@ -1146,6 +1153,8 @@ export declare class VectorEditorController {
|
|
|
1146
1153
|
ids?: readonly string[];
|
|
1147
1154
|
merge?: boolean | string;
|
|
1148
1155
|
}): VectorActionResult;
|
|
1156
|
+
/** Sets the colour scheme that picks the side of a brush's light / dark default colour. Existing strokes keep their colour. */
|
|
1157
|
+
setColorScheme(scheme: 'light' | 'dark'): void;
|
|
1149
1158
|
/** Removes layer `index` of the fill or stroke stack of the selected (or given) paths. */
|
|
1150
1159
|
removePaintLayer(kind: 'fill' | 'stroke', index: number, options?: {
|
|
1151
1160
|
ids?: readonly string[];
|
|
@@ -104,6 +104,8 @@ export interface VectorEditorOptions {
|
|
|
104
104
|
* profile decides which). Share one with the paint editor so a brush saved there paints here.
|
|
105
105
|
*/
|
|
106
106
|
brushLibrary?: Pick<BrushLibrary, 'list' | 'subscribe'>;
|
|
107
|
+
/** The app's colour scheme, which picks the side of a brush's light / dark default colour (default light). */
|
|
108
|
+
colorScheme?: 'light' | 'dark';
|
|
107
109
|
/** History to record into, e.g. one shared with the rest of the app (default: a new one). */
|
|
108
110
|
history?: HistoryManager;
|
|
109
111
|
/** Starting tool (default `select`). */
|
|
@@ -789,6 +791,7 @@ export declare class VectorEditorController {
|
|
|
789
791
|
private committing;
|
|
790
792
|
private revision;
|
|
791
793
|
private state;
|
|
794
|
+
private colorScheme;
|
|
792
795
|
constructor(options?: VectorEditorOptions);
|
|
793
796
|
/** Listens to the history (once; again after `destroy`). */
|
|
794
797
|
private connect;
|
|
@@ -1117,7 +1120,8 @@ export declare class VectorEditorController {
|
|
|
1117
1120
|
* Adds a brushstroke to the selected (or given) paths: a stroke layer that paints the path with
|
|
1118
1121
|
* brush `brushId` (a preset, or a saved brush of the brush library: `listBrushstrokeBrushes`), `size` document
|
|
1119
1122
|
* units across (default the brush's own), an optional `pressure` profile along the length, in
|
|
1120
|
-
* `color` (default the
|
|
1123
|
+
* `color` (default the brush's own default colour, unless `keepColour`; else the top stroke's
|
|
1124
|
+
* paint, else black) at `opacity`. At the top of the stroke
|
|
1121
1125
|
* stack or at `index`. A `seed` gives it the brush's character (jitter and the grain of `paper`,
|
|
1122
1126
|
* `null` for none); without one it renders plain. One undo step.
|
|
1123
1127
|
*/
|
|
@@ -1125,13 +1129,15 @@ export declare class VectorEditorController {
|
|
|
1125
1129
|
ids?: readonly string[];
|
|
1126
1130
|
index?: number;
|
|
1127
1131
|
color?: string;
|
|
1132
|
+
keepColour?: boolean;
|
|
1128
1133
|
opacity?: number;
|
|
1129
1134
|
}): VectorActionResult;
|
|
1130
1135
|
/**
|
|
1131
1136
|
* Changes brushstroke layer `index` (in the stroke stack, 0 is the bottom) of the selected (or
|
|
1132
1137
|
* given) paths: another brush, size, pressure profile (null removes it), colour or opacity, the
|
|
1133
1138
|
* character `seed` (null removes it: plain dabs) or the `paper` (replaced whole: `null` for no
|
|
1134
|
-
* grain, `{}` for the default paper).
|
|
1139
|
+
* grain, `{}` for the default paper). Another brush without a `color` takes that brush's default
|
|
1140
|
+
* colour, if it has one, unless `keepColour`. Fails, changing nothing, when that layer is not a
|
|
1135
1141
|
* brushstroke. With `merge`, consecutive edits fold into one undo step.
|
|
1136
1142
|
*/
|
|
1137
1143
|
setBrushstroke(index: number, patch: {
|
|
@@ -1139,6 +1145,7 @@ export declare class VectorEditorController {
|
|
|
1139
1145
|
size?: number | null;
|
|
1140
1146
|
pressure?: number[] | null;
|
|
1141
1147
|
color?: string;
|
|
1148
|
+
keepColour?: boolean;
|
|
1142
1149
|
opacity?: number;
|
|
1143
1150
|
seed?: number | null;
|
|
1144
1151
|
paper?: VectorBrushstrokePaper | null;
|
|
@@ -1146,6 +1153,8 @@ export declare class VectorEditorController {
|
|
|
1146
1153
|
ids?: readonly string[];
|
|
1147
1154
|
merge?: boolean | string;
|
|
1148
1155
|
}): VectorActionResult;
|
|
1156
|
+
/** Sets the colour scheme that picks the side of a brush's light / dark default colour. Existing strokes keep their colour. */
|
|
1157
|
+
setColorScheme(scheme: 'light' | 'dark'): void;
|
|
1149
1158
|
/** Removes layer `index` of the fill or stroke stack of the selected (or given) paths. */
|
|
1150
1159
|
removePaintLayer(kind: 'fill' | 'stroke', index: number, options?: {
|
|
1151
1160
|
ids?: readonly string[];
|