mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
🎨
This commit is contained in:
parent
0daed2d12a
commit
2ae4192392
2 changed files with 14 additions and 14 deletions
|
|
@ -199,25 +199,25 @@ export class Protyle {
|
||||||
fetchPost("/api/block/getDocInfo", {
|
fetchPost("/api/block/getDocInfo", {
|
||||||
id: options.blockId
|
id: options.blockId
|
||||||
}, (response) => {
|
}, (response) => {
|
||||||
|
let scrollObj;
|
||||||
if (response.data.ial.scroll) {
|
if (response.data.ial.scroll) {
|
||||||
let scrollObj;
|
|
||||||
try {
|
try {
|
||||||
scrollObj = JSON.parse(response.data.ial.scroll.replace(/"/g, '"'));
|
scrollObj = JSON.parse(response.data.ial.scroll.replace(/"/g, '"'));
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
scrollObj = undefined;
|
scrollObj = undefined;
|
||||||
}
|
}
|
||||||
if (scrollObj) {
|
}
|
||||||
getDocByScroll({
|
if (scrollObj) {
|
||||||
protyle: this.protyle,
|
getDocByScroll({
|
||||||
scrollAttr: scrollObj,
|
protyle: this.protyle,
|
||||||
mergedOptions,
|
scrollAttr: scrollObj,
|
||||||
cb: () => {
|
mergedOptions,
|
||||||
this.afterOnGet(mergedOptions);
|
cb: () => {
|
||||||
}
|
this.afterOnGet(mergedOptions);
|
||||||
});
|
}
|
||||||
} else {
|
});
|
||||||
this.getDoc(mergedOptions);
|
} else {
|
||||||
}
|
this.getDoc(mergedOptions);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
|
|
@ -210,7 +210,7 @@ export const setInlineStyle = (set = true) => {
|
||||||
.protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h1, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h2, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h3, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h4, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h5, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h6 {line-height:${height + 8}px;}
|
.protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h1, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h2, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h3, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h4, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h5, .protyle-wysiwyg [data-node-id].li > .protyle-action ~ .h6 {line-height:${height + 8}px;}
|
||||||
.protyle-wysiwyg [data-node-id].li > .protyle-action:after {height: ${window.siyuan.config.editor.fontSize}px;width: ${window.siyuan.config.editor.fontSize}px;margin:-${window.siyuan.config.editor.fontSize / 2}px 0 0 -${window.siyuan.config.editor.fontSize / 2}px}
|
.protyle-wysiwyg [data-node-id].li > .protyle-action:after {height: ${window.siyuan.config.editor.fontSize}px;width: ${window.siyuan.config.editor.fontSize}px;margin:-${window.siyuan.config.editor.fontSize / 2}px 0 0 -${window.siyuan.config.editor.fontSize / 2}px}
|
||||||
.protyle-wysiwyg [data-node-id].li > .protyle-action svg {height: ${Math.max(14, window.siyuan.config.editor.fontSize - 8)}px}
|
.protyle-wysiwyg [data-node-id].li > .protyle-action svg {height: ${Math.max(14, window.siyuan.config.editor.fontSize - 8)}px}
|
||||||
.protyle-wysiwyg [data-node-id].li:before {height: calc(100% - ${height + 8}px);top:${(height + 8) / 2}px}
|
.protyle-wysiwyg [data-node-id].li:before {height: calc(100% - ${height + 8}px);top:${(height + 8)}px}
|
||||||
.protyle-wysiwyg [data-node-id] [spellcheck] {min-height:${height}px;}
|
.protyle-wysiwyg [data-node-id] [spellcheck] {min-height:${height}px;}
|
||||||
.protyle-wysiwyg [data-node-id] {${window.siyuan.config.editor.rtl ? " direction: rtl;" : ""}${window.siyuan.config.editor.justify ? " text-align: justify;" : ""}}
|
.protyle-wysiwyg [data-node-id] {${window.siyuan.config.editor.rtl ? " direction: rtl;" : ""}${window.siyuan.config.editor.justify ? " text-align: justify;" : ""}}
|
||||||
.protyle-wysiwyg .li {min-height:${height + 8}px}
|
.protyle-wysiwyg .li {min-height:${height + 8}px}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue