Vanessa 2023-12-22 12:30:12 +08:00
parent badaf6ffb8
commit 33b9a6d331
18 changed files with 78 additions and 41 deletions

View file

@ -25,7 +25,7 @@ export const fetchNewDailyNote = (app: App, notebook: string) => {
export const newDailyNote = (app: App) => {
const exit = window.siyuan.dialogs.find(item => {
if (item.element.getAttribute("data-key") === window.siyuan.config.keymap.general.dailyNote.custom) {
if (item.element.getAttribute("data-key") === Constants.DIALOG_DIALYNOTE) {
item.destroy();
return true;
}
@ -74,7 +74,7 @@ export const newDailyNote = (app: App) => {
</div>`,
width: isMobile() ? "92vw" : "520px",
});
dialog.element.setAttribute("data-key", window.siyuan.config.keymap.general.dailyNote.custom);
dialog.element.setAttribute("data-key", Constants.DIALOG_DIALYNOTE);
const btnsElement = dialog.element.querySelectorAll(".b3-button");
const selectElement = dialog.element.querySelector(".b3-select") as HTMLSelectElement;
selectElement.value = localNotebookId;