{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "Tags, reading figures and an author card with share and save over a wide cover; the author, figures, tags and actions beside the cover; or the facts and related reading beside it.",
  "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 post header with the author, the reading figures, the tags and the actions. Axes: layout (center: tags,\n * figures and an author card with share and save over a wide cover; split: beside the cover; outline: facts and\n * related reading beside the cover), mediaSide, author (line, card, bio), cover (wide, square), actions (pair,\n * wide, icons), tone.\n */\nimport { type ReactNode } from \"react\";\nimport { MediaFrame } from \"../components/media-frame\";\nimport { PostActions } from \"../components/post-actions\";\nimport { PostAuthor } from \"../components/post-author\";\nimport { PostOutline } from \"../components/post-outline\";\nimport { PostStats } from \"../components/post-stats\";\nimport { PostTags } from \"../components/post-tags\";\nimport { SectionFrame } from \"../components/section-frame\";\nimport type { PostExtras, PostSplitLabels } from \"./post-split.types\";\nimport type { Post } from \"./post-card.types\";\nimport type { NavLink } from \"./nav-bar.types\";\n\nexport type PostSplitProps = {\n  id: string;\n  post: Post;\n  labels: PostSplitLabels;\n  extras: PostExtras;\n  level?: 1 | 2;\n  layout?: \"center\" | \"split\" | \"outline\";\n  mediaSide?: \"end\" | \"start\";\n  author?: \"line\" | \"card\" | \"bio\";\n  cover?: \"wide\" | \"square\";\n  actions?: \"pair\" | \"wide\" | \"icons\";\n  tone?: \"default\" | \"muted\";\n  landmarkLabel?: string;\n};\n\nexport function PostSplit({\n  id,\n  post,\n  labels,\n  extras,\n  level = 1,\n  layout = \"split\",\n  mediaSide = \"end\",\n  author = \"line\",\n  cover = \"wide\",\n  actions = \"pair\",\n  tone = \"default\",\n  landmarkLabel,\n}: PostSplitProps) {\n  return (\n    <>\n      {((layout as string) === \"center\") ? (\n        <SectionFrame\n          id={id}\n          title={post.title}\n          lead={post.excerpt}\n          heading={{ badge: post.category, level }}\n          tone={tone}\n          media={{ show: true }}\n          align=\"center\"\n          landmarkLabel={landmarkLabel}\n          aside={(\n            <MediaFrame\n              alt={post.title}\n              src={post.image}\n              ratio={\n                (layout as string) === \"center\" ? \"21/9\"\n                : (cover as string) === \"square\" ? \"1/1\"\n                : \"4/3\"\n              }\n            />\n          )}\n        >\n          {((extras.tags?.length ?? 0) > 0) ? (\n            <PostTags tags={extras.tags} align=\"center\" />\n          ) : null}\n          <PostStats post={post} extras={extras} labels={labels} align=\"center\" />\n          <PostAuthor\n            post={post}\n            extras={extras}\n            labels={labels}\n            mode=\"card\"\n            share={true}\n            className=\"mx-auto w-full max-w-md\"\n          />\n        </SectionFrame>\n      ) : (\n        <SectionFrame\n          id={id}\n          title={post.title}\n          lead={post.excerpt}\n          heading={{ badge: post.category, level }}\n          tone={tone}\n          media={{ show: true, side: mediaSide }}\n          layout=\"split\"\n          landmarkLabel={landmarkLabel}\n          aside={(\n            <MediaFrame\n              alt={post.title}\n              src={post.image}\n              ratio={\n                (layout as string) === \"center\" ? \"21/9\"\n                : (cover as string) === \"square\" ? \"1/1\"\n                : \"4/3\"\n              }\n            />\n          )}\n        >\n          {((layout as string) === \"outline\") ? (\n            <>\n              {((extras.outline?.length ?? 0) > 0) ? (\n                <PostOutline post={post} extras={extras} labels={labels} />\n              ) : null}\n            </>\n          ) : (\n            <>\n              <PostAuthor post={post} extras={extras} labels={labels} mode={author} />\n              {((author as string) !== \"line\") ? (\n                <PostStats post={post} extras={extras} labels={labels} />\n              ) : null}\n              {((extras.tags?.length ?? 0) > 0) ? (\n                <PostTags tags={extras.tags} />\n              ) : null}\n            </>\n          )}\n          <PostActions labels={labels} mode={actions} />\n        </SectionFrame>\n      )}\n    </>\n  );\n}\n",
      "path": "blocks/post-split.tsx",
      "target": "blocks/post-split.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\nimport type { NavLink } from \"./nav-bar.types\";\n\nexport type PostExtras = {\n  role: string;\n  bio: string;\n  views: string;\n  likes: string;\n  tags: NavLink[];\n  outline: NavLink[];\n};\n\nexport type PostSplitLabels = {\n  minutes: string;\n  views: string;\n  likes: string;\n  share: string;\n  save: string;\n  read: string;\n  related: string;\n};\n",
      "path": "blocks/post-split.types.ts",
      "target": "blocks/post-split.types.ts"
    }
  ],
  "meta": {
    "category": "content",
    "group": "blog",
    "kind": "block",
    "tags": [
      "react",
      "block"
    ]
  },
  "name": "post-split",
  "registryDependencies": [
    "media-frame",
    "nav-bar",
    "post-actions",
    "post-author",
    "post-card",
    "post-outline",
    "post-stats",
    "post-tags",
    "section-frame",
    "utils"
  ],
  "runtime": "react",
  "title": "Post Split",
  "type": "registry:block"
}
