Skip to main content

Why do ellipses on text elements behave unexpectedly?

Learn about known limitations with how Bubble truncates text and adds ellipses in Text elements, including differences between the editor and run mode.

Written by Sofia Maconi
Updated this week

When text overflows a Text element, Bubble truncates it and adds an ellipsis (…). This truncation is handled by a third-party library, which has some known limitations that can produce unexpected behavior in certain situations.

What you might notice

  • Truncation behaves differently between the editor and run mode — in run mode, text is cut at the word level; in the editor, it's cut at the character level

  • If a single word is too wide for the element, the entire word gets truncated rather than cut mid-word

  • URLs in a Text element are treated as a single word — if the URL is too long to fit, the entire URL may be hidden rather than trimmed

  • After a page expands (e.g. on a responsive layout), ellipses may remain even when there’s now enough space to show the full text

  • Text may briefly appear untruncated for a split second on page load before the ellipsis kicks in

Workaround

There's no workaround that fully addresses these behaviors, as they stem from how the underlying truncation library works. If precise text truncation is critical to your app, consider controlling text length in your data before it reaches the element — for example, using Bubble's ":truncated to" operator on the text expression to set a character limit manually.

Status

We're aware of these limitations and are evaluating options to fix or replace the truncation library. Because it's used across many elements, any change requires careful planning and testing, so we don't have a timeline yet.

Did this answer your question?