import { Slice } from '@tiptap/pm/model';
import { EditorState } from '@tiptap/pm/state';
import { Voice } from '../../../types/src/text-to-speech';
import { LocalizeController } from '../../../utils/src/custom-element/i18n';
import { RATE } from './text-to-speech.constants';

export declare const standardizeSSML: (str: string) => string;
export declare function splitLanguageCodes(fullName: string, languageCodes: string[]): string;
export declare function getVoiceLabel(voice: Voice): string;
/**
 * Standardizes a given slice by removing unsupported marks (italic, underline,...),
 * converting bold marks to emphasis marks,
 * removing empty textStyle marks, removing rate attributes from prosody marks,
 * and clearing unsupported nodes (li, ul, ol).
 *
 * @param slice - The slice to be standardized.
 * @param state - The current editor state.
 * @param unsupportedSsmlTags - The list of unsupported SSML tags for the current voice.
 * @returns A new standardized slice with unsupported nodes and marks cleared.
 */
export declare function standardizeSlice(slice: Slice, state: EditorState, unsupportedSsmlTags?: string[]): Slice;
/**
 * Converts a ProseMirror `Slice` into an HTML string representation.
 *
 * @param slice - The ProseMirror `Slice` object to be converted.
 * @param state - The current ProseMirror `EditorState` containing the schema for serialization.
 * @param textOnly - Optional flag indicating whether to return only the text content
 *                   (default is `false`, which returns the full HTML content).
 * @returns A string containing the HTML or text representation of the slice.
 */
export declare function sliceToHTML(slice: Slice, state: EditorState, textOnly?: boolean): string;
/**
 * Calculates the character overhead added by formatBeforeSaving wrapper tags.
 * Use this to adjust characterLimit before calling limitContentLength.
 *
 * @param speed - The speed value (e.g., '100%', '200%', 'x-fast')
 * @returns The number of characters added by the wrapper tags
 */
export declare function getFormatOverhead(speed: string): number;
export declare function formatBeforeSaving(content: string, speed: string): string;
export declare function extractSpeed(content: string): {
    speed: RATE;
    text: string;
};
export declare function formatTime(seconds: number): string;
export declare function getVoiceHelpText(unsupportedSsmlTags: string[], localizeController: LocalizeController): string;
export declare function getCssVariable(variable: string): any;
export declare const limitContentLength: ({ characterLimit, slice, state, }: {
    characterLimit: number;
    slice: Slice;
    state: EditorState;
}) => Slice;
