Skip to main content

Summary

This feature provides users with granular analytics about their digital habits. It splits into two main views: a Global Scroll Detail view that aggregates physical scrolling distance across all apps, and a Single App Detail view that offers a deep dive into a specific app’s usage patterns. It solves the problem of vague screen time data by distinguishing between “passive” scrolling and “active” usage, while visualizing the physical toll of infinite scrolling in meters and kilometers.

How It Works

Single App Deep Dive

When a user selects a specific app from their dashboard, the app launches a detailed analytics screen. This screen combines historical data with “smart insights” to tell a story about how the user interacts with that specific application.
1

Initialization & Metadata Loading

When the screen opens, the ViewModel immediately identifies the app package. It retrieves the app’s name, icon, and current visibility settings (whether it is hidden or tracked). It also checks if there are any active time limits set for this app.
2

Data Retrieval & Charting

The system fetches usage data for the current week. This includes three distinct metrics:
  1. Total Time: How long the app was open.
  2. Active Time: How long the user was actually touching the screen or typing.
  3. Scroll Distance: The physical distance scrolled (converted from pixels to meters).
This data is fed into a custom Chart Component that draws bars for usage time and overlays a “heat map” background representing scroll intensity.
3

Generating Insights

The system analyzes the raw data to generate human-readable “Insights.” It compares the current week’s performance to the previous week. For example, if the user scrolled 50% less than last week, it generates a positive comparison card. It also calculates “Focus Quality” by comparing Active Time vs. Total Time.
4

User Interaction

The user can swipe the chart left or right to view previous weeks. They can also tap “Quick Actions” to launch the app, open system settings, or toggle whether this app counts towards their total screen time goals.

Global Scroll Analytics

This view aggregates data from all apps to show the user the total physical distance they have scrolled on their device.
1

Aggregation & Conversion

The ScrollDetailViewModel pulls scroll data for every app in the database. It uses a utility to convert raw screen pixels into physical units (meters or kilometers) based on the device’s screen density (DPI).
2

Heatmap Visualization

The data is mapped onto a Calendar Heatmap. Days with heavy scrolling appear darker, allowing the user to spot trends over the month. Users can tap specific dates to filter the data below.
3

Ranking & Categorization

The screen displays a list of apps sorted by how much they contributed to the total scroll distance. It separates currently installed apps from “Removed Apps” (apps the user deleted but still have historical data for), ensuring the total distance remains accurate even after uninstallation.

Data Stored

This feature processes and visualizes the following data points:
FieldTypeDescription
usageTimeMillisLongTotal duration the app was in the foreground (milliseconds).
activeTimeMillisLongDuration of active input (touch/type) within the app.
scrollUnitsLongRaw distance scrolled (pixels or micrometers).
openCountIntegerNumber of times the app was launched.
dateStringThe specific date for the record (YYYY-MM-DD).
isInstalledBooleanFlag indicating if the app is currently on the device.

Key Components

AppDetailScreen

The main UI container for a single app’s analytics. It orchestrates the chart, insight grid, and quick action buttons.

UsageBarScrollLineChart

A custom-drawn canvas component that visualizes usage time (bars) and scroll intensity (background heatmap) simultaneously.

AppDetailInsightsGrid

A “Bento-box” style layout engine that dynamically arranges insight cards (like “Focus Quality” or “Frequency”) based on available data.

ScrollDetailViewModel

The logic engine for the global view. It handles the complex task of aggregating pixel data across all apps and converting it to physical distance.
Last modified on January 25, 2026