More tweak to widget rendering
This commit is contained in:
parent
7e9a3f7b6a
commit
af3e4737ba
@ -13,8 +13,8 @@ export async function setEditorMode() {
|
|||||||
export async function toggleDarkMode() {
|
export async function toggleDarkMode() {
|
||||||
let darkMode = await clientStore.get("darkMode");
|
let darkMode = await clientStore.get("darkMode");
|
||||||
darkMode = !darkMode;
|
darkMode = !darkMode;
|
||||||
await editor.setUiOption("darkMode", darkMode);
|
|
||||||
await clientStore.set("darkMode", darkMode);
|
await clientStore.set("darkMode", darkMode);
|
||||||
|
await editor.reloadUI();
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function foldCommand() {
|
export async function foldCommand() {
|
||||||
|
@ -10,6 +10,12 @@ body {
|
|||||||
display: initial !important;
|
display: initial !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#sb-root {
|
||||||
|
display: block !important;
|
||||||
|
width: initial !important;
|
||||||
|
height: initial !important;
|
||||||
|
}
|
||||||
|
|
||||||
#sb-editor {
|
#sb-editor {
|
||||||
flex: initial !important;
|
flex: initial !important;
|
||||||
height: initial !important;
|
height: initial !important;
|
||||||
@ -21,7 +27,6 @@ body {
|
|||||||
|
|
||||||
body {
|
body {
|
||||||
font-family: var(--editor-font);
|
font-family: var(--editor-font);
|
||||||
background-color: var(--root-background-color);
|
|
||||||
color: var(--root-color);
|
color: var(--root-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -27,8 +27,7 @@ export async function prepareJS(originalMarkdown: string) {
|
|||||||
`;
|
`;
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function wrapHTML( html: string
|
export async function wrapHTML(html: string): Promise<string> {
|
||||||
): Promise<string> {
|
|
||||||
const css = await asset.readAsset("assets/markdown_widget.css");
|
const css = await asset.readAsset("assets/markdown_widget.css");
|
||||||
|
|
||||||
return `
|
return `
|
||||||
|
@ -217,7 +217,7 @@ html[data-theme="dark"] {
|
|||||||
--editor-frontmatter-background-color: rgb(41, 40, 35, 0.5);
|
--editor-frontmatter-background-color: rgb(41, 40, 35, 0.5);
|
||||||
--editor-frontmatter-color: var(--subtle-color);
|
--editor-frontmatter-color: var(--subtle-color);
|
||||||
--editor-frontmatter-marker-color: #fff;
|
--editor-frontmatter-marker-color: #fff;
|
||||||
--editor-directive-background-color: rgba(72, 72, 72, 0.2);
|
--editor-directive-background-color: rgba(72, 72, 72, 0.5);
|
||||||
--editor-directive-border-color: #0000000f;
|
--editor-directive-border-color: #0000000f;
|
||||||
--editor-directive-color: #5b5b5b;
|
--editor-directive-color: #5b5b5b;
|
||||||
--editor-directive-info-color: var(--subtle-color);
|
--editor-directive-info-color: var(--subtle-color);
|
||||||
|
Loading…
Reference in New Issue
Block a user