MCPcopy
hub / github.com/GitbookIO/gitbook / getPagePDFContainerId

Function getPagePDFContainerId

packages/gitbook/src/components/PDF/PDFPage.tsx:362–367  ·  view source on GitHub ↗

* Create the HTML ID for the container of a page or a given anchor in it.

(
    page: RevisionPageDocument | RevisionPageGroup,
    anchor?: string
)

Source from the content-addressed store, hash-verified

360 * Create the HTML ID for the container of a page or a given anchor in it.
361 */
362function getPagePDFContainerId(
363 page: RevisionPageDocument | RevisionPageGroup,
364 anchor?: string
365): string {
366 return `pdf-page-${page.id}${anchor ? `-${anchor}` : ''}`;
367}

Callers 4

PDFPageFunction · 0.85
toPathForPageFunction · 0.85
PDFPageGroupFunction · 0.85
PDFPageDocumentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected