I’m a little surprised at something: I want to put two short paragraphs of instructions on a page in my app and the text includes a word I want to bold and a short bullet list. I don’t see a “rich text” component among the options, which seems odd. The Label component doesn’t allow for rich text. How would I accomplish what I want to do here?
Hi mbritt,
Maybe some workaround will be WebViewer component with setting URL of it to HTML data representing what you want to see. Here is a little example of code for that:
data:text/html,
<!DOCTYPE html><html><meta name="viewport" content="initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,width=device-width, user-scalable=no" /><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"><body>
<p style="width:100%;">Here is the <strong>example</strong> text:
<li>point1
<li>point2
<li>point3
</p>
</body></html>
You can put this code in your application line by line (as I pasted it here) using the join text or on one line with text.
Later if you want to make changes to the HTML data, you can do so using for example with replace text. Below is example of blocks for that:
Thanks for verifying this. I put HTML text into the Label component as @hatmanactions suggested and it looks great on the laptop, but on my iphone it’s just a white block with nothing in it. Darn… Going to try his suggestion above using blocks.
Hmm. I do want to use static text and I’m looking at the YayText page, but I don’t see how this would address the issue. It seems to create all kinds of interesting/unique versions of your text, but not sure I need that. Maybe I don’t get what you’re suggesting.
This is super cool and I might use this! However this only works for same colour labels. However something like the below is currently not possible on thunkable.
This is super cool and I might use this! However this only works for same colour labels. Like if I wanted something like this Hello my name is zander"
In this demo you can paste any paragraph and then choose the normal color and the highlighted words’ color with the ability to choose the highlighted words from the paragraph.
@muneer You’re clearly pretty darn good at this, but your examples all require the user to press a button to see the highlighted text. Is there any way you can think of where the text just appears on the page with the highlights pre-determine?
As a proof of concept, I have modified the Make Bold project to include an Input_text component that you can type and will see the result in the label below. I have chosen the <b> to start the bold letters and then another <b> to go back to normal letters.