refactor plugins to be functions instead of classes

This commit is contained in:
Jacky Zhao committed 2023-06-11 23:26:43 -07:00
1 parent b8c011410d
commit 352075ae81
20 files changed
+464 -507

No files matched your search

+2 -1
View File
@@ -10,7 +10,6 @@ export type QuartzComponentProps = {
cfg: GlobalConfiguration
children: QuartzComponent[] | JSX.Element[]
tree: Node<QuartzPluginData>
position?: 'sidebar' | 'header' | 'body'
}
export type QuartzComponent = ComponentType<QuartzComponentProps> & {
@@ -18,3 +17,5 @@ export type QuartzComponent = ComponentType<QuartzComponentProps> & {
beforeDOMLoaded?: string,
afterDOMLoaded?: string,
}
export type QuartzComponentConstructor<Options extends object> = (opts: Options) => QuartzComponent