/** * Builds WebPage JSON-LD with a `speakable` SpeakableSpecification — tells voice * assistants and AI which parts of the page are meant to be read aloud / * quoted. A GEO signal: pairs with the Markdown/llms work to make the page's key * content easy for assistants to lift cleanly. * * Add to the page's @graph via JsonLdGraph (recommended) or emit standalone: * * import { buildSpeakableJsonLd } from '@intecion/ipal-kit' * const node = buildSpeakableJsonLd({ url: canonical, cssSelectors: ['h1', '.lead'] }) * * Mark the matching elements in the project markup (e.g. className="speakable" * or a `.lead` summary). Selectors that match nothing are simply ignored by * consumers — but don't point at nav/boilerplate. */ export function buildSpeakableJsonLd({ id, cssSelectors = [ 'h1', '.speakable' ], url }) { return { '@context': 'https://schema.org', '@type': 'WebPage', ...id ? { '@id': id } : {}, speakable: { '@type': 'SpeakableSpecification', cssSelector: cssSelectors }, url }; } //# sourceMappingURL=buildSpeakableJsonLd.js.map