{"version":3,"file":"giphyAccessibility.mjs","names":[],"sources":["../../../../src/components/Attachment/giphyAccessibility.ts"],"sourcesContent":["/** Whether a string looks like a media URL, which must not be used as an accessible name. */\nexport const looksLikeUrl = (value?: string | null): boolean =>\n  !!value && /^(https?:|\\/\\/)/i.test(value);\n\n/**\n * Returns a human, non-URL giphy title for accessible names and announcements, or `undefined`.\n * Giphy payloads rarely carry a real title (it is often a media URL), so callers provide a generic\n * label for `undefined`. Shared by `Giphy` and `AttachmentActions` so both resolve it the same way.\n * @param title - Title from the attachment payload.\n */\nexport const getGiphyDescriptiveTitle = (title?: string | null): string | undefined =>\n  looksLikeUrl(title) ? undefined : (title ?? undefined);\n"],"mappings":";;AACA,IAAa,gBAAgB,UAC3B,CAAC,CAAC,SAAS,mBAAmB,KAAK,KAAK;;;;;;;AAQ1C,IAAa,4BAA4B,UACvC,aAAa,KAAK,IAAI,KAAA,IAAa,SAAS,KAAA"}