ComponentsPublishing
Author Card
Author bio box featuring avatar, biography, social links, and post counts.
Install
npx ghostcn@1.4.0 add author-card --skip-existingUsage
Pass an author context. In post.hbs you can use {{#primary_author}} as below; on an author archive use {{#author}}.
{{#primary_author}}
{{> "components/author-card"}}
{{/primary_author}}Customize this instance
{{#primary_author}}
{{> "components/author-card" class="my-6" titleClass="text-purple-700 dark:text-purple-300"}}
{{/primary_author}}Styling parameters
| Parameter | Target |
|---|---|
class | Component root — .gh-author-card |
avatarClass | .gh-author-avatar, .gh-author-avatar-fallback |
contentClass | .gh-author-details |
titleClass | .gh-author-name |
descriptionClass | .gh-author-bio |
metaClass | .gh-author-meta |
Styling parameters affect only elements that render. See Style component instances for specificity, dark mode, and preserving customizations.
Installed files
partials/components/author-card.hbsassets/css/components/author-card.css
Was this helpful?