Skip to content

Commit

Permalink
fixes (#177)
Browse files Browse the repository at this point in the history
  • Loading branch information
Cenadros authored Jun 18, 2024
1 parent 4edb964 commit 8eb2b1a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion plugin-src/transformers/partials/transformLayout.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export const transformLayoutAttributes = (
> => {
return {
'layoutItemH-Sizing': translateLayoutSizing(node.layoutSizingHorizontal, isFrame),
'layoutItemV-Sizing': translateLayoutSizing(node.layoutSizingVertical),
'layoutItemV-Sizing': translateLayoutSizing(node.layoutSizingVertical, isFrame),
'layoutItemAbsolute': node.layoutPositioning === 'ABSOLUTE',
'layoutItemMaxH': node.maxHeight ?? undefined,
'layoutItemMinH': node.minHeight ?? undefined,
Expand Down
4 changes: 2 additions & 2 deletions plugin-src/translators/translateLayout.ts
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,8 @@ export const translateLayoutSizing = (
case 'FIXED':
return 'fix';
case 'HUG':
return isFrame ? 'fix' : 'auto'; // @TODO: Penpot does not handle hug in frames as figma does
return 'auto';
case 'FILL':
return 'fill';
return isFrame ? 'fix' : 'fill'; // @TODO: Penpot does not handle fill in frames as figma does
}
};

0 comments on commit 8eb2b1a

Please sign in to comment.