Vilqor

AI Memory Timeline

AI chats

About

A thread through past entries, each a dot with a day and a note, ending in the one happening now. Words in [brackets] become quiet tags, so the same names recur from day to day. Part of Midnight, the full template on 21st.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds AI Memory Timeline to your project and fits it to your theme.

Code

How AI Memory Timeline is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import { useSyncExternalStore, type CSSProperties } from "react"

import { MemoryTimeline } from "@/components/ui/memory-timeline"

const fonts =
  "@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght,SOFT@0,9..144,300..600,0..100;1,9..144,300..600,0..100&family=Geist:wght@400..600&family=Geist+Mono:wght@400..500&display=swap');"

const settings = {
  background: "#f7f5f0",
  card: "#ffffff",
  text: "#141a2e",
  muted: "#4a5166",
  primary: "#a8803a",
}

// Midnight by night, the template's own palette
const night: Partial<typeof settings> = {
  background: "#0b1020",
  card: "#111731",
  text: "#ece9e1",
  muted: "#a9afc4",
  primary: "#d9b77e",
}

// 21st marks its dark theme with .dark on <html>; the demo answers with Midnight by night
function useDark() {
  return useSyncExternalStore(
    (on) => {
      const watch = new MutationObserver(on)
      watch.observe(document.documentElement, { attributes: true, attributeFilter: ["class"] })
      return () => watch.disconnect()
    },
    () => document.documentElement.classList.contains("dark"),
    () => false,
  )
}

// Midnight by day as theme tokens: warm paper, night-blue ink, deep gold with white text on it,
// Fraunces for headings, Geist for text, Geist Mono for figures. The component itself only reads the tokens.
function day(s: typeof settings) {
  const t: Record<string, string> = {
    background: s.background,
    foreground: s.text,
    card: s.card,
    primary: s.primary,
    "muted-foreground": s.muted,
  }
  return {
    ...Object.fromEntries(Object.entries(t).flatMap(([k, v]) => [[`--${k}`, v], [`--color-${k}`, v]])),
    "--font-display": "Fraunces, ui-serif, Georgia, serif",
    "--font-sans": "Geist, ui-sans-serif, system-ui, sans-serif",
    "--font-mono": "'Geist Mono', ui-monospace, Menlo, monospace",
  } as CSSProperties
}

export default function Demo(props: Partial<typeof settings>) {
  const dark = useDark()
  const s = { ...settings, ...props, ...(dark ? night : {}) }
  return (
    <div
      className="flex min-h-svh w-full items-center justify-center px-5 py-12"
      style={{ ...day(s), "--mn-edge": dark ? "inset 0 1px 0 0 rgb(255 255 255 / 0.09), inset 0 0 0 1px rgb(255 255 255 / 0.045), 0 1px 1px rgb(0 0 0 / 0.25), 0 14px 28px -18px rgb(0 0 0 / 0.55)" : "inset 0 0 0 1px rgb(20 26 46 / 0.07), 0 1px 2px rgb(20 26 46 / 0.05), 0 16px 32px -20px rgb(20 26 46 / 0.22)", fontFamily: "Geist, ui-sans-serif, system-ui, sans-serif", background: s.background, color: s.text } as CSSProperties}
    >
      <style>{fonts}</style>
      <div
        className="w-full max-w-[520px] rounded-[28px] p-8 md:p-10"
        style={{ background: s.card, boxShadow: "var(--mn-edge)" }}
      >
        <p className="text-[14px] font-medium" style={{ color: dark ? "#e3c592" : "#8a6a2e" }}>
          Context
        </p>
        <h3 className="mt-3 text-[26px] leading-[32px] font-semibold tracking-[-0.025em] text-balance">
          <span>Context that carries over.</span> <span style={{ color: s.muted }}>Every meeting picks up where the last one ended.</span>
        </h3>
        <MemoryTimeline
          className="mt-10"
          entries={[
            { when: "Mon", text: "[Acme] wants the pilot to start in [March]" },
            { when: "Tue", text: "[Legal] asked for the data processing terms" },
            { when: "Wed", text: "[Priya] at [Acme] owns the rollout" },
          ]}
          current={{ when: "Today", text: "Call with [Priya]: confirm [March] and send the [Legal] terms" }}
        />
      </div>
    </div>
  )
}

Dependencies

More by Vilqor

View all
  • 3D Glass Cube Hero

    3D Glass Cube Hero

    210
  • Footer with Big Wordmark

    Footer with Big Wordmark

    163
  • Guilloche Background Pattern

    Guilloche Background Pattern

    8
  • Card Carousel to Grid

    Card Carousel to Grid

  • AI Email Reply with Tones

    AI Email Reply with Tones

  • Use Cases Tabs Section

    Use Cases Tabs Section

  • Pricing Section with Toggle

    Pricing Section with Toggle

  • Logo Cloud Marquee

    Logo Cloud Marquee

More in AI chats

View all
  • AI Actions

    AI Actions

    372
  • Agent Chat

    Agent Chat

    21
  • Aquarium Prompt

    Aquarium Prompt

    212
  • Illos Knowledge Sources

    Illos Knowledge Sources

    71
  • AI SaaS Workflow Hero

    AI SaaS Workflow Hero

    32
  • AI Chat Composer

    AI Chat Composer

    17
  • AI Response

    AI Response

    16
  • Thumbs pour

    Thumbs pour