Componenteditors0.83 KB gzipZero dependencies

Audit Log

Audit trail with actor avatars, color-coded action badges and timestamps.

Preview

Live Preview
Open ↗

Installation

Tokens guide →

Add to your project via CLI (zero dependencies, code you own):

npx bigbullui add audit-log

Or install the full npm package:

npm install bigbullui

Usage

tsx3 lines
import { AuditLog } from "@/components/ui/audit-log"; <AuditLog />

Source code

audit-log.tsx + 1 helper

Zero third-party dependencies (2 local files shown in tabs below).

tsxaudit-log.tsx75 lines
"use client"; import * as React from "react";import { cn } from "./lib/utils"; export type AuditAction = "create" | "update" | "delete" | "login" | "export"; export interface AuditEntry {  id: string;  actor: string;  initials: string;  action: AuditAction;  target: string;  time: string;  ip?: string;} export interface AuditLogProps extends React.HTMLAttributes<HTMLDivElement> {

Props

PropTypeDescription
entriesAuditEntry[]Configures entries. (Default: [])
filterAuditAction | "all"Shows all actions if omitted