Bricking is Inspired by Stevia. The function is similar to Stevia. But supports the following features.
github "cp3hnu/Bricking"
/usr/local/bin/carthage copy-frameworks
File -> Swift Packages -> Add Package Dependency, then search bricking.
asv(
portraitImgView,
idLabel,
dateLabel
)
layout(
15,
|-15-portraitImgView.size(30)-idLabel-15-|,
10,
|-15-dateLabel-15-|,
15
)
let views = [Any](https://raw.github.com/cp3hnu/Bricking/master/)
if isTrue {
views += [view1, view2]
} else {
views += [view3, view4]
}
asv(views)
layoutDynamically(views)
view.layout(
topLayoutGuide.bottomAnchor,
10,
|subview1| ~ 50,
10,
|subview2|,
bottomLayoutGuide.topmAnchor
)
view.layout(
view.safeAreaLayoutGuide.topAnchor,
10,
|subview1| ~ 50,
10,
|subview2|,
view.safeAreaLayoutGuide.bottomAnchor
)
label1-(>=4)-Bricking.centerX-(>=4)-label2
layout(
|-15-label1-15-|,
10,
Bricking.centerY,
10,
|-15-label2-15-|
)
layout(
64,
|nameView|,
|cityView|,
20,
|-15-button-15-| ~ 40
)
cityView.shrinkVertically = true
is equal to
cityView.isHidden = true
layout(
64,
|nameView|,
20,
|-15-button-15-| ~ 40
)
label.laTop == 100
label2.laLeft == label1.laLeft + 20
label1.laWidth <= 50 % label2.laWidth
label.laBottom == 15 !! UILayoutPriorityRequired - 1
label.width(40%)
tableView.fillContainer()
button.centerInContainer()
alignLefts(label1, label2)
[label1, label2].alignLefts().alignTops()
...
Released under the MIT license. See LICENSE for details.
link |
Stars: 3 |
Last commit: 2 years ago |
Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics