Calendar heatmap
One cell a day over a year, weeks in columns, in one sequential hue: streaks, rhythms and gaps at a glance.
Web uniquement — React, depuis @krizaka/charts/heatmap. Bêta : son API peut encore changer à une version mineure.
Quand l’utiliser
- A daily habit or activity over months: publications, contributions, active days.
Quand ne pas l’utiliser
- Two categorical dimensions (weekday × hour).À la place : Heatmap
- A trend over time.À la place : Line chart
Installation
Installer
npm install @krizaka/chartsImporter
import { CalendarHeatmap } from "@krizaka/charts/heatmap";Exemples
A year of publishing
A creator's videos published per day over a year.
Videos published, last 12 months
Calendar heatmap, Oct 10, 2025 – Oct 9, 2026. Total 307, peak 3 (Oct 17, 2025), 164 with a value.
| Category | Videos |
|---|---|
| Oct 12, 2025 | 1 |
| Oct 13, 2025 | 2 |
| Oct 15, 2025 | 1 |
| Oct 17, 2025 | 3 |
| Oct 20, 2025 | 3 |
| Oct 21, 2025 | 1 |
| Oct 22, 2025 | 2 |
| Oct 24, 2025 | 1 |
| Oct 27, 2025 | 1 |
| Oct 29, 2025 | 3 |
| Oct 30, 2025 | 1 |
| Oct 31, 2025 | 2 |
| Nov 3, 2025 | 2 |
| Nov 5, 2025 | 1 |
| Nov 7, 2025 | 3 |
| Nov 8, 2025 | 1 |
| Nov 10, 2025 | 3 |
| Nov 12, 2025 | 2 |
| Nov 14, 2025 | 1 |
| Nov 17, 2025 | 1 |
| Nov 19, 2025 | 3 |
| Nov 21, 2025 | 2 |
| Nov 24, 2025 | 2 |
| Nov 26, 2025 | 1 |
| Nov 28, 2025 | 3 |
| Dec 1, 2025 | 3 |
| Dec 3, 2025 | 2 |
| Dec 5, 2025 | 1 |
| Dec 8, 2025 | 1 |
| Dec 10, 2025 | 3 |
| Dec 12, 2025 | 2 |
| Dec 14, 2025 | 1 |
| Dec 15, 2025 | 2 |
| Dec 17, 2025 | 1 |
| Dec 19, 2025 | 3 |
| Dec 22, 2025 | 3 |
| Dec 23, 2025 | 1 |
| Dec 24, 2025 | 2 |
| Dec 26, 2025 | 1 |
| Dec 29, 2025 | 1 |
| Dec 31, 2025 | 3 |
| Jan 1, 2026 | 1 |
| Jan 2, 2026 | 2 |
| Jan 5, 2026 | 2 |
| Jan 7, 2026 | 1 |
| Jan 9, 2026 | 3 |
| Jan 10, 2026 | 1 |
| Jan 12, 2026 | 3 |
| Jan 14, 2026 | 2 |
| Jan 16, 2026 | 1 |
| Jan 19, 2026 | 1 |
| Jan 21, 2026 | 3 |
| Jan 23, 2026 | 2 |
| Jan 26, 2026 | 2 |
| Jan 28, 2026 | 1 |
| Jan 30, 2026 | 3 |
| Feb 2, 2026 | 3 |
| Feb 4, 2026 | 2 |
| Feb 6, 2026 | 1 |
| Feb 9, 2026 | 1 |
| Feb 11, 2026 | 3 |
| Feb 13, 2026 | 2 |
| Feb 15, 2026 | 1 |
| Feb 16, 2026 | 2 |
| Feb 18, 2026 | 1 |
| Feb 20, 2026 | 3 |
| Feb 23, 2026 | 3 |
| Feb 24, 2026 | 1 |
| Feb 25, 2026 | 2 |
| Feb 27, 2026 | 1 |
| Mar 2, 2026 | 1 |
| Mar 4, 2026 | 3 |
| Mar 5, 2026 | 1 |
| Mar 6, 2026 | 2 |
| Mar 9, 2026 | 2 |
| Mar 11, 2026 | 1 |
| Mar 13, 2026 | 3 |
| Mar 14, 2026 | 1 |
| Mar 16, 2026 | 3 |
| Mar 18, 2026 | 2 |
| Mar 20, 2026 | 1 |
| Mar 23, 2026 | 1 |
| Mar 25, 2026 | 3 |
| Mar 27, 2026 | 2 |
| Mar 30, 2026 | 2 |
| Apr 1, 2026 | 1 |
| Apr 3, 2026 | 3 |
| Apr 6, 2026 | 3 |
| Apr 8, 2026 | 2 |
| Apr 10, 2026 | 1 |
| Apr 13, 2026 | 1 |
| Apr 15, 2026 | 3 |
| Apr 17, 2026 | 2 |
| Apr 19, 2026 | 1 |
| Apr 20, 2026 | 2 |
| Apr 22, 2026 | 1 |
| Apr 24, 2026 | 3 |
| Apr 27, 2026 | 3 |
| Apr 28, 2026 | 1 |
| Apr 29, 2026 | 2 |
| May 1, 2026 | 1 |
| May 4, 2026 | 1 |
| May 6, 2026 | 3 |
| May 7, 2026 | 1 |
| May 8, 2026 | 2 |
| May 11, 2026 | 2 |
| May 13, 2026 | 1 |
| May 15, 2026 | 3 |
| May 16, 2026 | 1 |
| May 18, 2026 | 3 |
| May 20, 2026 | 2 |
| May 22, 2026 | 1 |
| May 25, 2026 | 1 |
| May 27, 2026 | 3 |
| May 29, 2026 | 2 |
| Jun 1, 2026 | 2 |
| Jun 3, 2026 | 1 |
| Jun 5, 2026 | 3 |
| Jun 8, 2026 | 3 |
| Jun 10, 2026 | 2 |
| Jun 12, 2026 | 1 |
| Jun 15, 2026 | 1 |
| Jun 17, 2026 | 3 |
| Jun 19, 2026 | 2 |
| Jun 21, 2026 | 1 |
| Jun 22, 2026 | 2 |
| Jun 24, 2026 | 1 |
| Jun 26, 2026 | 3 |
| Jun 29, 2026 | 3 |
| Jun 30, 2026 | 1 |
| Aug 3, 2026 | 2 |
| Aug 5, 2026 | 1 |
| Aug 7, 2026 | 3 |
| Aug 10, 2026 | 3 |
| Aug 12, 2026 | 2 |
| Aug 14, 2026 | 1 |
| Aug 17, 2026 | 1 |
| Aug 19, 2026 | 3 |
| Aug 21, 2026 | 2 |
| Aug 23, 2026 | 1 |
| Aug 24, 2026 | 2 |
| Aug 26, 2026 | 1 |
| Aug 28, 2026 | 3 |
| Aug 31, 2026 | 3 |
| Sep 1, 2026 | 1 |
| Sep 2, 2026 | 2 |
| Sep 4, 2026 | 1 |
| Sep 7, 2026 | 1 |
| Sep 9, 2026 | 3 |
| Sep 10, 2026 | 1 |
| Sep 11, 2026 | 2 |
| Sep 14, 2026 | 2 |
| Sep 16, 2026 | 1 |
| Sep 18, 2026 | 3 |
| Sep 19, 2026 | 1 |
| Sep 21, 2026 | 3 |
| Sep 23, 2026 | 2 |
| Sep 25, 2026 | 1 |
| Sep 28, 2026 | 1 |
| Sep 30, 2026 | 3 |
| Oct 2, 2026 | 2 |
| Oct 5, 2026 | 2 |
| Oct 7, 2026 | 1 |
| Oct 9, 2026 | 3 |
Props
| Prop | Type | Défaut | Description |
|---|---|---|---|
datarequis | readonly T[] | — | One row per day (days without a row read as nothing). |
daterequis | string | ((datum: T, index: number) => unknown) | — | The field of the day: an ISO date (2026-04-12), a Date or an epoch. |
titlerequis | string | — | What the chart shows, in a few words: its accessible name, and its heading unless hideTitle. |
valuerequis | string | ((datum: T, index: number) => number) | — | The field of the day's value. |
brand | BrandId | — | The brand whose palette the charts use. Without it, a chart follows a .brand-<id> ancestor, else Krizaka. Set it
when the app loads a brand stylesheet on :root (@krizaka/tokens/brands/orazaka.css). |
className | string | — | A class on the figure (layout: margins, grid placement). |
dataTable | boolean | — | The "Show data" button (the table is in the page for screen readers either way). Default true. |
description | ReactNode | — | A sentence under the title: the period, the unit, the source. |
empty | ReactNode | — | What to show when there is nothing to draw (default: the empty label). An EmptyState of
@krizaka /ui fits. |
error | ReactNode | — | The data could not be loaded: true says the default words, a node says yours (a retry button…). |
exportable | boolean | readonly ExportFormat[] | — | Export buttons: true for PNG, SVG and CSV, or the formats you want. |
format | ValueFormat | — | How the values are written. |
height | number | — | The height of the plot in pixels. Default 280 (a sparkline: 32). |
hideTitle | boolean | — | Visually hide the title (it stays the chart's accessible name): a card that already has its heading. |
id | string | — | The id of the figure. |
labels | ChartLabelsInput | — | The words, translated: the buttons, the states, the written summary. |
live | boolean | — | Streaming data (a job queue, an auction): no entrance on updates, no announcement of every new point. |
loading | boolean | — | The data is on its way: a skeleton of the chart, announced once. |
locale | Locale | — | The locale of every figure and date ("fr-FR"). Default "en-US". |
range | readonly [string, string] | — | The first and last days shown. Default: the year before the last day of the data. |
renderer | Renderer | — | svg (default): sharp, exportable as SVG. canvas: for tens of thousands of marks. |
style | CSSProperties | — | Inline style on the figure (layout only: colours come from the tokens). |
summary | "hidden" | "visible" | — | The written summary: read by screen readers only ("hidden", default), or shown under the chart ("visible"). |
summaryText | string | — | Your own summary instead of the generated one (still read first by screen readers). |
valueLabel | string | — | The header of the values in the data table. |
Accessibilité
- The plot is a group named by the title and described by a summary written from the data, read before anything else.
- The data table is always in the page for assistive technology; “Show data” reveals it for everyone.
- The engine (ECharts core and this one chart type) loads when the chart nears the screen; a skeleton of the same height holds its place, so nothing shifts.
- Under reduced motion the chart is drawn without animation.
- The summary says the total, the busiest day and the number of active days.
Clavier
| Touches | Action |
|---|---|
| Tab | Moves the focus to the plot (one tab stop), then to the data and export buttons. |
| Arrow keys | Walk the items one by one: each is announced and highlighted, its tooltip shown. |
| Home / End | Jump to the first or the last item. |
| Esc | Hides the tooltip and clears the highlight. |
Bonnes pratiques
- Pass ISO dates (
2026-04-12): the month and weekday names come from the locale. - Leave days without activity out of the data: they are drawn empty.
Composants liés
Générée depuis le code de @krizaka/ui 2.4.0 : son meta.ts, ses exemples et ses types.Modifier cette documentation sur GitHub