mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-23 18:10:12 +01:00
🚨
This commit is contained in:
parent
e9fae295bf
commit
c19109cb45
4 changed files with 3 additions and 6 deletions
|
|
@ -6,7 +6,6 @@ import {confirmDialog} from "../dialog/confirmDialog";
|
||||||
import {highlightRender} from "../protyle/markdown/highlightRender";
|
import {highlightRender} from "../protyle/markdown/highlightRender";
|
||||||
import {exportLayout} from "../layout/util";
|
import {exportLayout} from "../layout/util";
|
||||||
import {Constants} from "../constants";
|
import {Constants} from "../constants";
|
||||||
import {loadAssets} from "../util/assets";
|
|
||||||
|
|
||||||
export const bazaar = {
|
export const bazaar = {
|
||||||
element: undefined as Element,
|
element: undefined as Element,
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,6 @@ import {setEditMode} from "../protyle/util/setEditMode";
|
||||||
import {Files} from "../layout/dock/Files";
|
import {Files} from "../layout/dock/Files";
|
||||||
import {setPadding} from "../protyle/ui/initUI";
|
import {setPadding} from "../protyle/ui/initUI";
|
||||||
import {fetchPost} from "../util/fetch";
|
import {fetchPost} from "../util/fetch";
|
||||||
import {showMessage} from "../dialog/message";
|
|
||||||
import {focusBlock, focusByRange} from "../protyle/util/selection";
|
import {focusBlock, focusByRange} from "../protyle/util/selection";
|
||||||
import {onGet} from "../protyle/util/onGet";
|
import {onGet} from "../protyle/util/onGet";
|
||||||
/// #if !BROWSER
|
/// #if !BROWSER
|
||||||
|
|
|
||||||
|
|
@ -510,7 +510,7 @@ export const imgMenu = (protyle: IProtyle, range: Range, assetElement: HTMLEleme
|
||||||
}
|
}
|
||||||
}).element);
|
}).element);
|
||||||
window.siyuan.menus.menu.append(new MenuItem({type: "separator"}).element);
|
window.siyuan.menus.menu.append(new MenuItem({type: "separator"}).element);
|
||||||
const imagePath = imgElement.getAttribute("data-src")
|
const imagePath = imgElement.getAttribute("data-src");
|
||||||
if (imagePath.startsWith("assets/")) {
|
if (imagePath.startsWith("assets/")) {
|
||||||
window.siyuan.menus.menu.append(new MenuItem({
|
window.siyuan.menus.menu.append(new MenuItem({
|
||||||
label: window.siyuan.languages.rename,
|
label: window.siyuan.languages.rename,
|
||||||
|
|
@ -816,14 +816,14 @@ export const videoMenu = (protyle: IProtyle, nodeElement: Element, type: string)
|
||||||
}, {
|
}, {
|
||||||
type: "separator"
|
type: "separator"
|
||||||
}];
|
}];
|
||||||
const src = videoElement.getAttribute("src")
|
const src = videoElement.getAttribute("src");
|
||||||
if (src.startsWith("assets/")) {
|
if (src.startsWith("assets/")) {
|
||||||
subMenus.push({
|
subMenus.push({
|
||||||
label: window.siyuan.languages.rename,
|
label: window.siyuan.languages.rename,
|
||||||
click() {
|
click() {
|
||||||
renameAsset(src);
|
renameAsset(src);
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
return subMenus.concat(openMenu(videoElement.getAttribute("src"), true) as IMenu[]);
|
return subMenus.concat(openMenu(videoElement.getAttribute("src"), true) as IMenu[]);
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,6 @@ import {setEditor} from "./util/setEmpty";
|
||||||
import {closePanel} from "./util/closePanel";
|
import {closePanel} from "./util/closePanel";
|
||||||
import {Constants} from "../constants";
|
import {Constants} from "../constants";
|
||||||
import {fetchPost} from "../util/fetch";
|
import {fetchPost} from "../util/fetch";
|
||||||
import {showMessage} from "../dialog/message";
|
|
||||||
import {disabledProtyle, enableProtyle, onGet} from "../protyle/util/onGet";
|
import {disabledProtyle, enableProtyle, onGet} from "../protyle/util/onGet";
|
||||||
import {addLoading} from "../protyle/ui/initUI";
|
import {addLoading} from "../protyle/ui/initUI";
|
||||||
import {focusBlock} from "../protyle/util/selection";
|
import {focusBlock} from "../protyle/util/selection";
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue