Skip to content

Working with calc() props for height/width #757

Answered by SiTaggart
alecnicolas asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @alecnicolas, working with heights is an interesting problem that Paste comes up against from time to time and I'm not sure we have the best answer yet.

On the one hand we're leaning towards allowing any height or width value, as it's pretty hard to predict what is useful for any given UI. Any value being any valid CSS for a height or width.

On the other, setting heights in particular can be a pretty problematic pattern we want folks to try and avoid if possible. The problem shows itself in a few scenarios all with the same unintended consequence. That consequence is that content might flow into new lines in certain situations, and if the container has a fixed height, the content will …

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@alecnicolas
Comment options

Answer selected by alecnicolas
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants