User Interface medium complexity frontend
1
Dependencies
0
Dependents
0
Entities
0
Integrations

Description

Client-side React component rendered as a banner or modal on first visit, collecting visitor cookie preferences before any non-essential scripts are loaded. Persists consent state in localStorage and provides granular category-level opt-in/opt-out controls.

Feature: Cookie Policy

cookie-consent-widget

Responsibilities

  • Display consent banner on first visit before non-essential scripts initialize
  • Allow granular category selection (necessary, analytics, marketing)
  • Persist consent preferences to localStorage
  • Provide accept-all, reject-all, and customize options
  • Re-display when visitor wants to change preferences

Interfaces

renderConsentBanner()
handleAcceptAll()
handleRejectAll()
handleCustomize(categories: ConsentCategories)
openPreferencesModal()
getConsentState(): ConsentState

Relationships

Dependencies (1)

Components this component depends on