mirror of
https://github.com/penpot/penpot-exporter-figma-plugin.git
synced 2024-12-22 21:53:27 -05:00
17 lines
397 B
TypeScript
17 lines
397 B
TypeScript
import { PenpotFile } from '@ui/lib/types/penpotFile';
|
|
import { FrameShape } from '@ui/lib/types/shapes/frameShape';
|
|
|
|
import { createPenpotItem } from '.';
|
|
|
|
export const createPenpotArtboard = (
|
|
file: PenpotFile,
|
|
{ type, children = [], ...rest }: FrameShape
|
|
) => {
|
|
file.addArtboard(rest);
|
|
|
|
for (const child of children) {
|
|
createPenpotItem(file, child);
|
|
}
|
|
|
|
file.closeArtboard();
|
|
};
|