Skip to content

Text Component

The Text component displays text content in your views. It supports both static text and dynamic content through formulas, with markdown formatting for rich text display.

Use the Text component to:

  • Display headings and labels
  • Show dynamic data from your tables
  • Create rich formatted content with markdown
  • Add instructional text or descriptions
  1. Open the Layout tab in your app editor
  2. Drag the Text component from the palette onto your canvas
  3. Select the component to open the settings panel
  4. Configure the title, content, and styling options
SettingTypeDescription
TitleText/FormulaHeader text displayed above content
ContentText/FormulaBody text (supports markdown)
Title SizeDropdownh1, h2, h3, h4, h5, or h6
AlignmentDropdownleft, center, or right
Text ColorColor pickerText color
Background ColorColor pickerBackground color

For simple static content, enter text directly in the settings:

Title: Welcome
Content: This is your dashboard. Select an item from the list to get started.

Use formulas to display dynamic content:

Reference table fields using {{}} syntax:

Title: {{customers.name}}
Content: Email: {{customers.email}}

In a list context, use $row to reference the current record:

Title: {{$row.product_name}}
Content: Price: ${{$row.price}}

Display information about the current user:

Title: Welcome, {{$user.display_name}}!
Content: You last logged in on {{FORMAT_DATE($user.last_login, 'long')}}

Use IF() for conditional display:

Content: Status: {{IF($row.is_active, 'Active', 'Inactive')}}

Perform calculations in your content:

Content: Total: ${{$row.quantity * $row.unit_price}}

The content field supports markdown formatting for rich text:

# Heading 1
## Heading 2
### Heading 3
**Bold text**
*Italic text*
~~Strikethrough~~
`Inline code`
- Unordered item 1
- Unordered item 2
1. Ordered item 1
2. Ordered item 2
[Link text](https://example.com)
> This is a quoted block of text
```
function example() {
return "Hello World";
}
```
| Column 1 | Column 2 |
|----------|----------|
| Cell 1 | Cell 2 |
| Cell 3 | Cell 4 |

Mix markdown formatting with dynamic formulas:

## Order Summary
**Customer:** {{$row.customer_name}}
**Items:**
- Product: {{$row.product_name}}
- Quantity: {{$row.quantity}}
- Unit Price: ${{$row.unit_price}}
**Total:** ${{$row.quantity * $row.unit_price}}
---
*Order placed on {{FORMAT_DATE($row.created_at, 'long')}}*

Choose the appropriate heading level for your content hierarchy:

SizeHTML ElementUse Case
h1<h1>Page titles, main headings
h2<h2>Section headings
h3<h3>Subsection headings
h4<h4>Minor section headings
h5<h5>Small headings
h6<h6>Smallest headings

Control how text is positioned:

AlignmentDescription
leftAlign text to the left (default)
centerCenter text horizontally
rightAlign text to the right

Set a custom text color:

  • Use the color picker to select a color
  • Or enter a hex value: #1a1a1a
  • Supports formulas for dynamic colors:
    {{IF($row.is_urgent, '#dc2626', '#171717')}}

Add a background color for emphasis:

  • Use the color picker or hex value
  • Great for callout boxes and highlights
  • Supports dynamic colors with formulas

Control when the text component is visible:

Visibility Formula: {{$row.status = 'active'}}

The component only displays when the formula evaluates to true.

Title: Welcome back, {{$user.display_name}}!
Title Size: h2
Content: Here's an overview of your recent activity.
Alignment: left
Title: No items found
Title Size: h3
Content: Try adjusting your filters or create a new item to get started.
Alignment: center
Visibility: {{COUNT(items.*) = 0}}
Title: (empty)
Content: **Attention:** This record is pending review.
Background Color: #fef3c7
Visibility: {{$row.status = 'pending'}}
Title: Monthly Summary
Content:
**Total Orders:** {{COUNT(orders.*)}}
**Revenue:** ${{SUM(orders.total)}}
**Avg Order:** ${{AVG(orders.total)}}
Title: (empty)
Content:
> **Tip:** Click on any row to view details. Use the search bar to find specific items.
Title: Next Steps
Content: {{IF($row.status = 'draft',
'Fill in all required fields and click Submit.',
IF($row.status = 'pending',
'Your submission is being reviewed.',
'Your submission has been approved.'))}}
  • Use heading sizes consistently
  • Reserve h1 for page titles
  • Use h2-h4 for section headings
  • Keep paragraphs short
  • Use bullet points for lists
  • Add spacing between sections
  • Provide fallback values for empty fields:
    {{COALESCE($row.description, 'No description available')}}
  • Format numbers and dates for readability:
    ${{FORMAT_NUMBER($row.price, 2)}}
  • Use descriptive headings
  • Ensure sufficient color contrast
  • Don’t rely solely on color for meaning
  • Avoid complex calculations in heavily repeated text
  • Use simple formulas when possible
  • Cache computed values in table fields if needed
IssueCauseSolution
Blank contentInvalid formulaCheck formula syntax and field names
Markdown not renderingSpecial charactersEscape special characters properly
Wrong formattingMissing markdownAdd proper markdown syntax
Text cut offContainer too smallResize component or use scrolling
  1. Start with static text to verify the component works
  2. Add simple formulas: {{$row.name}}
  3. Build up complexity gradually
  4. Check browser console for errors

Explore more EmberBlocks features:

  • Formulas - Learn formula syntax and functions
  • Actions - Trigger operations from buttons
  • Views - Organize components in pages