mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-17 17:36:08 +08:00
ui: simply solve a eslint bug
This commit is contained in:
1 parent
f4dbce5a76
commit
67f8c8d389
2 files changed
+6
-2
No files matched your search
@@ -25,6 +25,8 @@ function buildSequence(pages, type) {
|
||||
throw new Error("'type' should be one of 'before' or 'after'");
|
||||
}
|
||||
}
|
||||
// eslint bug
|
||||
// eslint-disable-next-line react/jsx-indent
|
||||
return pages
|
||||
.filter((p) => p && p[`${type}Loading`])
|
||||
.map((p) => ({
|
||||
|
||||
@@ -172,9 +172,11 @@ export default new NamedPage(['problem_create', 'problem_edit'], (pagename) => {
|
||||
|
||||
setInterval(() => {
|
||||
$('img').each(function () {
|
||||
if (this.src.startsWith('file://')) this.setAttribute('src', this.src.replace('file://', './file/'));
|
||||
if (this.src.startsWith('file://')) {
|
||||
this.setAttribute('src', this.src.replace('file://', './file/').replace(/\/$/, ''));
|
||||
}
|
||||
});
|
||||
}, 200);
|
||||
}, 500);
|
||||
|
||||
const $main = $('textarea[data-editor]');
|
||||
const $field = $('textarea[data-markdown-upload]');
|
||||
|
||||
Reference in new issue
Block a user