UNPKG

@rr0/cms

Version:

RR0 Content Management System (CMS)

19 lines (18 loc) 735 B
import { HtmlSsgContext } from "ssg-api"; import { HtmlRR0Context } from "RR0Context.js"; import { AnchorHandler } from "./AnchorHandler.js"; export declare class AnchorReplacer { protected handlers: AnchorHandler[]; protected readonly baseUrl: string; constructor(baseUrl: string, handlers: AnchorHandler[]); replacement(context: HtmlRR0Context, a: HTMLAnchorElement): Promise<HTMLAnchorElement>; /** * Update a link to denote it as external. * * @param context * @param a * @protected */ protected updateLinkExternal(context: HtmlSsgContext, a: HTMLAnchorElement): void; protected updateLinkInternal(context: HtmlRR0Context, a: HTMLAnchorElement, url: URL): Promise<void>; }