Update Flexbox

This commit is contained in:
Sabine Lim
2023-05-16 02:23:28 +10:00
parent 36f87b3b8d
commit 7a6c9480f8

View File

@@ -76,6 +76,10 @@ return function(name, basalt)
return spacing
end,
getFlexDirection = function(self)
return flexDirection
end,
setFlexDirection = function(self, direction)
if direction == "row" or direction == "column" then
flexDirection = direction
@@ -84,6 +88,10 @@ return function(name, basalt)
return self
end,
getJustifyContent = function(self)
return justifyContent
end,
setJustifyContent = function(self, alignment)
if alignment == "flex-start" or alignment == "flex-end" or alignment == "center" or alignment == "space-between" or alignment == "space-around" then
justifyContent = alignment
@@ -92,6 +100,10 @@ return function(name, basalt)
return self
end,
getAlignItems = function(self)
return alignItems
end,
setAlignItems = function(self, alignment)
if alignment == "flex-start" or alignment == "flex-end" or alignment == "center" or alignment == "space-between" or alignment == "space-around" then
alignItems = alignment