// Types for ./social.mjs (release 29 G2): how a post for X or Bluesky is // counted, its link, and what `publish.x` / `publish.bluesky` may hold. export type SocialPlatform = "x" | "bluesky"; /** `publish.x` / `publish.bluesky`: the first post (its link in it) and up to 4 more under it. */ export type SocialPost = { post: string; thread?: string[] }; export const SOCIAL_PLATFORMS: readonly SocialPlatform[]; export const SOCIAL_LIMITS: Readonly<{ x: number; bluesky: number; thread: number; urlWeight: number }>; export const SOCIAL_NAMES: Readonly>; export const SOCIAL_URL_RE: RegExp; export const SOCIAL_TLDS: readonly string[]; export function hasLink(text: unknown): boolean; export function graphemes(text: unknown): string[]; export function xLength(text: unknown): number; export function blueskyLength(text: unknown): number; export function socialLength(platform: SocialPlatform, text: unknown): number; export function socialLimit(platform: SocialPlatform): number; export function withLink(post: unknown, link: string | null | undefined): string; export function validateSocialPost(platform: SocialPlatform, v: unknown, where?: string): string[]; export function socialLinkOf(manifest: unknown, o?: { articleUrl?: string | null }): string | null;