Перейти к содержимому

Компоненты

Text

Отображает текст заданного размера с выбранным семантическим тегом.

Использование

Базовый

A title

Design tokens keep every component on brand.

Supporting detail

HTML
<bs:bsui-stack direction="column" gap="2">
  <bs:bsui-text content="A title" variant="title" tag="h3" />
  <bs:bsui-text content="Design tokens keep every component on brand." variant="body" tag="p" />
  <bs:bsui-text content="Supporting detail" variant="muted" tag="p" />
</bs:bsui-stack>

Все варианты

Все восемь вариантов на одной метке — меняется только масштаб шрифта.

Heading Title Lead Body Label Muted Caption Code
HTML
<bs:bsui-stack direction="column" gap="2">
  <bs:bsui-text content="Heading" variant="heading" tag="span" />
  <bs:bsui-text content="Title" variant="title" tag="span" />
  <bs:bsui-text content="Lead" variant="lead" tag="span" />
  <bs:bsui-text content="Body" variant="body" tag="span" />
  <bs:bsui-text content="Label" variant="label" tag="span" />
  <bs:bsui-text content="Muted" variant="muted" tag="span" />
  <bs:bsui-text content="Caption" variant="caption" tag="span" />
  <bs:bsui-text content="Code" variant="code" tag="span" />
</bs:bsui-stack>

Тег и вариант

Тег задает уровень обводки, а вариант — размер; их выбирают отдельно.

Release notes

Version 7.4

Breaking changes

Blocks

HTML
<bs:bsui-stack direction="column" gap="2">
  <bs:bsui-text content="Release notes" variant="heading" tag="h2" />
  <bs:bsui-text content="Version 7.4" variant="title" tag="h3" />
  <bs:bsui-text content="Breaking changes" variant="label" tag="h4" />
  <bs:bsui-text content="Blocks" variant="caption" tag="h5" />
</bs:bsui-stack>

Атрибуты

АтрибутТипПо умолчанию
content richtext —
variant body label heading title caption muted code lead body
tag p span label h1 h2 h3 h4 div p