fix div w-full

This commit is contained in:
Face
2025-09-09 17:47:48 +03:00
parent 5e353398df
commit 55db8438bb

View File

@@ -68,6 +68,11 @@ static func apply_element_styles(node: Control, element: HTMLParser.HTMLElement,
if width == "100%": if width == "100%":
node.size_flags_horizontal = Control.SIZE_EXPAND_FILL node.size_flags_horizontal = Control.SIZE_EXPAND_FILL
node.custom_minimum_size.x = 0 node.custom_minimum_size.x = 0
if node is PanelContainer and node.get_child_count() > 0:
var vbox = node.get_child(0)
if vbox is VBoxContainer:
vbox.size_flags_horizontal = Control.SIZE_EXPAND_FILL
node.set_meta("size_flags_set_by_style_manager", true)
else: else:
# For other percentages, convert to viewport-relative size # For other percentages, convert to viewport-relative size
var percent = float(width.replace("%", "")) / 100.0 var percent = float(width.replace("%", "")) / 100.0