Skip to content

Commit d49e697

Browse files
committed
feat: support contents display mode
1 parent df664bf commit d49e697

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

Sources/Swift/FlexLayout.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1466,6 +1466,10 @@ public final class Flex {
14661466
case flex
14671467
/// With this value, the item will be hidden and not be calculated
14681468
case none
1469+
/// With this value, the node is removed from the layout flow, while its children are preserved and hoisted.
1470+
/// This allows higher-level UI frameworks to compose wrapper components (e.g., to handle events)
1471+
/// without influencing the layout of child nodes.
1472+
case contents
14691473
}
14701474

14711475
/*public enum Overflow {

Sources/Swift/Impl/FlexLayout+Enum.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,7 @@ extension Flex.Display {
114114
switch self {
115115
case .flex: return YGDisplay.flex
116116
case .none: return YGDisplay.none
117+
case .contents: return YGDisplay.contents
117118
}
118119
}
119120
}

0 commit comments

Comments
 (0)