Docs

Documentation versions (currently viewingVaadin 25 (prerelease))

Details Styling

Styling API reference for the Details component.

Style Variants

The following style variants are supported by Details:

Variant Description Supported by

filled

Makes the component’s boundaries visible

Aura, Lumo

no-padding

Removes the padding from the content area

Aura

small

Used for compact UIs

Lumo

reverse

Places the toggle icon after the summary contents

Aura, Lumo

Filled

The filled variant makes the component’s boundaries visible, which helps tie its content together visually and distinguishes it from the surrounding UI.

Source code
DetailsFilled.java
details-filled.tsx
details-filled.ts

Small

Use the small variant for compact UIs.

Source code
DetailsSmall.java
details-small.tsx
details-small.ts

Reverse

The reverse variant places the toggle icon after the summary contents, which can be useful for visually aligning the summary with other content.

Source code
DetailsReverse.java
details-reverse.tsx
details-reverse.ts

Style Properties

The following style properties can be used in CSS stylesheets to customize the appearance of this component.

To apply values to these properties globally in your application UI, place them in a CSS block using the html {…​} selector. See Component Style Properties for more information on style properties.

Property Supported by

--vaadin-details-summary-background

Aura

--vaadin-details-summary-border-color

Aura

--vaadin-details-summary-border-radius

Aura

--vaadin-details-summary-border-width

Aura

--vaadin-details-summary-font-size

Aura

--vaadin-details-summary-font-weight

Aura

--vaadin-details-summary-gap

Aura

--vaadin-details-summary-height

Aura

--vaadin-details-summary-padding

Aura

--vaadin-details-summary-text-color

Aura

CSS Selectors

The following CSS selectors can be used in stylesheets to target the various parts and states of the component. See the Styling documentation for more details on how to style components.

Root element

vaadin-details

States

Opened panel

vaadin-details[opened]

Disabled panel

vaadin-details[disabled]

Summary

Panel header (a.k.a. summary)

vaadin-details-summary

Toggle

vaadin-details-summary::part(toggle)

Toggle icon

vaadin-details-summary::part(toggle)::before

Summary content wrapper

vaadin-details-summary::part(content)

Opened details summary

vaadin-details-summary[opened]

Disabled details summary

vaadin-details-summary[disabled]

Content

Collapsible content wrapper

vaadin-details::part(content)