{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "Recent events as a timeline or a list.",
  "devDependencies": [],
  "digest": "0.1.0",
  "files": [
    {
      "content": "// Code generated by packages/kit-compose/src/organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT.\n/**\n * A panel with recent events: a timeline with dots on a line, or a list of rows with an icon. Axes: layout\n * (timeline, list), density (default, compact), tone (default, muted).\n */\nimport { For, type JSX } from \"solid-js\";\nimport { Block, Container, List, ListItem, Stack, Text } from \"../compose\";\nimport { EmptyState } from \"../components/empty-state\";\nimport { Panel } from \"../components/panel\";\nimport { Timeline } from \"../components/timeline\";\nimport { cn, tpl } from \"../utils\";\nimport type { Event } from \"./activity-feed.types\";\n\nexport type ActivityFeedProps = {\n  id: string;\n  title: string;\n  text: string;\n  events: Event[];\n  empty?: string;\n  layout?: \"timeline\" | \"list\";\n  density?: \"default\" | \"compact\";\n  tone?: \"default\" | \"muted\";\n  landmarkLabel?: string;\n};\n\nexport function ActivityFeed({\n  id,\n  title,\n  text,\n  events,\n  empty = \"\",\n  layout = \"timeline\",\n  density = \"default\",\n  tone = \"default\",\n  landmarkLabel,\n}: ActivityFeedProps) {\n  return (\n    <Block\n      tag=\"section\"\n      aria-labelledby={(landmarkLabel ? undefined : ((title && id) ? tpl(\"{0}-t\", id) : undefined))}\n      aria-label={landmarkLabel}\n      data-slot=\"panel-section\"\n    >\n      <Container class=\"mx-auto w-full max-w-6xl px-4 py-8\" data-slot=\"container\">\n        <Panel title={title} description={text} id={id} class={(((tone as string) === \"muted\") ? \"bg-muted\" : \"\")}>\n          {((events?.length ?? 0) === 0) ? (\n            <EmptyState icon=\"activity\" title={empty} />\n          ) : ((layout as string) === \"timeline\") ? (\n            <Timeline items={events} />\n          ) : (\n            <List class=\"m-0 flex list-none flex-col p-0\" data-slot=\"items\">\n              <For each={events ?? []}>{(e) => (\n                <ListItem\n                  class={cn(\n                    \"flex items-start justify-between gap-4 border-b border-border last:border-0\",\n                    (((density as string) === \"compact\") ? \"py-2\" : \"py-4\")\n                  )}\n                  data-slot=\"item\"\n                >\n                  <Stack gap=\"0\">\n                    <Text size=\"sm\" weight=\"semibold\">\n                      {e.title}\n                    </Text>\n                    {((density as string) === \"default\") ? (\n                      <Text size=\"sm\" class=\"text-muted-foreground\">\n                        {e.text}\n                      </Text>\n                    ) : null}\n                  </Stack>\n                  <Text size=\"xs\" class=\"shrink-0 text-muted-foreground\">\n                    {e.time}\n                  </Text>\n                </ListItem>\n              )}</For>\n            </List>\n          )}\n        </Panel>\n      </Container>\n    </Block>\n  );\n}\n",
      "path": "blocks/activity-feed.tsx",
      "target": "blocks/activity-feed.tsx"
    },
    {
      "content": "// Code generated by packages/kit-compose/src/organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT.\n\nexport type Event = {\n  id: string;\n  title: string;\n  text: string;\n  time: string;\n  tone: string;\n};\n",
      "path": "blocks/activity-feed.types.ts",
      "target": "blocks/activity-feed.types.ts"
    }
  ],
  "meta": {
    "category": "dashboard",
    "group": "widgets",
    "kind": "block",
    "tags": [
      "solid",
      "block"
    ]
  },
  "name": "activity-feed",
  "registryDependencies": [
    "compose",
    "empty-state",
    "panel",
    "timeline",
    "utils"
  ],
  "runtime": "solid",
  "title": "Activity Feed",
  "type": "registry:block"
}
