mirror of
https://github.com/penpot/penpot-exporter-figma-plugin.git
synced 2024-12-22 05:33:02 -05:00
Avoid adding indentation for texts with no indent (#156)
* Avoid adding indentation for texts with no indent * fix previous changelog
This commit is contained in:
parent
342ab90e69
commit
6fc812a08f
3 changed files with 9 additions and 2 deletions
|
@ -1,5 +1,5 @@
|
|||
---
|
||||
"penpot-exporter": minor
|
||||
"penpot-exporter": patch
|
||||
---
|
||||
|
||||
Translate line endings done with shift+Enter in Figma
|
||||
|
|
5
.changeset/proud-foxes-jump.md
Normal file
5
.changeset/proud-foxes-jump.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
"penpot-exporter": patch
|
||||
---
|
||||
|
||||
Do not apply indentation to texts with indent zero
|
|
@ -63,7 +63,9 @@ export class Paragraph {
|
|||
return false;
|
||||
}
|
||||
|
||||
private segmentIndent(indent: number): PenpotTextNode {
|
||||
private segmentIndent(indent: number): PenpotTextNode | undefined {
|
||||
if (indent === 0) return;
|
||||
|
||||
return {
|
||||
text: ' '.repeat(indent),
|
||||
fontId: 'sourcesanspro',
|
||||
|
|
Loading…
Reference in a new issue