Language Selector (language_selector
)
The consistent placement, interface, and behavior of the language selection component allows users to easily find and access content in the language the user is most comfortable in.
🔗 External documentation.
ID | Label | Description | Schema |
---|---|---|---|
language_label | Language label | Label for the button |
|
items | Language buttons |
|
id: language_selector
label: 'Language Selector'
description: 'The consistent placement, interface, and behavior of the language selection component allows users to easily find and access content in the language the user is most comfortable in.'
group: Language
homepage: 'https://designsystem.digital.gov/components/language-selector/'
props:
language_label:
id: language_label
label: 'Language label'
description: 'Label for the button'
schema:
type: string
items:
id: items
label: 'Language buttons'
schema:
type: array
items:
type: object
properties:
title:
type: string
attributes:
$ref: '#/$defs/attributes_value'
below:
type: object
examples:
preview:
id: preview
label: Preview
renderable:
'@component': language_selector
language_label: 'Test language selector'
items:
-
label: English
url: /
attributes:
lang: en
-
label: Spanish
url: /es
attributes:
lang: es
-
label: French
url: /fr
attributes:
lang: fr