Zur Navigation Zum Inhalt Kontakt Menu Trova un componente Descrizione generale Lyne Principi Base Accessibilité Sistema di design Guidelines Deutsch Français Italiano English I nostri principi di design Soluzioni focalizzate sull’utente Riconoscibilità Inclusione Riduzione Olistico Autoesplicativo Orientamento all’attività Adeguatezza Portale della marca FFS Logo Orologio digitale Diritti di utilizzazione Colori die base Colori funzionali Colori Off Brand Icone Icone dell'orario Pittogrammi Informazioni sull’accessibilità Über diesen Guide Contatti Letture consigliate Product Owner User Research Interaction Design Visual Design Development Content Design Testing What is a design system? Designing Coding FAQ Aiuto Processo Contribution Contatto Introduzione Base Componenti Introduzione Base Componenti Introduzione Base Componenti Introduzione Design Tokens Componenti Introduzione Base Informazioni Senso & scopo Community Assets Istruzioni Power-Apps Banner pubblicitari digitali SAP Icone delle app
Trova un componente

Lyne

Basics Animation

Animation

Border

Border

Grid

Grid

Spacings

Spacings

Typografie

Typografie

Components Action-Group

Action-Group

Alert

Alert

Alert-Group

Alert-Group

Autocomplete

Autocomplete

Button

Button

Calendar

Calendar

Card

Card

Card-Badge

Card-Badge

Checkbox

Checkbox

Checkbox-Group

Checkbox-Group

Chip

Chip

Clock

Clock

Datepicker

Datepicker

Dialog

Dialog

Divider

Divider

Footer

Footer

Form-Error

Form-Error

Form-Field

Form-Field

Header

Header

Header-Action

Header-Action

Icon

Icon

Image

Image

Journey-Header

Journey-Header

Link

Link

Link-List

Link-List

Logo

Logo

Menu

Menu

Menu-Action

Menu-Action

Radio-Button

Radio-Button

Radio-Button-Group

Radio-Button-Group

Selection-Panel

Selection-Panel

Signet

Signet

Slider

Slider

Tab-Group

Tab-Group

Tab Title

Tab Title

Tag

Tag

Tag-Group

Tag-Group

Teaser

Teaser

Teaser-Hero

Teaser-Hero

Time-Input

Time-Input

Title

Title

Toggle

Toggle

Toggle-Check

Toggle-Check

Tooltip

Tooltip

Tooltip-Trigger

Tooltip-Trigger

Questa pagina non è disponibile nella lingua desiderata. Lingue disponibili: Deutsch English

Checkbox-Group Implementation

The <sbb-checkbox-group> component is used as a container for one or multiple <sbb-checkbox> components,
which are projected inside an unnamed slot.

The orientation property is used to set items orientation. Possible values are horizontal (default) and vertical.
The optional property horizontalFrom can be used in combination with orientation='vertical' to
indicate the minimum breakpoint from which the orientation changes to horizontal.

It is possible to mark the entire group as disabled or required using the properties disabled and required.

The component can display one or more <sbb-form-error> components right below the <sbb-checkbox-group> using the error slot.

Usage

Basic usage:

<sbb-checkbox-group>
<sbb-checkbox value="checkbox-1">Label 1</sbb-checkbox>
<sbb-checkbox value="checkbox-2">Label 2</sbb-checkbox>
<sbb-checkbox value="checkbox-3">Label 3</sbb-checkbox>
</sbb-checkbox-group>

Required sbb-checkbox-group with error message:

<!-- All the child checkboxes will be marked as required-->
<sbb-checkbox-group required>
<sbb-checkbox value="checkbox-1">Label 1</sbb-checkbox>
<sbb-checkbox value="checkbox-2">Label 2</sbb-checkbox>
<sbb-checkbox value="checkbox-3">Label 3</sbb-checkbox>
<sbb-form-error slot="error">You must accept all the terms and conditions.</sbb-form-error>
</sbb-checkbox-group>

Disabled sbb-checkbox-group with vertical orientation below large breakpoint and horizontal above:

<!-- All the child checkboxes will be disabled-->
<sbb-checkbox-group disabled orientation="vertical" horizontal-from="large">
<sbb-checkbox value="checkbox-1">Label 1</sbb-checkbox>
<sbb-checkbox value="checkbox-2">Label 2</sbb-checkbox>
<sbb-checkbox value="checkbox-3">Label 3</sbb-checkbox>
</sbb-checkbox-group>

Properties

Property Attribute Description Type Default
disabled disabled Whether the checkbox group is disabled. boolean false
horizontalFrom horizontal-from Overrides the behaviour of orientation property. "large" | "medium" | "micro" | "small" | "ultra" | "wide" | "zero" undefined
orientation orientation Indicates the orientation of the checkboxes inside the <sbb-checkbox-group>. "horizontal" | "vertical" 'horizontal'
required required Whether the checkbox group is required. boolean false
size size Size variant, either m or s. "m" | "s" 'm'

Slots

Slot Description
"error" Slot used to render the inside the .
"unnamed" Slot used to render the inside the .

Demo
Label 1Label 2Label 3
Vertikal Horizontal
S M
Am Anfang Am Ende
White Milk Iron Charcoal Black
Mehr Beispiele auf Storybook
Impressum Contatto Impostazioni dei cookie