Design systém gov.cz4.7.0

gov-cookiebar

Properties

PropertyAttributeDescriptionTypeDefault
accessibleBadgeLabelaccessible-badge-labelAria label of the floating badge button.string'Otevřít nastavení cookies'
accessibleCloseLabelaccessible-close-labelAccessible label of the settings modal close button.string'Zavřít podrobné nastavení'
accessibleLabelaccessible-labelAria label of the cookie bar dialog.string'Nastavení souhlasu s cookies'
badgebadgeRenders a floating badge to reopen the bar after a choice was saved.booleantrue
categoriescategoriesCookie categories configuration. Accepts an array or a JSON string.CookieCategory[] | stringundefined
cookieNamecookie-nameName of the cookie holding the consent.string'gov-cookiebar-consent'
expirationexpirationConsent validity in days.number365
labelAcceptlabel-acceptText of the accept-all button.string'Souhlasím se všemi'
labelAlwaysOnlabel-always-onLabel of the chip marking always-on (required) categories.string'Vždy zapnuto'
labelCookieDetailslabel-cookie-details[DEPRECATED] No-op since the redesign — the per-cookie table was replaced by the label-privacy / privacy-url link. Kept for backward compatibility.

Label of the collapsible cookie declaration inside a category.
string'Seznam cookies'
labelCookieExpirationlabel-cookie-expiration[DEPRECATED] No-op since the redesign — the per-cookie table was removed. Kept for backward compatibility.

Header of the cookie expiration column in the declaration table.
string'Platnost'
labelCookieNamelabel-cookie-name[DEPRECATED] No-op since the redesign — the per-cookie table was removed. Kept for backward compatibility.

Header of the cookie name column in the declaration table.
string'Název'
labelCookieProviderlabel-cookie-provider[DEPRECATED] No-op since the redesign — the per-cookie table was removed. Kept for backward compatibility.

Header of the cookie provider column in the declaration table.
string'Poskytovatel'
labelCookiePurposelabel-cookie-purpose[DEPRECATED] No-op since the redesign — the per-cookie table was removed. Kept for backward compatibility.

Header of the cookie purpose column in the declaration table.
string'Účel'
labelPrivacylabel-privacyText of the privacy-policy link inside the settings modal.string'Zpracování osobních údajů a cookies'
labelRejectlabel-rejectText of the reject button.string'Odmítnout všechny'
labelSavelabel-saveText of the save button inside the settings modal.string'Uložit nastavení'
labelSettingslabel-settingsText of the settings button. The button renders only when categories are provided.string'Podrobné nastavení'
labelSettingsTitlelabel-settings-titleTitle of the detailed settings modal.string'Podrobné nastavení cookies'
privacyUrlprivacy-urlURL of the privacy-policy link inside the settings modal. Supplied by the application. The link renders only when a non-empty URL is provided.string''

Events

EventDescriptionType
gov-consentEmitted when the user saves a consent choice.CustomEvent<CookiebarConsentEvent>

Methods

getConsent() => Promise<CookiebarConsent | null>

Returns the stored consent or null when no valid consent exists.

Returns

Type: Promise<CookiebarConsent>

show() => Promise<void>

Reopens the bar; opens directly the settings panel when categories are configured.

Returns

Type: Promise<void>

Dependencies

Depends on

Graph


Built with StencilJS