0
Fork 0
mirror of https://github.com/penpot/penpot-exporter-figma-plugin.git synced 2025-01-05 06:10:52 -05:00
penpot-exporter-figma-plugin/ui-src/converters/createPenpotText.ts

11 lines
358 B
TypeScript
Raw Normal View History

2024-05-13 03:12:58 -05:00
import { PenpotFile } from '@ui/lib/types/penpotFile';
import { TextShape } from '@ui/lib/types/shapes/textShape';
2024-04-16 04:24:53 -05:00
import { translateUiBlendMode } from '@ui/translators';
2024-04-08 10:50:01 -05:00
export const createPenpotText = (file: PenpotFile, { type, blendMode, ...rest }: TextShape) => {
file.createText({
2024-04-16 04:24:53 -05:00
blendMode: translateUiBlendMode(blendMode),
...rest
2024-04-08 10:50:01 -05:00
});
};