import type { BlockService } from '@blockeditor/block-std'; import { Slot } from '@blockeditor/global/utils'; import { z } from 'zod'; import { LineWidth, NoteDisplayMode } from '../../_common/types.js'; import { CanvasTextFontFamily, CanvasTextFontStyle, CanvasTextFontWeight, ShapeStyle, StrokeStyle } from '../consts.js'; import type { EdgelessElementType } from '../edgeless-types.js'; import { ConnectorEndpointStyle } from '../elements/connector/types.js'; import { TextAlign, TextVerticalAlign } from '../elements/consts.js'; import { SHAPE_TEXT_FONT_SIZE, ShapeType } from '../elements/shape/consts.js'; declare const LastPropsSchema: z.ZodObject<{ connector: z.ZodObject<{ frontEndpointStyle: z.ZodNativeEnum; rearEndpointStyle: z.ZodNativeEnum; strokeStyle: z.ZodNativeEnum; stroke: z.ZodUnion<[z.ZodLiteral<"--affine-palette-line-yellow">, z.ZodLiteral<"--affine-palette-line-orange">, z.ZodLiteral<"--affine-palette-line-tangerine">, z.ZodLiteral<"--affine-palette-line-red">, z.ZodLiteral<"--affine-palette-line-magenta">, z.ZodLiteral<"--affine-palette-line-purple">, z.ZodLiteral<"--affine-palette-line-green">, z.ZodLiteral<"--affine-palette-line-blue">, z.ZodLiteral<"--affine-palette-line-navy">, z.ZodLiteral<"--affine-palette-line-black">, z.ZodLiteral<"--affine-palette-line-grey">, z.ZodLiteral<"--affine-palette-line-white">]>; strokeWidth: z.ZodNativeEnum; rough: z.ZodBoolean; mode: z.ZodOptional; }, "strip", z.ZodTypeAny, { stroke: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; strokeWidth: LineWidth; strokeStyle: StrokeStyle; rough: boolean; frontEndpointStyle: ConnectorEndpointStyle; rearEndpointStyle: ConnectorEndpointStyle; mode?: number | undefined; }, { stroke: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; strokeWidth: LineWidth; strokeStyle: StrokeStyle; rough: boolean; frontEndpointStyle: ConnectorEndpointStyle; rearEndpointStyle: ConnectorEndpointStyle; mode?: number | undefined; }>; brush: z.ZodObject<{ color: z.ZodUnion<[z.ZodLiteral<"--affine-palette-line-yellow">, z.ZodLiteral<"--affine-palette-line-orange">, z.ZodLiteral<"--affine-palette-line-tangerine">, z.ZodLiteral<"--affine-palette-line-red">, z.ZodLiteral<"--affine-palette-line-magenta">, z.ZodLiteral<"--affine-palette-line-purple">, z.ZodLiteral<"--affine-palette-line-green">, z.ZodLiteral<"--affine-palette-line-blue">, z.ZodLiteral<"--affine-palette-line-navy">, z.ZodLiteral<"--affine-palette-line-black">, z.ZodLiteral<"--affine-palette-line-grey">, z.ZodLiteral<"--affine-palette-line-white">]>; lineWidth: z.ZodNativeEnum; }, "strip", z.ZodTypeAny, { color: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; lineWidth: LineWidth; }, { color: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; lineWidth: LineWidth; }>; shape: z.ZodObject<{ shapeType: z.ZodNativeEnum; fillColor: z.ZodUnion<[z.ZodLiteral<"--affine-palette-shape-yellow">, z.ZodLiteral<"--affine-palette-shape-orange">, z.ZodLiteral<"--affine-palette-shape-tangerine">, z.ZodLiteral<"--affine-palette-shape-red">, z.ZodLiteral<"--affine-palette-shape-magenta">, z.ZodLiteral<"--affine-palette-shape-purple">, z.ZodLiteral<"--affine-palette-shape-green">, z.ZodLiteral<"--affine-palette-shape-blue">, z.ZodLiteral<"--affine-palette-shape-navy">, z.ZodLiteral<"--affine-palette-shape-black">, z.ZodLiteral<"--affine-palette-shape-white">, z.ZodLiteral<"--affine-palette-transparent">]>; strokeColor: z.ZodUnion<[z.ZodLiteral<"--affine-palette-line-yellow">, z.ZodLiteral<"--affine-palette-line-orange">, z.ZodLiteral<"--affine-palette-line-tangerine">, z.ZodLiteral<"--affine-palette-line-red">, z.ZodLiteral<"--affine-palette-line-magenta">, z.ZodLiteral<"--affine-palette-line-purple">, z.ZodLiteral<"--affine-palette-line-green">, z.ZodLiteral<"--affine-palette-line-blue">, z.ZodLiteral<"--affine-palette-line-navy">, z.ZodLiteral<"--affine-palette-line-black">, z.ZodLiteral<"--affine-palette-line-white">, z.ZodLiteral<"--affine-palette-transparent">]>; shapeStyle: z.ZodNativeEnum; filled: z.ZodBoolean; radius: z.ZodNumber; strokeWidth: z.ZodOptional; strokeStyle: z.ZodOptional>; color: z.ZodOptional; fontSize: z.ZodOptional>; fontFamily: z.ZodOptional>; fontWeight: z.ZodOptional>; fontStyle: z.ZodOptional>; textAlign: z.ZodOptional>; textHorizontalAlign: z.ZodOptional>; textVerticalAlign: z.ZodOptional>; }, "strip", z.ZodTypeAny, { shapeStyle: ShapeStyle; shapeType: ShapeType; fillColor: "--affine-palette-shape-yellow" | "--affine-palette-shape-orange" | "--affine-palette-shape-tangerine" | "--affine-palette-shape-red" | "--affine-palette-shape-magenta" | "--affine-palette-shape-purple" | "--affine-palette-shape-navy" | "--affine-palette-shape-blue" | "--affine-palette-shape-green" | "--affine-palette-shape-white" | "--affine-palette-shape-black" | "--affine-palette-transparent"; strokeColor: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-transparent"; radius: number; filled: boolean; strokeWidth?: number | undefined; strokeStyle?: StrokeStyle | undefined; color?: string | undefined; fontSize?: SHAPE_TEXT_FONT_SIZE | undefined; fontFamily?: CanvasTextFontFamily | undefined; fontWeight?: CanvasTextFontWeight | undefined; fontStyle?: CanvasTextFontStyle | undefined; textAlign?: TextAlign | undefined; textHorizontalAlign?: TextAlign | undefined; textVerticalAlign?: TextVerticalAlign | undefined; }, { shapeStyle: ShapeStyle; shapeType: ShapeType; fillColor: "--affine-palette-shape-yellow" | "--affine-palette-shape-orange" | "--affine-palette-shape-tangerine" | "--affine-palette-shape-red" | "--affine-palette-shape-magenta" | "--affine-palette-shape-purple" | "--affine-palette-shape-navy" | "--affine-palette-shape-blue" | "--affine-palette-shape-green" | "--affine-palette-shape-white" | "--affine-palette-shape-black" | "--affine-palette-transparent"; strokeColor: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-transparent"; radius: number; filled: boolean; strokeWidth?: number | undefined; strokeStyle?: StrokeStyle | undefined; color?: string | undefined; fontSize?: SHAPE_TEXT_FONT_SIZE | undefined; fontFamily?: CanvasTextFontFamily | undefined; fontWeight?: CanvasTextFontWeight | undefined; fontStyle?: CanvasTextFontStyle | undefined; textAlign?: TextAlign | undefined; textHorizontalAlign?: TextAlign | undefined; textVerticalAlign?: TextVerticalAlign | undefined; }>; text: z.ZodObject<{ color: z.ZodString; fontFamily: z.ZodNativeEnum; textAlign: z.ZodNativeEnum; fontWeight: z.ZodNativeEnum; fontStyle: z.ZodNativeEnum; fontSize: z.ZodNumber; hasMaxWidth: z.ZodBoolean; }, "strip", z.ZodTypeAny, { color: string; fontSize: number; fontFamily: CanvasTextFontFamily; fontWeight: CanvasTextFontWeight; fontStyle: CanvasTextFontStyle; textAlign: TextAlign; hasMaxWidth: boolean; }, { color: string; fontSize: number; fontFamily: CanvasTextFontFamily; fontWeight: CanvasTextFontWeight; fontStyle: CanvasTextFontStyle; textAlign: TextAlign; hasMaxWidth: boolean; }>; 'affine:note': z.ZodObject<{ background: z.ZodUnion<[z.ZodLiteral<"--affine-background-secondary-color">, z.ZodLiteral<"--affine-tag-yellow">, z.ZodLiteral<"--affine-tag-red">, z.ZodLiteral<"--affine-tag-green">, z.ZodLiteral<"--affine-tag-blue">, z.ZodLiteral<"--affine-tag-purple">]>; displayMode: z.ZodOptional>; edgeless: z.ZodObject<{ style: z.ZodObject<{ borderRadius: z.ZodNumber; borderSize: z.ZodNumber; borderStyle: z.ZodNativeEnum; shadowType: z.ZodUnion<[z.ZodLiteral<"">, z.ZodLiteral<"--affine-note-shadow-box">, z.ZodLiteral<"--affine-note-shadow-sticker">, z.ZodLiteral<"--affine-note-shadow-paper">, z.ZodLiteral<"--affine-note-shadow-float">, z.ZodLiteral<"--affine-note-shadow-film">]>; }, "strip", z.ZodTypeAny, { borderRadius: number; borderSize: number; borderStyle: StrokeStyle; shadowType: "" | "--affine-note-shadow-box" | "--affine-note-shadow-sticker" | "--affine-note-shadow-paper" | "--affine-note-shadow-float" | "--affine-note-shadow-film"; }, { borderRadius: number; borderSize: number; borderStyle: StrokeStyle; shadowType: "" | "--affine-note-shadow-box" | "--affine-note-shadow-sticker" | "--affine-note-shadow-paper" | "--affine-note-shadow-float" | "--affine-note-shadow-film"; }>; }, "strip", z.ZodTypeAny, { style: { borderRadius: number; borderSize: number; borderStyle: StrokeStyle; shadowType: "" | "--affine-note-shadow-box" | "--affine-note-shadow-sticker" | "--affine-note-shadow-paper" | "--affine-note-shadow-float" | "--affine-note-shadow-film"; }; }, { style: { borderRadius: number; borderSize: number; borderStyle: StrokeStyle; shadowType: "" | "--affine-note-shadow-box" | "--affine-note-shadow-sticker" | "--affine-note-shadow-paper" | "--affine-note-shadow-float" | "--affine-note-shadow-film"; }; }>; }, "strip", z.ZodTypeAny, { background: "--affine-background-secondary-color" | "--affine-tag-blue" | "--affine-tag-green" | "--affine-tag-purple" | "--affine-tag-red" | "--affine-tag-yellow"; edgeless: { style: { borderRadius: number; borderSize: number; borderStyle: StrokeStyle; shadowType: "" | "--affine-note-shadow-box" | "--affine-note-shadow-sticker" | "--affine-note-shadow-paper" | "--affine-note-shadow-float" | "--affine-note-shadow-film"; }; }; displayMode?: NoteDisplayMode | undefined; }, { background: "--affine-background-secondary-color" | "--affine-tag-blue" | "--affine-tag-green" | "--affine-tag-purple" | "--affine-tag-red" | "--affine-tag-yellow"; edgeless: { style: { borderRadius: number; borderSize: number; borderStyle: StrokeStyle; shadowType: "" | "--affine-note-shadow-box" | "--affine-note-shadow-sticker" | "--affine-note-shadow-paper" | "--affine-note-shadow-float" | "--affine-note-shadow-film"; }; }; displayMode?: NoteDisplayMode | undefined; }>; }, "strip", z.ZodTypeAny, { text: { color: string; fontSize: number; fontFamily: CanvasTextFontFamily; fontWeight: CanvasTextFontWeight; fontStyle: CanvasTextFontStyle; textAlign: TextAlign; hasMaxWidth: boolean; }; 'affine:note': { background: "--affine-background-secondary-color" | "--affine-tag-blue" | "--affine-tag-green" | "--affine-tag-purple" | "--affine-tag-red" | "--affine-tag-yellow"; edgeless: { style: { borderRadius: number; borderSize: number; borderStyle: StrokeStyle; shadowType: "" | "--affine-note-shadow-box" | "--affine-note-shadow-sticker" | "--affine-note-shadow-paper" | "--affine-note-shadow-float" | "--affine-note-shadow-film"; }; }; displayMode?: NoteDisplayMode | undefined; }; shape: { shapeStyle: ShapeStyle; shapeType: ShapeType; fillColor: "--affine-palette-shape-yellow" | "--affine-palette-shape-orange" | "--affine-palette-shape-tangerine" | "--affine-palette-shape-red" | "--affine-palette-shape-magenta" | "--affine-palette-shape-purple" | "--affine-palette-shape-navy" | "--affine-palette-shape-blue" | "--affine-palette-shape-green" | "--affine-palette-shape-white" | "--affine-palette-shape-black" | "--affine-palette-transparent"; strokeColor: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-transparent"; radius: number; filled: boolean; strokeWidth?: number | undefined; strokeStyle?: StrokeStyle | undefined; color?: string | undefined; fontSize?: SHAPE_TEXT_FONT_SIZE | undefined; fontFamily?: CanvasTextFontFamily | undefined; fontWeight?: CanvasTextFontWeight | undefined; fontStyle?: CanvasTextFontStyle | undefined; textAlign?: TextAlign | undefined; textHorizontalAlign?: TextAlign | undefined; textVerticalAlign?: TextVerticalAlign | undefined; }; brush: { color: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; lineWidth: LineWidth; }; connector: { stroke: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; strokeWidth: LineWidth; strokeStyle: StrokeStyle; rough: boolean; frontEndpointStyle: ConnectorEndpointStyle; rearEndpointStyle: ConnectorEndpointStyle; mode?: number | undefined; }; }, { text: { color: string; fontSize: number; fontFamily: CanvasTextFontFamily; fontWeight: CanvasTextFontWeight; fontStyle: CanvasTextFontStyle; textAlign: TextAlign; hasMaxWidth: boolean; }; 'affine:note': { background: "--affine-background-secondary-color" | "--affine-tag-blue" | "--affine-tag-green" | "--affine-tag-purple" | "--affine-tag-red" | "--affine-tag-yellow"; edgeless: { style: { borderRadius: number; borderSize: number; borderStyle: StrokeStyle; shadowType: "" | "--affine-note-shadow-box" | "--affine-note-shadow-sticker" | "--affine-note-shadow-paper" | "--affine-note-shadow-float" | "--affine-note-shadow-film"; }; }; displayMode?: NoteDisplayMode | undefined; }; shape: { shapeStyle: ShapeStyle; shapeType: ShapeType; fillColor: "--affine-palette-shape-yellow" | "--affine-palette-shape-orange" | "--affine-palette-shape-tangerine" | "--affine-palette-shape-red" | "--affine-palette-shape-magenta" | "--affine-palette-shape-purple" | "--affine-palette-shape-navy" | "--affine-palette-shape-blue" | "--affine-palette-shape-green" | "--affine-palette-shape-white" | "--affine-palette-shape-black" | "--affine-palette-transparent"; strokeColor: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-transparent"; radius: number; filled: boolean; strokeWidth?: number | undefined; strokeStyle?: StrokeStyle | undefined; color?: string | undefined; fontSize?: SHAPE_TEXT_FONT_SIZE | undefined; fontFamily?: CanvasTextFontFamily | undefined; fontWeight?: CanvasTextFontWeight | undefined; fontStyle?: CanvasTextFontStyle | undefined; textAlign?: TextAlign | undefined; textHorizontalAlign?: TextAlign | undefined; textVerticalAlign?: TextVerticalAlign | undefined; }; brush: { color: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; lineWidth: LineWidth; }; connector: { stroke: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; strokeWidth: LineWidth; strokeStyle: StrokeStyle; rough: boolean; frontEndpointStyle: ConnectorEndpointStyle; rearEndpointStyle: ConnectorEndpointStyle; mode?: number | undefined; }; }>; export type LastProps = z.infer; declare const SessionPropsSchema: z.ZodObject<{ viewport: z.ZodUnion<[z.ZodObject<{ centerX: z.ZodNumber; centerY: z.ZodNumber; zoom: z.ZodNumber; }, "strip", z.ZodTypeAny, { centerX: number; zoom: number; centerY: number; }, { centerX: number; zoom: number; centerY: number; }>, z.ZodObject<{ referenceId: z.ZodString; xywh: z.ZodString; padding: z.ZodOptional>; }, "strip", z.ZodTypeAny, { xywh: string; referenceId: string; padding?: [number, number, number, number] | undefined; }, { xywh: string; referenceId: string; padding?: [number, number, number, number] | undefined; }>]>; presentBlackBackground: z.ZodBoolean; presentFillScreen: z.ZodBoolean; presentHideToolbar: z.ZodBoolean; templateCache: z.ZodString; remoteColor: z.ZodString; }, "strip", z.ZodTypeAny, { viewport: ({ centerX: number; zoom: number; centerY: number; } | { xywh: string; referenceId: string; padding?: [number, number, number, number] | undefined; }) & ({ centerX: number; zoom: number; centerY: number; } | { xywh: string; referenceId: string; padding?: [number, number, number, number] | undefined; } | undefined); remoteColor: string; presentBlackBackground: boolean; presentFillScreen: boolean; presentHideToolbar: boolean; templateCache: string; }, { viewport: ({ centerX: number; zoom: number; centerY: number; } | { xywh: string; referenceId: string; padding?: [number, number, number, number] | undefined; }) & ({ centerX: number; zoom: number; centerY: number; } | { xywh: string; referenceId: string; padding?: [number, number, number, number] | undefined; } | undefined); remoteColor: string; presentBlackBackground: boolean; presentFillScreen: boolean; presentHideToolbar: boolean; templateCache: string; }>; type SessionProps = z.infer; export type SerializedViewport = z.infer; export declare class EditSessionStorage { private _service; private _lastProps; private _disposables; slots: { lastPropsUpdated: Slot<{ type: keyof LastProps; props: Record; }>; }; constructor(_service: BlockService); getLastProps(type: T): { text: { color: string; fontSize: number; fontFamily: CanvasTextFontFamily; fontWeight: CanvasTextFontWeight; fontStyle: CanvasTextFontStyle; textAlign: TextAlign; hasMaxWidth: boolean; }; 'affine:note': { background: "--affine-background-secondary-color" | "--affine-tag-blue" | "--affine-tag-green" | "--affine-tag-purple" | "--affine-tag-red" | "--affine-tag-yellow"; edgeless: { style: { borderRadius: number; borderSize: number; borderStyle: StrokeStyle; shadowType: "" | "--affine-note-shadow-box" | "--affine-note-shadow-sticker" | "--affine-note-shadow-paper" | "--affine-note-shadow-float" | "--affine-note-shadow-film"; }; }; displayMode?: NoteDisplayMode | undefined; }; shape: { shapeStyle: ShapeStyle; shapeType: ShapeType; fillColor: "--affine-palette-shape-yellow" | "--affine-palette-shape-orange" | "--affine-palette-shape-tangerine" | "--affine-palette-shape-red" | "--affine-palette-shape-magenta" | "--affine-palette-shape-purple" | "--affine-palette-shape-navy" | "--affine-palette-shape-blue" | "--affine-palette-shape-green" | "--affine-palette-shape-white" | "--affine-palette-shape-black" | "--affine-palette-transparent"; strokeColor: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-transparent"; radius: number; filled: boolean; strokeWidth?: number | undefined; strokeStyle?: StrokeStyle | undefined; color?: string | undefined; fontSize?: SHAPE_TEXT_FONT_SIZE | undefined; fontFamily?: CanvasTextFontFamily | undefined; fontWeight?: CanvasTextFontWeight | undefined; fontStyle?: CanvasTextFontStyle | undefined; textAlign?: TextAlign | undefined; textHorizontalAlign?: TextAlign | undefined; textVerticalAlign?: TextVerticalAlign | undefined; }; brush: { color: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; lineWidth: LineWidth; }; connector: { stroke: "--affine-palette-line-yellow" | "--affine-palette-line-orange" | "--affine-palette-line-tangerine" | "--affine-palette-line-red" | "--affine-palette-line-magenta" | "--affine-palette-line-purple" | "--affine-palette-line-navy" | "--affine-palette-line-blue" | "--affine-palette-line-green" | "--affine-palette-line-white" | "--affine-palette-line-black" | "--affine-palette-line-grey"; strokeWidth: LineWidth; strokeStyle: StrokeStyle; rough: boolean; frontEndpointStyle: ConnectorEndpointStyle; rearEndpointStyle: ConnectorEndpointStyle; mode?: number | undefined; }; }[T]; record(type: EdgelessElementType, recordProps: Partial): void; apply(type: EdgelessElementType, props: Record): void; private _getKey; setItem(key: T, value: SessionProps[T]): void; getItem(key: T): { viewport: ({ centerX: number; zoom: number; centerY: number; } | { xywh: string; referenceId: string; padding?: [number, number, number, number] | undefined; }) & ({ centerX: number; zoom: number; centerY: number; } | { xywh: string; referenceId: string; padding?: [number, number, number, number] | undefined; } | undefined); remoteColor: string; presentBlackBackground: boolean; presentFillScreen: boolean; presentHideToolbar: boolean; templateCache: string; }[T] | null; dispose(): void; } export {}; //# sourceMappingURL=edit-session.d.ts.map