mirror of
https://github.com/zadam/trilium.git
synced 2026-01-06 14:44:25 +01:00
chore: address requested changes
This commit is contained in:
parent
e06c004e0d
commit
b0e7b6ce67
@ -25,7 +25,7 @@ import ActionButton from "../react/ActionButton";
|
||||
import { Badge } from "../react/Badge";
|
||||
import Dropdown from "../react/Dropdown";
|
||||
import { FormDropdownDivider, FormListItem } from "../react/FormList";
|
||||
import { useActiveNoteContext, useChildNotes, useNote, useNoteColorClass, useNoteIcon, useNoteLabel, useNoteLabelBoolean, useNoteProperty, useNoteTitle, useStaticTooltip, useTriliumOptionBool } from "../react/hooks";
|
||||
import { useActiveNoteContext, useChildNotes, useNote, useNoteColorClass, useNoteIcon, useNoteLabel, useNoteLabelBoolean, useNoteTitle, useStaticTooltip, useTriliumOptionBool } from "../react/hooks";
|
||||
import Icon from "../react/Icon";
|
||||
import { NewNoteLink } from "../react/NoteLink";
|
||||
import { ParentComponent } from "../react/react_utils";
|
||||
|
||||
@ -1,10 +1,10 @@
|
||||
import clsx from "clsx";
|
||||
import { HTMLAttributes } from "preact";
|
||||
import { useEffect, useLayoutEffect, useRef, useState } from "preact/hooks";
|
||||
import { useEffect, useRef, useState } from "preact/hooks";
|
||||
|
||||
import link, { calculateHash, ViewScope } from "../../services/link";
|
||||
import tree from "../../services/tree";
|
||||
import { useImperativeSearchHighlighlighting, useNote, useNoteColorClass, useNoteIcon, useNoteLabel, useNoteLabelBoolean, useNoteProperty, useNoteTitle, useTriliumEvent } from "./hooks";
|
||||
import { useImperativeSearchHighlighlighting, useNote, useNoteColorClass, useNoteIcon, useNoteLabelBoolean, useNoteTitle, useTriliumEvent } from "./hooks";
|
||||
import Icon from "./Icon";
|
||||
|
||||
interface NoteLinkOpts {
|
||||
|
||||
@ -8,7 +8,6 @@ import { t } from "../../services/i18n";
|
||||
import server from "../../services/server";
|
||||
import { formatSize } from "../../services/utils";
|
||||
import { formatDateTime } from "../../utils/formatters";
|
||||
import Button from "../react/Button";
|
||||
import { useTriliumEvent } from "../react/hooks";
|
||||
import LinkButton from "../react/LinkButton";
|
||||
import LoadingSpinner from "../react/LoadingSpinner";
|
||||
|
||||
@ -1,5 +1,4 @@
|
||||
import type { App, BrowserWindow, BrowserWindowConstructorOptions, IpcMainEvent,WebContents } from "electron";
|
||||
import electron, { ipcMain } from "electron";
|
||||
import { type App, type BrowserWindow, type BrowserWindowConstructorOptions, default as electron, ipcMain, type IpcMainEvent, type WebContents } from "electron";
|
||||
import fs from "fs/promises";
|
||||
import { t } from "i18next";
|
||||
import path from "path";
|
||||
@ -12,7 +11,7 @@ import optionService from "./options.js";
|
||||
import port from "./port.js";
|
||||
import { RESOURCE_DIR } from "./resource_dir.js";
|
||||
import sqlInit from "./sql_init.js";
|
||||
import { formatDownloadTitle, isDev, isMac, isWindows } from "./utils.js";
|
||||
import { formatDownloadTitle, isMac, isWindows } from "./utils.js";
|
||||
|
||||
// Prevent the window being garbage collected
|
||||
let mainWindow: BrowserWindow | null;
|
||||
@ -121,14 +120,14 @@ electron.ipcMain.on("export-as-pdf", async (e, { title, notePath, landscape, pag
|
||||
</div>
|
||||
`
|
||||
});
|
||||
} catch (e) {
|
||||
} catch (_e) {
|
||||
electron.dialog.showErrorBox(t("pdf.unable-to-export-title"), t("pdf.unable-to-export-message"));
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
await fs.writeFile(filePath, buffer);
|
||||
} catch (e) {
|
||||
} catch (_e) {
|
||||
electron.dialog.showErrorBox(t("pdf.unable-to-export-title"), t("pdf.unable-to-save-message"));
|
||||
return;
|
||||
}
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
import { Autoformat, AutoLink, BlockQuote, BlockToolbar, Bold, CKFinderUploadAdapter, Clipboard, Code, CodeBlock, Enter, Font, FontBackgroundColor, FontColor, GeneralHtmlSupport, Heading, HeadingButtonsUI, HorizontalLine, Image, ImageCaption, ImageInline, ImageResize, ImageStyle, ImageToolbar, ImageUpload, Alignment, Indent, IndentBlock, Italic, Link, List, ListProperties, Mention, PageBreak, Paragraph, ParagraphButtonUI, PasteFromOffice, PictureEditing, RemoveFormat, SelectAll, ShiftEnter, SpecialCharacters, SpecialCharactersEssentials, Strikethrough, Style, Subscript, Superscript, Table, TableCaption, TableCellProperties, TableColumnResize, TableProperties, TableSelection, TableToolbar, TextPartLanguage, TextTransformation, TodoList, Typing, Underline, Undo, Bookmark, Emoji, Notification, EmojiMention, EmojiPicker, FindAndReplaceEditing } from "ckeditor5";
|
||||
import { Autoformat, AutoLink, BlockQuote, BlockToolbar, Bold, CKFinderUploadAdapter, Clipboard, Code, CodeBlock, Enter, Font, FontBackgroundColor, FontColor, GeneralHtmlSupport, Heading, HeadingButtonsUI, HorizontalLine, Image, ImageCaption, ImageInline, ImageResize, ImageStyle, ImageToolbar, ImageUpload, Alignment, Indent, IndentBlock, Italic, Link, List, ListProperties, Mention, PageBreak, Paragraph, ParagraphButtonUI, PasteFromOffice, PictureEditing, RemoveFormat, SelectAll, ShiftEnter, SpecialCharacters, SpecialCharactersEssentials, Strikethrough, Style, Subscript, Superscript, Table, TableCaption, TableCellProperties, TableColumnResize, TableProperties, TableSelection, TableToolbar, TextPartLanguage, TextTransformation, TodoList, Typing, Underline, Undo, Bookmark, EmojiMention, EmojiPicker, FindAndReplaceEditing } from "ckeditor5";
|
||||
import { SlashCommand, Template, FormatPainter } from "ckeditor5-premium-features";
|
||||
import type { Plugin } from "ckeditor5";
|
||||
import CutToNotePlugin from "./plugins/cuttonote.js";
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user