Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(type): type error in config #839

Merged
merged 10 commits into from
Aug 14, 2024
Prev Previous commit
Next Next commit
fix: add type onExpandCode onUnExpandCode
  • Loading branch information
RSS1102 committed Aug 7, 2024
commit 09fda94992d04f93e3484d6cc7b42f0229fc207b
2 changes: 2 additions & 0 deletions types/cherry.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ export interface _CherryOptions<T extends CherryCustomOptions = CherryCustomOpti
onCopyCode?: (e: ClipboardEvent, code: string) => string | false;
changeString2Pinyin?: (str: string) => string;
onPaste?: (clipboardData: ClipboardEvent['clipboardData']) => string | boolean;
onExpandCode?: (e: MouseEvent, code: string) => string;
onUnExpandCode?: (e: MouseEvent, code: string) => string;
};
event: {
focus?: ({ e: MouseEvent, cherry: Cherry }) => void;
Expand Down
Loading