Forum Academy Marketplace Showcase Pricing Features

Dumb Formatting Question

I feel like this is a dumb question because it’s probably an easy solve but I can’t seem to find it through search.

I have a text section that displays the notification
image

I need this to be centered vertically when it’s one line, but also centered vertically when it’s two lines of data (centered in the middle with the blue circle). I’ve already set the text to center vertically in the check box-

However, as you can see, the second row (“nickle”) doesn’t shift so it aligns with the blue circle.

image

Any tips? Thanks

1 Like

Actually not a dumb question, no perfect fix to this since there’s no telling how long the text can be (think 3 or 4 rows)

Only suggestion I have is:

Bring the top of the box up and position so it’s as if you had 2 lines of text. This will be the default. Do not vertically center text.

Count out an aprox number of characters until it wraps from 1 line to 2.

Set a conditional for current cells body:number of characters < (aprox line wrap count)

Vertically center if condition is met. (Meaning it’s only 1 row of text)

You can also set a second conditional for the expected number of characters to wrap from 2 lines to 3 and truncated to (aprox char count) to prevent it stretching to 3 lines

Hey @fernando7 :wave:

Definitely not a dumb question.

There might be an easier way. There is always multiple ways to solve one problem. Just thought I would throw this option to the mix.

Maybe try putting the text height all the way from the top to the bottom and then add a little bit of code to the page like this example.

Editor: 805testapp42 | Bubble Editor

Preview: Your Bubble app

Just cut off text if it’s too high so it doesn’t look weird after 4 or 5 lines maybe. :man_shrugging:t2:

Hope that helps! :blush:

@j805 www.NoCodeMinute.com

For All Your No-Code Education Needs:

1 Like

Love this approach

1 Like

Thank you for your input! Will give these options a try.

1 Like