brickkit-ios icon indicating copy to clipboard operation
brickkit-ios copied to clipboard

Brick height depending of the View height

Open Stanou01260 opened this issue 7 years ago • 0 comments

I saw in the readme that there are 3 different ways to define height.

// Calculate height using auto-layout
LabelBrick(height: .auto(estimate: .fixed(size: 50)), text: "BRICK"),

// Fixed Height
LabelBrick(height: .fixed(size: 50), text: "BRICK"),

// Calculate height based on ratio of the width
LabelBrick(height: .ratio(ratio: 1), text: "BRICK")

However I did not see a way to set the height depending on the superView height (like there is for the width). For instance, if I want to have cells being a third of the height, I do not know how to proceed : I can update the section in viewWillTransitionTo() but I would like not to use this ugly solution

Stanou01260 avatar Jan 10 '18 14:01 Stanou01260