From eb7164528ac72960cde9a8f0bf25d2cc50842414 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Thu, 9 Jan 2025 00:04:09 +0200 Subject: [PATCH] feat(i18n): translate note map buttons --- src/public/app/widgets/note_map.js | 32 ++++++++++----------- src/public/translations/en/translation.json | 4 ++- src/public/translations/ro/translation.json | 4 ++- 3 files changed, 22 insertions(+), 18 deletions(-) diff --git a/src/public/app/widgets/note_map.js b/src/public/app/widgets/note_map.js index e89d971c2..d5a263f41 100644 --- a/src/public/app/widgets/note_map.js +++ b/src/public/app/widgets/note_map.js @@ -16,14 +16,14 @@ const TPL = `
height: 100%; overflow: hidden; } - + .map-type-switcher { - position: absolute; - top: 10px; - left: 10px; + position: absolute; + top: 10px; + left: 10px; z-index: 10; /* should be below dropdown (note actions) */ } - + .map-type-switcher button.bx { font-size: 130%; padding: 1px 10px 1px 10px; @@ -31,8 +31,8 @@ const TPL = `
/* Style Ui Element to Drag Nodes */ .fixnodes-type-switcher { - position: absolute; - top: 10px; + position: absolute; + top: 10px; left: 45%; z-index: 10; /* should be below dropdown (note actions) */ border-radius:0.2rem; @@ -40,13 +40,13 @@ const TPL = `
/* Start of styling the slider */ input[type="range"] { - + /* removing default appearance */ -webkit-appearance: none; - appearance: none; + appearance: none; margin-left: 15px; width:50% - + } @@ -63,7 +63,7 @@ const TPL = `
input[type="range"]::-webkit-slider-thumb { /* removing default appearance */ -webkit-appearance: none; - appearance: none; + appearance: none; /* creating a custom design */ height: 15px; width: 15px; @@ -74,7 +74,7 @@ const TPL = `
/* End of styling the slider */ - +
@@ -83,9 +83,9 @@ const TPL = `
- - - + + +
@@ -180,7 +180,7 @@ export default class NoteMapWidget extends NoteContextAwareWidget { hoverNode = node || null; highlightLinks.clear(); }) - + // set link width to immitate a highlight effekt. Checking the condition if any links are saved in the previous defined set highlightlinks .linkWidth(link => (highlightLinks.has(link) ? 3 : 0.4)) .linkColor(link => (highlightLinks.has(link) ? 'white' : this.css.mutedTextColor)) diff --git a/src/public/translations/en/translation.json b/src/public/translations/en/translation.json index 5406e8053..a4ad201a3 100644 --- a/src/public/translations/en/translation.json +++ b/src/public/translations/en/translation.json @@ -795,7 +795,9 @@ "note_map": { "open_full": "Expand to full", "collapse": "Collapse to normal size", - "title": "Note Map" + "title": "Note Map", + "fix-nodes": "Fix nodes", + "link-distance": "Link distance" }, "note_paths": { "title": "Note Paths", diff --git a/src/public/translations/ro/translation.json b/src/public/translations/ro/translation.json index 4df6d0640..fe77402da 100644 --- a/src/public/translations/ro/translation.json +++ b/src/public/translations/ro/translation.json @@ -851,7 +851,9 @@ "note_map": { "collapse": "Micșorează la dimensiunea normală", "open_full": "Expandează la maximum", - "title": "Harta notițelor" + "title": "Harta notițelor", + "fix-nodes": "Fixează nodurile", + "link-distance": "Distanța dintre legături" }, "note_paths": { "archived": "Arhivat",