mirror of
https://github.com/penpot/penpot-plugins.git
synced 2025-01-22 22:58:43 -05:00
feat(plugins-runtime): fix types mismatch in runtime
This commit is contained in:
parent
6b94617029
commit
5dc0da98b9
1 changed files with 6 additions and 4 deletions
|
@ -258,18 +258,20 @@ export function createApi(context: PenpotContext, manifest: Manifest): Penpot {
|
||||||
return context.getSelectedShapes();
|
return context.getSelectedShapes();
|
||||||
},
|
},
|
||||||
|
|
||||||
getColors(shapes: PenpotShape[]): (PenpotColor & PenpotColorShapeInfo)[] {
|
shapesColors(
|
||||||
|
shapes: PenpotShape[]
|
||||||
|
): (PenpotColor & PenpotColorShapeInfo)[] {
|
||||||
// checkPermission('selection:read');
|
// checkPermission('selection:read');
|
||||||
return context.getColors(shapes);
|
return context.shapesColors(shapes);
|
||||||
},
|
},
|
||||||
|
|
||||||
changeColor(
|
replaceColor(
|
||||||
shapes: PenpotShape[],
|
shapes: PenpotShape[],
|
||||||
oldColor: PenpotColor,
|
oldColor: PenpotColor,
|
||||||
newColor: PenpotColor
|
newColor: PenpotColor
|
||||||
) {
|
) {
|
||||||
// checkPermission('selection:read');
|
// checkPermission('selection:read');
|
||||||
return context.changeColor(shapes, oldColor, newColor);
|
return context.replaceColor(shapes, oldColor, newColor);
|
||||||
},
|
},
|
||||||
|
|
||||||
getTheme(): PenpotTheme {
|
getTheme(): PenpotTheme {
|
||||||
|
|
Loading…
Add table
Reference in a new issue