Simplest read more solution

I don’t know if all of you are aware of this trick. I wasn’t.
In one of my templates I’ve teaser card elements. Initial a card should only display a short text and a read more button. A click on the button should display the whole text.
Solution:
Set a state “truncated” (yes/no - default value “yes”) to the text element.
Set a conditon: if truncated is yes → max-heigth 120px min height 120px
(the height depends on your font size. So you have to adjust this to your needs)

Add a workflow to the “Read more” button. On click set the truncated state of the text element to no.

That’s all.

1 Like

I forgot to mention a second condition for the text element.
Truncated is no → min-height: e.g. 360px - max-height: infinite

1 Like