mirror of
https://github.com/penpot/penpot-exporter-figma-plugin.git
synced 2024-12-22 05:33:02 -05:00
Merge branch 'main' into feature/autolayout
This commit is contained in:
commit
d2ab27b887
3 changed files with 8 additions and 3 deletions
5
.changeset/lucky-bottles-sparkle.md
Normal file
5
.changeset/lucky-bottles-sparkle.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
"penpot-exporter": minor
|
||||
---
|
||||
|
||||
Translate line endings done with shift+Enter in Figma
|
|
@ -30,7 +30,7 @@ export const transformInstanceNode = async (
|
|||
}
|
||||
|
||||
if (isExternalComponent(mainComponent)) {
|
||||
await registerExternalComponents(mainComponent);
|
||||
registerExternalComponents(mainComponent);
|
||||
}
|
||||
|
||||
return {
|
||||
|
@ -56,7 +56,7 @@ export const transformInstanceNode = async (
|
|||
};
|
||||
};
|
||||
|
||||
const registerExternalComponents = async (mainComponent: ComponentNode): Promise<void> => {
|
||||
const registerExternalComponents = (mainComponent: ComponentNode): void => {
|
||||
let component: ComponentSetNode | ComponentNode = mainComponent;
|
||||
|
||||
if (component.parent?.type === 'COMPONENT_SET') {
|
||||
|
|
|
@ -45,7 +45,7 @@ const splitTextNodeByEOL = (node: PenpotTextNode): PenpotTextNode[] => {
|
|||
|
||||
return split.map(text => ({
|
||||
...node,
|
||||
text: text
|
||||
text: text.replace(/\u2028/g, '\n')
|
||||
}));
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue