Is there a particular reason why we can’t have a true center text vertically as an option?
I find myself using flexbox for text elements, but it seems like such a simple thing to have as default in the editor? But maybe it really messes with something if it were an option?
Anyway, to the powers that be, it sure would make things a lot simpler
Haha no sorry, I guess my post wasn’t very clear at all.
Yes, there is an option “center the text vertically”. However, that option doesn’t actually center the text inside the text element vertically. It will only center the first line vertically. So if you have more than one line of text, you can’t actually center it properly without CSS. (as far as I can tell)
Placing it inside a group and center inside is an option that can get you close, but it won’t work for dynamic text where the text element’s height will expand if you end up with 3 lines instead of 2 for example.
Yeah that’s another work around that can work for some cases. Sure would be nice to have a proper center vertically, that worked for all cases with the click of a button
Then change the element height to be the font size + 1/2 the font size - So 16 with 1.5 spacing would be 24 and the text will be perfectly centered in the element
The problem with that solution is that it breaks as soon as you use dynamic data with varying number of characters.
For a group to not expand if a text element inside it is not tall enough (in bubble speak) the text element has to already be the maximum height required for any length of text (to give it room to expand inside it’s own element) or be allowed to “cut off content”
Having the ability to center inside its own element is the functionality needed for that to work. And that piece is what’s currently missing in bubble.
group 1. - Set up as your example, works great with known # of characters.
group 2. - Set up as your example, but with more characters, expanding the element
group 3. - Text element using the same size as the parent group, No longer expanding the element, but text is no longer vertically centred within the group.
Not sure Team Bubble can get to this without it breaking a lot of legacy formatting, but if they can set it up to work this way for just new text elements then I’m also 100% behind this.
We use a lot of buttons disguised as text for this reason, but that doesn’t work out when you have a wide variance of potential outcomes in text length (buttons don’t expand with text) or if you want to use any of the other bells and whistles of text formatting.
If this could be added in one of the monthly hacks that would be helpful - even more so if teamed with proper vertical centering for elements within elements (e.g., a button or text element floating vertically in the center of a group that can change size based on it’s contents).
I agree, this is a big problem with my application. I have having to re-create my designs because it is very difficult to center text verically (like, actually center it).