Merge remote-tracking branch 'upstream/main'

This commit is contained in:
2026-08-26 09:31:34 +08:00
parent 9b8c4bfab6
commit 394eb0285d
34137 changed files with 3589424 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
import Quill from '../core/quill.js';
import Module from '../core/module.js';
import type { Range } from '../core/selection.js';
type Handler = (this: Toolbar, value: any) => void;
export type ToolbarConfig = Array<string[] | Array<string | Record<string, unknown>>>;
export interface ToolbarProps {
container?: HTMLElement | ToolbarConfig | null;
handlers?: Record<string, Handler>;
option?: number;
module?: boolean;
theme?: boolean;
}
declare class Toolbar extends Module<ToolbarProps> {
static DEFAULTS: ToolbarProps;
container?: HTMLElement | null;
controls: [string, HTMLElement][];
handlers: Record<string, Handler>;
constructor(quill: Quill, options: Partial<ToolbarProps>);
addHandler(format: string, handler: Handler): void;
attach(input: HTMLElement): void;
update(range: Range | null): void;
}
declare function addControls(container: HTMLElement, groups: (string | Record<string, unknown>)[][] | (string | Record<string, unknown>)[]): void;
export { Toolbar as default, addControls };