import type { Cell, Sheet } from '@fortune-sheet/core'; import { type SpreadsheetUnderlineStyle } from './work-spreadsheet-underline'; import { type XlsxCellStyleOrigin, type XlsxSemanticPalette } from './work-xlsx-cell-style-origin'; import { type XlsxColorResolver } from './work-xlsx-colors'; import { type XlsxRichTextRun } from './work-xlsx-rich-text-model'; export { MAX_XLSX_RICH_TEXT_CELL_CHARACTERS, MAX_XLSX_RICH_TEXT_CELLS, MAX_XLSX_RICH_TEXT_RUNS, MAX_XLSX_RICH_TEXT_RUNS_PER_CELL, type XlsxRichTextRun, } from './work-xlsx-rich-text-model'; export interface XlsxRichTextCell { column: number; row: number; runs: XlsxRichTextRun[]; text: string; } export interface XlsxRichTextReadContext { readonly colors: XlsxColorResolver; readonly hasRichSharedStrings: boolean; readonly sharedStrings: ReadonlyMap; remainingCells: number; remainingRuns: number; } interface XlsxRichTextContextOptions { sharedStrings: Document | null; styles: Document | null; theme: Document | null; } interface SpreadsheetRichTextFontPatch { bold?: boolean; fontColor?: string; fontFamily?: string; fontSize?: number; italic?: boolean; strike?: boolean; underline?: SpreadsheetUnderlineStyle; } export declare function createXlsxRichTextReadContext(options: XlsxRichTextContextOptions): XlsxRichTextReadContext; export declare function readXlsxRichTextCells(worksheet: Document, context: XlsxRichTextReadContext): XlsxRichTextCell[]; export declare function applyImportedXlsxRichText(cell: Cell, richText: XlsxRichTextCell | undefined): Cell; export declare function patchSpreadsheetRichTextFontRuns(cell: Cell, patch: SpreadsheetRichTextFontPatch): Cell; export declare function xlsxRichTextCellText(cell: Cell): string | null; export declare function sheetHasXlsxRichTextCells(sheet: Sheet): boolean; export declare function xlsxRichTextStyleOrigins(sheet: Sheet): XlsxCellStyleOrigin[]; export declare function writeXlsxRichTextCells(worksheet: Document, sheet: Sheet, semanticPalette?: XlsxSemanticPalette): void;