-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make
TableListLayout
respect padding by default
Previously while you could set padding on the `TableListLayout`, that padding would be equally distributed to the left and right rather than respecting any difference between the two. Even if a custom width was set on the section or items, if the center alignment was used the resulting attributes would be globally centered versus centered in the available width between the padding. This change resolves the issue on two fronts. First, the `CustomWidth.Alignment.center` now center aligns between the provided padding. Second, because the `CustomWidth.default` will center align completely ignoring padding, this change introduces a root `CustomWidth` during the layout which all other components merge against to calculate their origin. This allows the correct center alignment with respect to padding to cascade down throughout the attributes until a component overrides the width with something else.
- Loading branch information
Showing
5 changed files
with
87 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file modified
BIN
+110 Bytes
(100%)
...tLayoutTests.swift/All/test_layout_vertical()/Images/200.0 x 700.0.snapshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters