• Meet OMA at Smart City Expo World Congress • Barcelona • 3–5 November 2026 • Hall 3, Street F, Stand 90 •
• Live LwM2M demos • Water 2.0 panel • Smart City SIG sessions •

💧 OMA Utilities WG • Water 2.0 has launched • Utility Membership •

🏙️ OMA Conformance Tool • Apply for Early Access •


Segment

Usage

The ShSegment component is the most flexible component. It encapsulates one block or container of Markdown and HTML content that can be styled, and it can take any value and represent it.

Basic

This is and example of how a basic ShSegment component is displayed:

This is a specific block of Markdown content that can be styled.

This is a HTML anchor (a)

::ShSegment
---
ui:
  wrapper: bg-cyan-300 dark:bg-cyan-800 rounded-xl border shadow-md p-4 # Comment
---

This is a specific block of *Markdown* content that can be styled.

This is a HTML <a href="https://www.w3schools.com/tags/tag_a.asp" target="_blank">anchor (a)</a>

::

The content can be markdown or HTML text of any length. All elements are supported as in the normal text.

Advanced settings

This is how a complex example of the ShSegment is displayed. When hovering over the content is zoom in/out and contains different type of content:

  • Markdown content
  • HTML Table
  • An embedded ShSegment that contains an image.

Content inside of the ShSegment can be of any length or structure.

It can have any general Markdown formatting structure: lists, order lists, or tables.

  • item
  • item
  • and one more item
  1. First element
  2. Second element
  3. third element

This is a table written in HTML:

Row 1, Col 1 Row 1, Col 2
Row 2, Col 1 Row 2, Col 2

It can also include other components. For example another ShSegment.

This is a nested segment with its own specific styling and an image.

image

That is making this used to show this component flexibility.

::ShSegment
---
ui:
  wrapper: bg-gradient-to-r from-blue-500 text-3xl p-4 m-12 rounded-xl shadow-2xl transition duration-300 ease-in-out hover:scale-110 # Comment
---

Content inside of the `ShSegment` can be of any length or structure.

It can have any general *Markdown* formatting structure: lists, order lists, or 
tables.

* item
* item
* and one more item

1. First element 
1. Second element
1. third element

This is a table written in HTML:
<table border="2">
  <tr>
    <td>Row 1, Col 1</td>
    <td>Row 1, Col 2</td>
  </tr>
  <tr>
    <td>Row 2, Col 1</td>
    <td>Row 2, Col 2</td>
  </tr>
</table>

It can also include other components. For example another `ShSegment`.

:::ShSegment
---
ui:
  wrapper: bg-gradient-to-r from-blue-500 text-3xl p-4 rounded shadow-2xl
---
This is a nested segment with its own specific styling and an image.

![image](https://assets-global.website-files.com/5e19ea5aa7d3a217492e372b/624de949df5a11680ab170b9_Axios%20logo%20-%20RGB%20-%20minimum%20space.png)

That is making this used to show this component flexibility.
:::

::

Props

PropTypeDefaultDescription
uiRecord<string, any>–Overrides the default classes of the UI config below. Values are merged with the defaults using tailwind-merge.
imageBackgroundstring–Sets a background image on the segment via inline CSS `background`.
imageBackgroundClassstring–Optional. Additional inline style applied alongside `imageBackground`, e.g. to control background size or position.
descriptionstring""Note for content writers. It is not rendered on the website.

Slots

  • default

UI config

Default classes of every styled element. Override any key through the ui prop.

KeyDefault classesDescription
wrapper""Defines the overall styling for the container that holds all the elements inside of the `ShSegment`. The attribute `shadow-xl` is used to provide a shadow effect around the wrapper.
inner""Inner container that holds the segment content.

FAQs

Q: There are no props inside of the front-matter in this constructor. Why does this constructor needs to work differently and how it works?

Since this constructor for its content has only one input (and that input could be anything), we opted out for slot element, which allows it to have a placeholder for anything that we want to populate with, including text with full MD support. Because of that, of that flexibility, this constructor`s use is a little bit different (no props at all). To use it, you would simply start adding text/link/img or whatever is you wish inside of --- divider.