Activity Log

Loading preview

Starting the Flutter app

A Flutter admin activity log with a timeline of user actions, actors, and timestamps.

Get the source

Add it to your project

Copies the Dart source into your app, so you own it. Flutter SDK only, no extra packages.

First time? Run dart pub global activate fluttertemplates_dev, or read the CLI guide.

How it works

ActivityLog is stateless and reads a const _events list of six entries, with times stored as ready-made strings like ‘2 min ago’. Each row is an IntrinsicHeight Row, which lets the connector line stretch to the height of the text beside it, and isLast drops the line on the final entry. The filter button in the app bar shows a demo SnackBar.

Adapting it

  • Load _events from your audit API and make _Event.time a DateTime formatted at render time, so entries don’t go stale.
  • Derive _Event.icon from an event type instead of setting it by hand per row.
  • Use the Icons.filter_list button’s onPressed to open a filter by actor or action.