User activity calendar

A personal activity calendar makes repeated behaviour visible without reducing it to a single streak. For a learning app, completed practice sessions on each day show both busy periods and gaps that a lifetime total cannot explain. The screenshot is from Fission's chart gallery.

What the chart is for

The measure here is completed practice sessions for the current user. Starting a session and completing one are not interchangeable. Count the event that matches the user's goal, and do not present a missing day as a failure.

Data model

Supply ISO date/count pairs after aggregating completed sessions. Choose whether the calendar follows the user's timezone or a fixed reporting timezone and keep that choice stable, particularly when the user travels.

Rust API

Setting
Type
Meaning
CalendarHeatmapSeries::data
Vec<(&str, f32)>
Converts date/value pairs into the series' owned Vec<(String, f32)>.
CalendarHeatmapSeries::range
&str, &str
Sets the displayed start and end dates.
Chart::visual_map
VisualMap
Sets the numeric colour range.
Chart::series
Vec<Series>
Adds the calendar series; Cartesian axes are not required.

Example

use fission::charts::{CalendarHeatmapSeries, Chart, VisualMap};

let chart = Chart::new()
    .title("Practice sessions completed per day")
    .visual_map(VisualMap::new().min(0.0).max(5.0))
    .series(vec![CalendarHeatmapSeries::new("Completed sessions")
        .range("2026-10-01", "2026-10-31")
        .data(vec![
            ("2026-10-01", 2.0),
            ("2026-10-02", 0.0),
            ("2026-10-03", 1.0),
        ])
        .into()]);

Authoring from a Fission component

The parent supplies the daily values. This component presents them; it does not start a request during the build.
use fission::prelude::*;
use fission::charts::{CalendarHeatmapSeries, Chart, Series, VisualMap};

// The parent resolves display labels from its translation bundles.
fission_component! {
    pub UserActivityCalendarChart<()> {
        props {
            chart_title: String,
            series_label: String,
            daily_values: Vec<(String, f32)>,
        }
    }
    view(calendar, _state, _cx) =>
        Chart(
            title: Some(calendar.chart_title.clone()),
            visual_map: Some(VisualMap::new().min(0.0).max(5.0)),
            series: vec![Series::CalendarHeatmap(CalendarHeatmapSeries {
                name: calendar.series_label.clone(),
                data: calendar.daily_values.clone(),
                start: Some("2026-10-01".into()),
                end: Some("2026-10-31".into()),
            })],
        )
}

Interaction and accessibility

A selected day can show that user's session history through a reducer. Provide a readable count alongside the visual and avoid motion or labels that turn an ordinary gap into artificial urgency.

Testing guidance

Check several sessions on one day, no sessions on a recorded day, and a session completed across midnight. A zero-valued record and a failed activity load must lead to different application states. Check the rendered calendar at the dashboard's actual width as well as testing the aggregate values.
Tags: calendar, user.