diff --git a/apps/client/src/widgets/collections/NoteList.tsx b/apps/client/src/widgets/collections/NoteList.tsx index 98d9a3feb..63eb64a99 100644 --- a/apps/client/src/widgets/collections/NoteList.tsx +++ b/apps/client/src/widgets/collections/NoteList.tsx @@ -123,7 +123,6 @@ function useNoteIds(note: FNote | null | undefined, viewType: ViewTypeOptions | } async function getNoteIds(note: FNote) { - console.log("Refreshed note IDs"); if (viewType === "list" || viewType === "grid") { return note.getChildNoteIds(); } else { diff --git a/apps/client/src/widgets/collections/geomap/map.tsx b/apps/client/src/widgets/collections/geomap/map.tsx index faf2ec654..da9c2173b 100644 --- a/apps/client/src/widgets/collections/geomap/map.tsx +++ b/apps/client/src/widgets/collections/geomap/map.tsx @@ -68,7 +68,6 @@ export default function Map({ coordinates, zoom, layerName, viewportChanged, chi useEffect(() => { const map = mapRef.current; const layerToAdd = layer; - console.log("Add layer ", map, layerToAdd); if (!map || !layerToAdd) return; layerToAdd.addTo(map); return () => layerToAdd.removeFrom(map); diff --git a/apps/client/src/widgets/ribbon/components/AttributeEditor.tsx b/apps/client/src/widgets/ribbon/components/AttributeEditor.tsx index 08241f931..32cae708b 100644 --- a/apps/client/src/widgets/ribbon/components/AttributeEditor.tsx +++ b/apps/client/src/widgets/ribbon/components/AttributeEditor.tsx @@ -132,7 +132,7 @@ export default function AttributeEditor({ api, note, componentId, notePath, ntxI if (htmlAttrs.length > 0) { htmlAttrs += " "; - } + } editorRef.current?.setText(htmlAttrs); setCurrentValue(htmlAttrs); @@ -233,7 +233,6 @@ export default function AttributeEditor({ api, note, componentId, notePath, ntxI useEffect(() => refresh(), [ note ]); useTriliumEvent("entitiesReloaded", ({ loadResults }) => { if (loadResults.getAttributeRows(componentId).find((attr) => attributes.isAffecting(attr, note))) { - console.log("Trigger due to entities reloaded"); refresh(); } }); @@ -262,8 +261,8 @@ export default function AttributeEditor({ api, note, componentId, notePath, ntxI } return result?.note?.getBestNotePathString(); - } - }), [ notePath ])); + } + }), [ notePath ])); // Keyboard shortcuts useTriliumEvent("addNewLabel", ({ ntxId: eventNtxId }) => { @@ -281,7 +280,7 @@ export default function AttributeEditor({ api, note, componentId, notePath, ntxI refresh, renderOwnedAttributes: (attributes) => renderOwnedAttributes(attributes as FAttribute[], false) }), [ save, refresh, renderOwnedAttributes ]); - + return ( <> {!hidden &&
save(), 100); @@ -313,9 +312,9 @@ export default function AttributeEditor({ api, note, componentId, notePath, ntxI }} onChange={(currentValue) => { currentValueRef.current = currentValue ?? ""; - + const oldValue = getPreprocessedData(lastSavedContent.current ?? "").trimEnd(); - const newValue = getPreprocessedData(currentValue ?? "").trimEnd(); + const newValue = getPreprocessedData(currentValue ?? "").trimEnd(); setNeedsSaving(oldValue !== newValue); setError(undefined); }} @@ -351,7 +350,7 @@ export default function AttributeEditor({ api, note, componentId, notePath, ntxI x: e.pageX, y: e.pageY }); - setState("showAttributeDetail"); + setState("showAttributeDetail"); } else { setState("showHelpTooltip"); } @@ -373,7 +372,7 @@ export default function AttributeEditor({ api, note, componentId, notePath, ntxI onClick={save} /> } - - ) + ) } function getPreprocessedData(currentValue: string) {