--- import PostMetadata from "./PostMetadata.astro"; interface Props { class: string; entry: any; title: string; url: string; published: Date; tags: string[]; categories: string[]; cover: string; description: string; words: number; } const { entry, title, url, published, tags, categories, cover, description, words } = Astro.props; const className = Astro.props.class; // console.log(Astro.props); import ImageBox from "./misc/ImageBox.astro"; import ButtonTag from "./control/ButtonTag.astro"; import { Icon } from 'astro-icon/components'; import Button from "./control/Button.astro"; import {i18n} from "../i18n/translation"; import I18nKey from "../i18n/i18nKey"; // tags = ['Foo', 'Bar', 'Baz', 'Qux', 'Quux']; // const cover = 'https://saicaca.github.io/vivia-preview/assets/79905307_p0.jpg'; // cover = null; const hasCover = cover !== undefined && cover !== null && cover !== ''; const coverWidth = "28%"; const { remarkPluginFrontmatter } = await entry.render(); ---
{title}
{ description }
{remarkPluginFrontmatter.words} {" " + i18n(I18nKey.wordsCount)}
|
{remarkPluginFrontmatter.minutes} {" " + i18n(I18nKey.minutesCount)}
{hasCover &&
} {!hasCover && }