mirror of
https://github.com/zadam/trilium.git
synced 2025-12-04 22:44:25 +01:00
Compare commits
3 Commits
29b1cfd978
...
f85d0bdf90
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f85d0bdf90 | ||
|
|
2163334c4f | ||
|
|
f5d180af6b |
@ -1012,7 +1012,7 @@ div[data-notify="container"] {
|
||||
|
||||
svg.ck-icon {
|
||||
&.ck-icon_inherit-color {
|
||||
* {
|
||||
path {
|
||||
fill: currentColor;
|
||||
}
|
||||
}
|
||||
|
||||
@ -37,12 +37,21 @@ export default function MarkdownImportDialog() {
|
||||
return (
|
||||
<Modal
|
||||
className="markdown-import-dialog" title={t("markdown_import.dialog_title")} size="lg"
|
||||
footer={<Button className="markdown-import-button" text={t("markdown_import.import_button")} onClick={() => setShown(false)} keyboardShortcut="Ctrl+Enter" />}
|
||||
footer={
|
||||
<Button
|
||||
className="markdown-import-button"
|
||||
text={t("markdown_import.import_button")}
|
||||
keyboardShortcut="Ctrl+Enter"
|
||||
onClick={async () => {
|
||||
setShown(false);
|
||||
if (editorApiRef.current) {
|
||||
await convertMarkdownToHtml(text, editorApiRef.current);
|
||||
}
|
||||
}}
|
||||
/>
|
||||
}
|
||||
onShown={() => markdownImportTextArea.current?.focus()}
|
||||
onHidden={async () => {
|
||||
if (editorApiRef.current) {
|
||||
await convertMarkdownToHtml(text, editorApiRef.current);
|
||||
}
|
||||
onHidden={() => {
|
||||
setShown(false);
|
||||
setText("");
|
||||
}}
|
||||
@ -56,6 +65,9 @@ export default function MarkdownImportDialog() {
|
||||
if (e.key === "Enter" && e.ctrlKey) {
|
||||
e.preventDefault();
|
||||
setShown(false);
|
||||
if (editorApiRef.current) {
|
||||
convertMarkdownToHtml(text, editorApiRef.current);
|
||||
}
|
||||
}
|
||||
}}></textarea>
|
||||
</Modal>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user