• Start
  • Blogg
  • Kom igång
  • Riktlinjer
  • Komponenter
  • Changelog
  • Tillgänglighet
  • Statistik
  • Inställningar

Komponenter

Komponenter

​
​

Inga resultat hittade, prova med andra sökvillkor.

Text List

Text List

2.1.6

A description of this component is work in progress.

Demo
Props
Installation
Länkar
Tillgänglighet
Change log
Statistik

Demo

Props

Se fullständing dokumentation(öppnas i ny flik)
NamnTypBeskrivning

color

"inherit" | "black" | "green"

customAttribute

{ attribute: string; value: string | number }Used for tests. Clickable and requested subcomponents will be suffixed with "-[ComponentName]".

isLoading

booleanIf true, a loading skeleton will be rendered instead of the component.

variant

"number" | "bullet" | "check"Defines the style of adornment for the list item. This can also be set in the TextList component, which will override this setting. Note: When using the 'number' variant, ensure the list is rendered using <ol> for proper HTML semantics.

Installation

Kodexempel
npm install @sj-ab/component-library.ui.text-list

Länkar

  • Storybook

  • Figma

  • Bit.cloud

Tillgänglighet

Semantik

Text List presenteras som standard som en enkel oordnad lista: <ul>

Det är möjligt att göra om listan till en ordnad lista genom att använda variant="number". Gör detta om det är viktigt för användare med skärmläsare att förstå att listalternativen har en inbördes ordning.

Tillgängligt namn

En lista behöver vanligtvis inte ett eget tillgängligt namn. I vissa situationer kan det dock finnas anledning att förtydliga listans syfte med ett eget namn genom aria-label:

Kodexempel

Change log

  • Upgrade to React 19

    2.1.0

Statistik

  • Importer av Text List

    46
  • Repos med Text List

    34%
  • Senaste installerade version av Text List

    2.1.6
  • Äldsta installerade version av Text List

    2.1.6