Update notebook styling

This commit is contained in:
Jackson Harper
2023-06-22 17:40:29 +08:00
parent b1a7fc8488
commit b0b7bf5dcc
4 changed files with 352 additions and 2 deletions

View File

@ -0,0 +1,33 @@
import { Disc, FloppyDisk } from 'phosphor-react'
import { PluginComponent, PluginProps } from 'react-markdown-editor-lite'
import { SpanBox } from '../elements/LayoutPrimitives'
import { Button } from '../elements/Button'
export default class MDEditorSavePlugin extends PluginComponent {
static pluginName = 'save'
static align = 'right'
constructor(props: any) {
super(props)
this.handleClick = this.handleClick.bind(this)
}
private handleClick() {}
render() {
return (
<Button
style="plainIcon"
css={{ display: 'flex', pr: '5px' }}
onClick={(event) => {
document.dispatchEvent(new Event('saveMarkdownNote'))
event.preventDefault()
}}
>
<FloppyDisk size={18} weight="bold" color="#757575" />
</Button>
)
}
}