Skip to main content

List
New

Lists are used to display name/value pairs such as terms and definitions. Particularly useful for glossaries.

Examples

Open in new window
<duet-list variation="striped">
<duet-list-item>
<span slot="label">Nimi</span>
<span slot="value">Lasse Mäkinen</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Osoite</span>
<span slot="value">Kotikatu 23 A 4, 00220 Helsinki, Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Puhelin</span>
<span slot="value">+358 400 123 456</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Email</span>
<span slot="value">lasse.makinen@test.com</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Kieli</span>
<span slot="value">Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Alueyhtiö</span>
<span slot="value">Lähitapiola Keskinäinen Vakuutusyhtiö</span>
</duet-list-item>
</duet-list>
Open in new window
<duet-list>
<duet-list-item>
<span slot="label">Nimi</span>
<span slot="value">Lasse Mäkinen</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Osoite</span>
<span slot="value">Kotikatu 23 A 4, 00220 Helsinki, Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Puhelin</span>
<span slot="value">+358 400 123 456</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Email</span>
<span slot="value">lasse.makinen@test.com</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Kieli</span>
<span slot="value">Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Alueyhtiö</span>
<span slot="value">Lähitapiola Keskinäinen Vakuutusyhtiö</span>
</duet-list-item>
</duet-list>
Open in new window
<duet-list label-width="30" variation="striped">
<duet-list-item>
<span slot="label">Nimi</span>
<span slot="value">Lasse Mäkinen</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Osoite</span>
<span slot="value">Kotikatu 23 A 4, 00220 Helsinki, Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Puhelin</span>
<span slot="value">+358 400 123 456</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Email</span>
<span slot="value">lasse.makinen@test.com</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Kieli</span>
<span slot="value">Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Alueyhtiö</span>
<span slot="value">Lähitapiola Keskinäinen Vakuutusyhtiö</span>
</duet-list-item>
</duet-list>

<duet-list label-width="50" variation="striped">
<duet-list-item>
<span slot="label">Nimi</span>
<span slot="value">Lasse Mäkinen</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Osoite</span>
<span slot="value">Kotikatu 23 A 4, 00220 Helsinki, Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Puhelin</span>
<span slot="value">+358 400 123 456</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Email</span>
<span slot="value">lasse.makinen@test.com</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Kieli</span>
<span slot="value">Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Alueyhtiö</span>
<span slot="value">Lähitapiola Keskinäinen Vakuutusyhtiö</span>
</duet-list-item>
</duet-list>

<duet-list label-width="70" variation="striped">
<duet-list-item>
<span slot="label">Nimi</span>
<span slot="value">Lasse Mäkinen</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Osoite</span>
<span slot="value">Kotikatu 23 A 4, 00220 Helsinki, Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Puhelin</span>
<span slot="value">+358 400 123 456</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Email</span>
<span slot="value">lasse.makinen@test.com</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Kieli</span>
<span slot="value">Suomi</span>
</duet-list-item>
<duet-list-item>
<span slot="label">Alueyhtiö</span>
<span slot="value">Lähitapiola Keskinäinen Vakuutusyhtiö</span>
</duet-list-item>
</duet-list>

Properties #

Property Attribute Description Type Default
labelWidth label-width Set the column width of the first column in percentages. "30" or "50" or "70" "30"
margin margin Controls the margin of the component. "auto" or "none" "auto"
theme theme Theme of the list. "" or "default" or "turva" ""
variation variation Style variation of the list. "default" or "striped" "default"

Integration

For integration, event and theming guidelines, please see Using Components. This documentation explains how to implement and use Duet’s components across different technologies like Angular, React or Vanilla JavaScript.



Tutorials

Follow these practical tutorials to learn how to build simple page layouts using Duet’s CSS Framework, Web Components and other features:

Tutorials

Building Layouts

Tutorials

Using CLI Tools

Tutorials

Creating Custom Patterns

Tutorials

Server Side Rendering

Tutorials

Sharing Prototypes


Troubleshooting

If you experience any issues while using a component, please head over to the Support page for more guidelines and help.