mirror of
https://github.com/alrayyes/wiki.git
synced 2025-05-01 22:48:14 +00:00
generic quartz component for layout
This commit is contained in:
parent
dde36fa558
commit
317cce9314
11 changed files with 77 additions and 58 deletions
quartz/components
|
@ -1,6 +1,16 @@
|
|||
import { ComponentType } from "preact"
|
||||
import { ComponentType, JSX } from "preact"
|
||||
import { StaticResources } from "../resources"
|
||||
import { QuartzPluginData } from "../plugins/vfile"
|
||||
import { GlobalConfiguration } from "../cfg"
|
||||
|
||||
export type QuartzComponent<Props> = ComponentType<Props> & {
|
||||
export type QuartzComponentProps = {
|
||||
externalResources: StaticResources
|
||||
fileData: QuartzPluginData
|
||||
cfg: GlobalConfiguration
|
||||
children: QuartzComponent[] | JSX.Element[]
|
||||
}
|
||||
|
||||
export type QuartzComponent = ComponentType<QuartzComponentProps> & {
|
||||
css?: string,
|
||||
beforeDOMLoaded?: string,
|
||||
afterDOMLoaded?: string,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue