Skip to content

Commit

Permalink
simplify star
Browse files Browse the repository at this point in the history
  • Loading branch information
jordisala1991 committed Apr 16, 2024
1 parent 4f6b5fe commit 514e597
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 26 deletions.
1 change: 0 additions & 1 deletion plugin-src/transformers/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,5 @@ export * from './transformPageNode';
export * from './transformPolygonNode';
export * from './transformRectangleNode';
export * from './transformSceneNode';
export * from './transformStarNode';
export * from './transformTextNode';
export * from './transformVectorNode';
2 changes: 1 addition & 1 deletion plugin-src/transformers/transformPolygonNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { translateFills, translateStrokes, translateVectorPaths } from '@plugin/
import { PathShape } from '@ui/lib/types/path/pathShape';

export const transformPolygonNode = (
node: PolygonNode,
node: DefaultShapeMixin,
baseX: number,
baseY: number
): PathShape => {
Expand Down
4 changes: 1 addition & 3 deletions plugin-src/transformers/transformSceneNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import {
transformImageNode,
transformPolygonNode,
transformRectangleNode,
transformStarNode,
transformTextNode,
transformVectorNode
} from '.';
Expand Down Expand Up @@ -43,12 +42,11 @@ export const transformSceneNode = async (
return await transformGroupNode(node, baseX, baseY);
case 'TEXT':
return transformTextNode(node, baseX, baseY);
case 'STAR':
case 'POLYGON':
return transformPolygonNode(node, baseX, baseY);
case 'VECTOR':
return transformVectorNode(node, baseX, baseY);
case 'STAR':
return transformStarNode(node, baseX, baseY);
}

throw new Error(`Unsupported node type: ${node.type}`);
Expand Down
21 changes: 0 additions & 21 deletions plugin-src/transformers/transformStarNode.ts

This file was deleted.

0 comments on commit 514e597

Please sign in to comment.