{
  "name": "MemoriesDialog",
  "package": "@magicblocksai/ui",
  "file": "packages/ui/src/components/MemoriesDialog.tsx",
  "chapterTag": "16 Pipeline & CRM",
  "chapter": "16-app-pipeline.html",
  "sectionId": "memories-dialog",
  "elName": "MemoriesDialog",
  "demoUrl": "https://brand.magicblocks.ai/components/16-app-pipeline#memories-dialog",
  "hasLiveDemo": false,
  "description": "The \"expand memories\" popup. The launcher opens a `<Modal>` listing every memory\nthe agent captured — text, category, confidence, the source quote it was inferred\nfrom, and a \"history\" badge for memories carried across sessions. Composes the\nkit's `<Modal>` + `<MemoryList>`.",
  "useClient": true,
  "interactivity": "interactive",
  "namedExports": [
    {
      "name": "MemoriesDialog",
      "isPrincipal": true,
      "isType": false
    },
    {
      "name": "MemoriesDialogProps",
      "isPrincipal": false,
      "isType": true
    }
  ],
  "importStatement": "import { MemoriesDialog } from \"@magicblocksai/ui\";",
  "props": [
    {
      "name": "memories",
      "optional": false,
      "type": "Memory[]",
      "doc": "Every memory collected (the dialog shows them all; the summary band shows a preview)."
    },
    {
      "name": "trigger",
      "optional": true,
      "type": "ReactNode",
      "doc": "Launcher element. Defaults to a secondary \"Expand all memories (N)\" button."
    },
    {
      "name": "title",
      "optional": true,
      "type": "ReactNode",
      "doc": "Dialog title. Defaults to \"Memories collected\"."
    },
    {
      "name": "footnote",
      "optional": true,
      "type": "ReactNode",
      "doc": "Quiet footer note. Defaults to the persist-to-profile line."
    },
    {
      "name": "open",
      "optional": true,
      "type": "boolean",
      "doc": "Controlled open state."
    },
    {
      "name": "defaultOpen",
      "optional": true,
      "type": "boolean",
      "doc": "Uncontrolled initial open state."
    },
    {
      "name": "onOpenChange",
      "optional": true,
      "type": "(open: boolean) => void",
      "doc": "Fires when the dialog opens or closes."
    }
  ],
  "classesUsed": [
    "memories-dialog",
    "memories-dialog-foot",
    "memories-dialog-launch"
  ],
  "examples": {
    "react": "<MemoriesDialog memories={[\n  { id: \"m1\", text: \"Prefers Slack for team handoffs\", type: \"preference\", confidence: \"high\", source: \"this session\", sourceQuote: \"CS team handing off to Slack\" },\n]} />",
    "html": "<div style=\"display:flex; flex-direction:column; gap:16px;\">\n  <div><button type=\"button\" class=\"btn btn-secondary\">Expand all memories (5)</button></div>\n  <div class=\"memories-dialog\" style=\"max-width:520px;\">\n    <div class=\"memory-list\">\n      <div class=\"memory-row\"><div class=\"memory-body\"><div class=\"memory-text\">Prefers Slack for team handoffs</div><div class=\"memory-quote\">CS team handing off to Slack</div><div class=\"memory-meta\"><span class=\"memory-type\">preference</span><span class=\"memory-source\">this session</span><span class=\"memory-conf\" data-conf=\"high\">high</span></div></div></div>\n      <div class=\"memory-row\"><div class=\"memory-body\"><div class=\"memory-text\">Raised SLA concerns previously</div><div class=\"memory-meta\"><span class=\"memory-history\">history</span><span class=\"memory-source\">session #S-4102</span><span class=\"memory-conf\" data-conf=\"high\">high</span></div></div></div>\n    </div>\n    <div class=\"memories-dialog-foot\">These memories persist to the contact&apos;s profile.</div>\n  </div>\n</div>",
    "css": ".memories-dialog { display: flex; flex-direction: column; }\n\n.memories-dialog-foot { display: flex; align-items: center; gap: var(--s-2); margin-top: var(--s-3); padding-top: var(--s-3); border-top: 1px solid var(--hair-soft); font: 500 11.5px/1.4 var(--f-body); color: var(--fg-faint); }\n\n.memories-dialog-launch { display: contents; }"
  }
}
