/** * Replaces style tags in the message text with custom tags with encoded content. * @param {string} text * @returns {string} Encoded message text * @copyright https://github.com/kwaroran/risuAI */ export declare function encodeStyleTags(text: string): string; /** * Sanitizes custom style tags in the message text to prevent DOM pollution. * @param {string} text Message text * @param {object} options Options object * @param {string} options.prefix Prefix the selectors with this value * @returns {string} Sanitized message text * @copyright https://github.com/kwaroran/risuAI */ export declare function decodeStyleTags(text: string, { prefix }?: { prefix: string; }): string; export declare const markdownUnderscoreExt: () => { type: string; regex: RegExp; replace: (match: string, tagContent: string, italicContent: string) => string; }[]; /** * @enum {number} Where the regex script should be applied */ /** * Formats the message text into an HTML string using Markdown and other formatting. * @param {string} mes Message text * @param {string} ch_name Character name * @param {boolean} isSystem If the message was sent by the system * @param {boolean} isUser If the message was sent by the user * @param {number} messageId Message index in chat array * @param {object} [sanitizerOverrides] DOMPurify sanitizer option overrides * @param {boolean} [isReasoning] If the message is reasoning output * @returns {string} HTML string */ export declare function messageFormatting(mes: any, sanitizerOverrides?: any): any;