From 199984d961cbf194aaab28add2a78e97026cdebb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20S=C3=A1nchez?= Date: Mon, 17 Jun 2024 17:47:53 +0200 Subject: [PATCH] added min-max height-width (#171) --- .../transformers/partials/transformLayout.ts | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/plugin-src/transformers/partials/transformLayout.ts b/plugin-src/transformers/partials/transformLayout.ts index 2869c45a..6f235319 100644 --- a/plugin-src/transformers/partials/transformLayout.ts +++ b/plugin-src/transformers/partials/transformLayout.ts @@ -34,11 +34,21 @@ export const transformLayoutAttributes = ( node: LayoutMixin ): Pick< LayoutChildAttributes, - 'layoutItemH-Sizing' | 'layoutItemV-Sizing' | 'layoutItemAbsolute' + | 'layoutItemH-Sizing' + | 'layoutItemV-Sizing' + | 'layoutItemAbsolute' + | 'layoutItemMaxH' + | 'layoutItemMinH' + | 'layoutItemMaxW' + | 'layoutItemMinW' > => { return { 'layoutItemH-Sizing': translateLayoutSizing(node.layoutSizingHorizontal), 'layoutItemV-Sizing': translateLayoutSizing(node.layoutSizingVertical), - 'layoutItemAbsolute': node.layoutPositioning === 'ABSOLUTE' + 'layoutItemAbsolute': node.layoutPositioning === 'ABSOLUTE', + 'layoutItemMaxH': node.maxHeight ?? undefined, + 'layoutItemMinH': node.minHeight ?? undefined, + 'layoutItemMaxW': node.maxWidth ?? undefined, + 'layoutItemMinW': node.minWidth ?? undefined }; };