Skip to content

Commit 77e8cff

Browse files
committed
Fix tabs.
1 parent 2a67100 commit 77e8cff

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

Sources/Layout/Layoutless.swift

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -362,25 +362,25 @@ extension LayoutProtocol where Node: UIView {
362362

363363
/// Stack an array of views in a stack view.
364364
public func stack(_ views: [AnyLayout], axis: NSLayoutConstraint.Axis, spacing: CGFloat = 0, distribution: UIStackView.Distribution = .fill, alignment: UIStackView.Alignment = .fill, configure: @escaping (UIStackView) -> Void = { _ in }) -> Layout<UIStackView> {
365-
return Layout { revertable in
366-
let stackView = UIStackView()
367-
stackView.axis = axis
368-
stackView.spacing = spacing
369-
stackView.distribution = distribution
370-
stackView.alignment = alignment
371-
views.forEach {
372-
revertable.append($0.layout(in: stackView))
373-
}
374-
configure(stackView)
375-
return stackView
376-
}
365+
return Layout { revertable in
366+
let stackView = UIStackView()
367+
stackView.axis = axis
368+
stackView.spacing = spacing
369+
stackView.distribution = distribution
370+
stackView.alignment = alignment
371+
views.forEach {
372+
revertable.append($0.layout(in: stackView))
373+
}
374+
configure(stackView)
375+
return stackView
376+
}
377377
}
378378

379379
/// Stack an array of views in a stack view.
380380
public func stack(_ axis: NSLayoutConstraint.Axis, spacing: CGFloat = 0, distribution: UIStackView.Distribution = .fill, alignment: UIStackView.Alignment = .fill, configure: @escaping (UIStackView) -> Void = { _ in }) -> ((AnyLayout...) -> Layout<UIStackView>) {
381-
return { (views: AnyLayout...) -> Layout<UIStackView> in
382-
return stack(views, axis: axis, spacing: spacing, distribution: distribution, alignment: alignment,configure: configure)
383-
}
381+
return { (views: AnyLayout...) -> Layout<UIStackView> in
382+
return stack(views, axis: axis, spacing: spacing, distribution: distribution, alignment: alignment, configure: configure)
383+
}
384384
}
385385

386386
// MARK: Grouping

0 commit comments

Comments
 (0)