import * as v from 'valibot'; import { accountSchema } from './account'; /** * @category Schemas * @see {@link https://docs.joinmastodon.org/entities/PreviewCardAuthor/} */ const previewCardAuthorSchema = v.object({ name: v.string(), url: v.pipe(v.string(), v.url()), account: v.fallback(v.nullable(accountSchema), null), }); type PreviewCardAuthor = v.InferOutput; export { previewCardAuthorSchema, type PreviewCardAuthor };