mirror of
https://github.com/zadam/trilium.git
synced 2025-11-16 18:25:51 +01:00
Apply suggestions from code review
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -69,7 +69,7 @@ function removeOwnedLabelByName(note: FNote, labelName: string) {
|
||||
* @returns `true` if an attribute was identified and removed, `false` otherwise.
|
||||
*/
|
||||
function removeOwnedRelationByName(note: FNote, relationName: string) {
|
||||
const label = note.getOwnedRelation(relationName);
|
||||
const relation = note.getOwnedRelation(relationName);
|
||||
if (label) {
|
||||
removeAttributeById(note.noteId, label.attributeId);
|
||||
return true;
|
||||
|
||||
@@ -7,7 +7,7 @@ import type { EntityChange } from "../server_types.js";
|
||||
interface NoteRow {
|
||||
blobId: string;
|
||||
dateCreated: string;
|
||||
dateMOdified: string;
|
||||
dateModified: string;
|
||||
isDeleted?: boolean;
|
||||
isProtected?: boolean;
|
||||
mime: string;
|
||||
|
||||
@@ -268,7 +268,7 @@ export function TitleEditor({ currentValue, placeholder, save, dismiss, mode, is
|
||||
}
|
||||
};
|
||||
|
||||
const onBlur = (newValue) => {
|
||||
const onBlur = (newValue: string) => {
|
||||
if (!shouldDismiss.current && newValue.trim() && (newValue !== currentValue || isNewItem)) {
|
||||
save(newValue);
|
||||
dismissOnNextRefreshRef.current = true;
|
||||
@@ -311,6 +311,6 @@ export function TitleEditor({ currentValue, placeholder, save, dismiss, mode, is
|
||||
dismiss();
|
||||
}}
|
||||
/>
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user