Skip to content

Commit

Permalink
Fix Toolbar Handler type (#3730)
Browse files Browse the repository at this point in the history
Handlers are called with a format-dependent [`value`][1].

This change updates the `Handler` type to allow passing a value.

[1]: https://github.com/quilljs/quill/blob/d2f689fb4744cdada96c632a8bccf6d476932d7b/modules/toolbar.ts#L106
  • Loading branch information
alecgibson authored Apr 20, 2023
1 parent 2165cf1 commit bfb5845
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/toolbar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import Module from '../core/module';

const debug = logger('quill:toolbar');

type Handler = () => void;
type Handler = (value: any) => void;

interface ToolbarProps {
container: HTMLElement;
Expand Down

0 comments on commit bfb5845

Please sign in to comment.