import type { ContentModelSegmentFormat, FormatContentModelContext, IEditor, ReadonlyContentModelDocument, ShallowMutableContentModelParagraph, ShallowMutableContentModelSegment } from 'roosterjs-content-model-types'; /** * Invoke a callback to format the selected segment using Content Model * @param editor The editor object * @param apiName Name of API this calling this function. This is mostly for logging. * @param toggleStyleCallback The callback to format the segment. It will be called with current selected table. If no table is selected, it will not be called. * @param segmentHasStyleCallback The callback used for checking if the given segment already has required format * @param includingFormatHolder True to also include format holder of list item when search selected segments * @param afterFormatCallback A callback to invoke after format is applied to all selected segments and before the change is applied to DOM tree */ export declare function formatSegmentWithContentModel(editor: IEditor, apiName: string, toggleStyleCallback: (format: ContentModelSegmentFormat, isTuringOn: boolean, segment: ShallowMutableContentModelSegment | null, paragraph: ShallowMutableContentModelParagraph | null) => void, segmentHasStyleCallback?: (format: ContentModelSegmentFormat, segment: ShallowMutableContentModelSegment | null, paragraph: ShallowMutableContentModelParagraph | null) => boolean, includingFormatHolder?: boolean, afterFormatCallback?: (model: ReadonlyContentModelDocument, isTurningOff: boolean, context: FormatContentModelContext) => void): void;