mirror of
https://github.com/konvajs/konva.git
synced 2025-06-28 02:03:47 +08:00
Merge pull request #1772 from squoddam/fix-fill-type-gradient
Update `fill` type to accept `CanvasGradient`
This commit is contained in:
commit
cb0cbbfe3d
@ -26,7 +26,7 @@ export type LineJoin = 'round' | 'bevel' | 'miter';
|
||||
export type LineCap = 'butt' | 'round' | 'square';
|
||||
|
||||
export interface ShapeConfig extends NodeConfig {
|
||||
fill?: string;
|
||||
fill?: string | CanvasGradient;
|
||||
fillPatternImage?: HTMLImageElement;
|
||||
fillPatternX?: number;
|
||||
fillPatternY?: number;
|
||||
@ -766,7 +766,7 @@ export class Shape<
|
||||
dash: GetSet<number[], this>;
|
||||
dashEnabled: GetSet<boolean, this>;
|
||||
dashOffset: GetSet<number, this>;
|
||||
fill: GetSet<string, this>;
|
||||
fill: GetSet<string | CanvasGradient, this>;
|
||||
fillEnabled: GetSet<boolean, this>;
|
||||
fillLinearGradientColorStops: GetSet<Array<number | string>, this>;
|
||||
fillLinearGradientStartPoint: GetSet<Vector2d, this>;
|
||||
@ -815,7 +815,7 @@ export class Shape<
|
||||
shadowOffsetY: GetSet<number, this>;
|
||||
shadowOpacity: GetSet<number, this>;
|
||||
shadowBlur: GetSet<number, this>;
|
||||
stroke: GetSet<string, this>;
|
||||
stroke: GetSet<string | CanvasGradient, this>;
|
||||
strokeEnabled: GetSet<boolean, this>;
|
||||
fillAfterStrokeEnabled: GetSet<boolean, this>;
|
||||
strokeScaleEnabled: GetSet<boolean, this>;
|
||||
|
Loading…
Reference in New Issue
Block a user