Compare commits

...

31 Commits

Author SHA1 Message Date
SngAbc
8ae3f2dad6
Merge a81e8adde78e4d608b40d417fdafd2ca3005bdcc into 8eca14069a263efac5133f0aa6e946e0ad9d554e 2025-12-01 12:02:46 +00:00
Elian Doran
8eca14069a
fix(e2e): i18n test failing to due to English selection
Some checks are pending
Checks / main (push) Waiting to run
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Deploy Documentation / Build and Deploy Documentation (push) Waiting to run
Dev / Test development (push) Waiting to run
Dev / Build Docker image (push) Blocked by required conditions
Dev / Check Docker build (Dockerfile) (push) Blocked by required conditions
Dev / Check Docker build (Dockerfile.alpine) (push) Blocked by required conditions
/ Check Docker build (Dockerfile) (push) Waiting to run
/ Check Docker build (Dockerfile.alpine) (push) Waiting to run
/ Build Docker images (Dockerfile, ubuntu-24.04-arm, linux/arm64) (push) Blocked by required conditions
/ Build Docker images (Dockerfile.alpine, ubuntu-latest, linux/amd64) (push) Blocked by required conditions
/ Build Docker images (Dockerfile.legacy, ubuntu-24.04-arm, linux/arm/v7) (push) Blocked by required conditions
/ Build Docker images (Dockerfile.legacy, ubuntu-24.04-arm, linux/arm/v8) (push) Blocked by required conditions
/ Merge manifest lists (push) Blocked by required conditions
playwright / E2E tests on linux-arm64 (push) Waiting to run
playwright / E2E tests on linux-x64 (push) Waiting to run
2025-12-01 14:02:32 +02:00
Elian Doran
1af0477ac0
chore(ci): fix duplicate artifact name error 2025-12-01 13:53:07 +02:00
Elian Doran
43920f12ae
feat(backlinks): use proper plural 2025-12-01 13:50:59 +02:00
Elian Doran
5a0beec6cb
fix(backlinks): not refreshed after inserting a new link 2025-12-01 13:37:15 +02:00
Elian Doran
98241fb54b
fix(promoted_attributes): value carrying over onto new notes 2025-12-01 13:37:15 +02:00
Adorian Doran
3051664228 style: fix typo 2025-12-01 13:34:36 +02:00
Adorian Doran
1ed774365c client/Kanban board collection: reorder context menu items 2025-12-01 13:33:20 +02:00
Adorian Doran
f2e33dfd58 Merge branch 'main' of https://github.com/TriliumNext/Trilium 2025-12-01 13:29:39 +02:00
Adorian Doran
90b5282b39 client/calendar collection: add "Archive note" command to the context menu 2025-12-01 13:29:28 +02:00
Elian Doran
d520fc46b9
fix(text): code blocks cannot wrap automatically (#7910) 2025-12-01 11:18:31 +00:00
Adorian Doran
e69b5988ec style: fix custom title bar buttons on the legacy theme 2025-12-01 11:48:42 +02:00
Adorian Doran
3cdc1ba794 style/calendar collection: fix colors on the legacy theme 2025-12-01 11:38:48 +02:00
Adorian Doran
25e1008c5c Merge branch 'main' of https://github.com/TriliumNext/Trilium 2025-12-01 11:24:52 +02:00
Adorian Doran
a093862311 style/calendar collection: use a separate style for archived notes 2025-12-01 11:24:39 +02:00
Elian Doran
53057ea9fc
Translations update from Hosted Weblate (#7907) 2025-12-01 08:09:22 +00:00
Francis C.
94db96de3e
Translated using Weblate (Chinese (Simplified Han script))
Currently translated at 100.0% (1638 of 1638 strings)

Translation: Trilium Notes/Client
Translate-URL: https://hosted.weblate.org/projects/trilium/client/zh_Hans/
2025-12-01 09:04:54 +01:00
Mr Mejri
60e4fbbf75
Translated using Weblate (Persian)
Currently translated at 15.2% (18 of 118 strings)

Translation: Trilium Notes/README
Translate-URL: https://hosted.weblate.org/projects/trilium/readme/fa/
2025-12-01 09:04:53 +01:00
green
d35dd67632
Translated using Weblate (Japanese)
Currently translated at 100.0% (1638 of 1638 strings)

Translation: Trilium Notes/Client
Translate-URL: https://hosted.weblate.org/projects/trilium/client/ja/
2025-12-01 07:28:44 +01:00
Francis C.
8813985c68
Translated using Weblate (Chinese (Traditional Han script))
Currently translated at 100.0% (1638 of 1638 strings)

Translation: Trilium Notes/Client
Translate-URL: https://hosted.weblate.org/projects/trilium/client/zh_Hant/
2025-12-01 07:28:44 +01:00
Mr Mejri
538c98b587
Translated using Weblate (Persian)
Currently translated at 5.9% (7 of 118 strings)

Translation: Trilium Notes/README
Translate-URL: https://hosted.weblate.org/projects/trilium/readme/fa/
2025-12-01 07:28:44 +01:00
Hosted Weblate
389c7029cf
Update translation files
Updated by "Cleanup translation files" add-on in Weblate.

Translation: Trilium Notes/README
Translate-URL: https://hosted.weblate.org/projects/trilium/readme/
2025-12-01 07:28:44 +01:00
Elian Doran
d47f9e1131
chore(deps): update dependency eslint-plugin-playwright to v2.4.0 (#7908) 2025-12-01 06:28:37 +00:00
Elian Doran
c0a8d29756
fix(deps): update dependency tsx to v4.21.0 (#7909) 2025-12-01 06:26:48 +00:00
SiriusXT
668fd34af6 fix(text): code blocks cannot wrap automatically 2025-12-01 13:55:21 +08:00
renovate[bot]
8aa08cf8fe
fix(deps): update dependency tsx to v4.21.0 2025-12-01 01:19:56 +00:00
renovate[bot]
16c04f5ae4
chore(deps): update dependency eslint-plugin-playwright to v2.4.0 2025-12-01 01:19:12 +00:00
SiriusXT
a81e8adde7 client/pageurl: adjust Info bar order
Some checks failed
Checks / main (push) Has been cancelled
2025-11-14 20:22:51 +08:00
SiriusXT
5aec9229d4 chore: remove unnecessary console.log 2025-11-14 18:16:59 +08:00
SiriusXT
0c954322e4 i18n: remove unused translation note_properties.info 2025-11-14 18:08:20 +08:00
SiriusXT
9580d636cf client/pageurl: migrate note origin to info bar 2025-11-14 17:20:35 +08:00
38 changed files with 285 additions and 505 deletions

View File

@ -79,7 +79,7 @@ jobs:
if: failure()
uses: actions/upload-artifact@v5
with:
name: e2e report
name: e2e report ${{ matrix.arch }}
path: apps/server-e2e/test-output
- name: Kill the server

View File

@ -30,6 +30,7 @@ import ScrollingContainer from "../widgets/containers/scrolling_container.js";
import ScrollPadding from "../widgets/scroll_padding.js";
import SearchResult from "../widgets/search_result.jsx";
import SharedInfo from "../widgets/shared_info.jsx";
import OriginInfo from "../widgets/note_origin.jsx";
import SpacerWidget from "../widgets/spacer.js";
import SplitNoteContainer from "../widgets/containers/split_note_container.js";
import SqlResults from "../widgets/sql_result.js";
@ -139,6 +140,7 @@ export default class DesktopLayout {
.filling()
.child(new ContentHeader()
.child(<ReadOnlyNoteInfoBar />)
.child(<OriginInfo />)
.child(<SharedInfo />)
)
.child(<PromotedAttributes />)

View File

@ -0,0 +1,21 @@
import { t } from "../services/i18n"
import attributes from "../services/attributes"
import FNote from "../entities/fnote"
export function getArchiveMenuItem(note: FNote) {
if (!note.isArchived) {
return {
title: t("board_view.archive-note"),
uiIcon: "bx bx-archive",
handler: () => attributes.addLabel(note.noteId, "archived")
}
} else {
return {
title: t("board_view.unarchive-note"),
uiIcon: "bx bx-archive-out",
handler: async () => {
attributes.removeOwnedLabelByName(note, "archived")
}
}
}
}

View File

@ -207,7 +207,7 @@ function toObject<T, R>(array: T[], fn: (arg0: T) => [key: string, value: R]) {
return obj;
}
function randomString(len: number) {
export function randomString(len: number) {
let text = "";
const possible = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";

View File

@ -257,6 +257,11 @@ button.close:hover {
color: var(--hover-item-text-color);
}
button.custom-title-bar-button {
background: transparent;
border: unset;
}
.modal-content {
background-color: var(--modal-background-color) !important;
}

View File

@ -275,7 +275,8 @@
--calendar-coll-event-background-lightness: 20%;
--calendar-coll-event-background-color: #3c3c3c;
--calendar-coll-event-text-color: white;
--calendar-cell-event-hover-filter: brightness(1.25);
--calendar-coll-event-hover-filter: brightness(1.25);
--callendar-coll-event-archived-sripe-color: #00000026;
--calendar-coll-today-background-color: #ffffff08;
}

View File

@ -273,7 +273,8 @@
--calendar-coll-event-background-saturation: 80%;
--calendar-coll-event-background-color: #eaeaea;
--calendar-coll-event-text-color: black;
--calendar-cell-event-hover-filter: brightness(.95) saturate(1.25);
--calendar-coll-event-hover-filter: brightness(.95) saturate(1.25);
--callendar-coll-event-archived-sripe-color: #0000000a;
--calendar-coll-today-background-color: #00000006;
}

View File

@ -643,7 +643,7 @@ html .note-detail-editable-text :not(figure, .include-note, hr):first-child {
}
}
.note-detail-printable:not(.word-wrap) pre code {
.ck-content:not(.word-wrap) pre code {
white-space: pre;
}

View File

@ -511,7 +511,7 @@
"title": "الملاحظات المعدلة"
},
"note_properties": {
"info": "معلومات"
"this_note_was_originally_taken_from": ""
},
"backend_log": {
"refresh": "تحديث"

View File

@ -162,7 +162,8 @@
"inPageSearch": "页面内搜索",
"newTabWithActivationNoteLink": "在新标签页打开笔记链接并激活该标签页",
"title": "资料表",
"newTabNoteLink": "在新标签页开启链接"
"newTabNoteLink": "在新标签页开启链接",
"editShortcuts": "编辑键盘快捷键"
},
"import": {
"importIntoNote": "导入到笔记",
@ -840,8 +841,7 @@
"search": "搜索"
},
"note_properties": {
"this_note_was_originally_taken_from": "笔记来源:",
"info": "信息"
"this_note_was_originally_taken_from": "笔记来源:"
},
"owned_attribute_list": {
"owned_attributes": "拥有的属性"
@ -2104,5 +2104,8 @@
"clear-color": "清除笔记颜色",
"set-color": "设置笔记颜色",
"set-custom-color": "设置自定义笔记颜色"
},
"popup-editor": {
"maximize": "切换至完整编辑器"
}
}

View File

@ -837,8 +837,7 @@
"search": "Suchen"
},
"note_properties": {
"this_note_was_originally_taken_from": "Diese Notiz stammt ursprünglich aus:",
"info": "Info"
"this_note_was_originally_taken_from": "Diese Notiz stammt ursprünglich aus:"
},
"owned_attribute_list": {
"owned_attributes": "Eigene Attribute"

View File

@ -736,8 +736,8 @@
"zoom_out_title": "Zoom Out"
},
"zpetne_odkazy": {
"backlink": "{{count}} Backlink",
"backlinks": "{{count}} Backlinks",
"backlink_one": "{{count}} Backlink",
"backlink_other": "{{count}} Backlinks",
"relation": "relation"
},
"mobile_detail_menu": {
@ -841,8 +841,7 @@
"search": "Search"
},
"note_properties": {
"this_note_was_originally_taken_from": "This note was originally taken from:",
"info": "Info"
"this_note_was_originally_taken_from": "This note was originally taken from:"
},
"owned_attribute_list": {
"owned_attributes": "Owned Attributes"

View File

@ -840,8 +840,7 @@
"search": "Buscar"
},
"note_properties": {
"this_note_was_originally_taken_from": "Esta nota fue tomada originalmente de:",
"info": "Información"
"this_note_was_originally_taken_from": "Esta nota fue tomada originalmente de:"
},
"owned_attribute_list": {
"owned_attributes": "Atributos propios"

View File

@ -834,8 +834,7 @@
"search": "Recherche"
},
"note_properties": {
"this_note_was_originally_taken_from": "Cette note est initialement extraite de :",
"info": "Infos"
"this_note_was_originally_taken_from": "Cette note est initialement extraite de :"
},
"owned_attribute_list": {
"owned_attributes": "Attributs propres"

View File

@ -1409,8 +1409,7 @@
"search": "Ricerca"
},
"note_properties": {
"this_note_was_originally_taken_from": "Questa nota è stata originariamente tratta da:",
"info": "Informazioni"
"this_note_was_originally_taken_from": "Questa nota è stata originariamente tratta da:"
},
"owned_attribute_list": {
"owned_attributes": "Attributi posseduti"

View File

@ -693,7 +693,6 @@
"outside_hoisted": "このパスはホイストされたノートの外側にあるため、ホイストを解除する必要があります。"
},
"note_properties": {
"info": "情報",
"this_note_was_originally_taken_from": "このノートは元々以下から引用したものです:"
},
"similar_notes": {
@ -2105,5 +2104,8 @@
"clear-color": "ノートの色をクリア",
"set-color": "ノートの色を設定",
"set-custom-color": "ノートの色をカスタム設定"
},
"popup-editor": {
"maximize": "フルエディターに切り替え"
}
}

View File

@ -447,8 +447,7 @@
"search": "Szukaj"
},
"note_properties": {
"this_note_was_originally_taken_from": "Ta notatka oryginalnie została wzięta z:",
"info": "Info"
"this_note_was_originally_taken_from": "Ta notatka oryginalnie została wzięta z:"
},
"owned_attribute_list": {
"owned_attributes": "Posiadane atrybuty"

View File

@ -809,8 +809,7 @@
"search": "Pesquisar"
},
"note_properties": {
"this_note_was_originally_taken_from": "Esta nota foi originalmente obtida de:",
"info": "Informações"
"this_note_was_originally_taken_from": "Esta nota foi originalmente obtida de:"
},
"owned_attribute_list": {
"owned_attributes": "Atributos próprios"

View File

@ -1075,8 +1075,7 @@
"outside_hoisted": "Este caminho está fora de uma nota fixada e você teria que desafixar."
},
"note_properties": {
"this_note_was_originally_taken_from": "Esta nota foi originalmente obtida de:",
"info": "Informações"
"this_note_was_originally_taken_from": "Esta nota foi originalmente obtida de:"
},
"promoted_attributes": {
"promoted_attributes": "Atributos Promovidos",

View File

@ -910,7 +910,6 @@
"title": "Căile notiței"
},
"note_properties": {
"info": "Informații",
"this_note_was_originally_taken_from": "Această notiță a fost preluată original de la:"
},
"note_type_chooser": {
@ -1362,8 +1361,9 @@
"title": "Factorul de zoom (doar pentru versiunea desktop)"
},
"zpetne_odkazy": {
"backlink": "{{count}} legături de retur",
"backlinks": "{{count}} legături de retur",
"backlink_one": "{{count}} legătură de retur",
"backlink_few": "{{count}} legături de retur",
"backlink_other": "{{count}} de legături de retur",
"relation": "relație"
},
"svg_export_button": {

View File

@ -1066,7 +1066,6 @@
"archived": "Архивировано"
},
"note_properties": {
"info": "Информация",
"this_note_was_originally_taken_from": "Эта заметка была первоначально взята из:"
},
"promoted_attributes": {

View File

@ -162,7 +162,8 @@
"inPageSearch": "頁面內搜尋",
"title": "列表",
"newTabNoteLink": "在新分頁開啟筆記連結",
"newTabWithActivationNoteLink": "在新分頁開啟並切換至筆記連結"
"newTabWithActivationNoteLink": "在新分頁開啟並切換至筆記連結",
"editShortcuts": "編輯鍵盤快捷鍵"
},
"import": {
"importIntoNote": "匯入至筆記",
@ -837,8 +838,7 @@
"search": "搜尋"
},
"note_properties": {
"this_note_was_originally_taken_from": "筆記來源:",
"info": "資訊"
"this_note_was_originally_taken_from": "筆記來源:"
},
"owned_attribute_list": {
"owned_attributes": "自有屬性"
@ -2104,5 +2104,8 @@
"clear-color": "清除筆記顏色",
"set-color": "設定筆記顏色",
"set-custom-color": "設定自訂筆記顏色"
},
"popup-editor": {
"maximize": "切換至完整編輯器"
}
}

View File

@ -938,8 +938,7 @@
"outside_hoisted": "Цей шлях знаходиться поза межами закріпленої нотатки і вам доведеться відкріпити."
},
"note_properties": {
"this_note_was_originally_taken_from": "Цю нотатку було спочатку взято з:",
"info": "Інформація"
"this_note_was_originally_taken_from": "Цю нотатку було спочатку взято з:"
},
"owned_attribute_list": {
"owned_attributes": "Власні Атрибути"

View File

@ -18,6 +18,7 @@ import froca from "../services/froca";
import NoteLink from "./react/NoteLink";
import RawHtml from "./react/RawHtml";
import { ViewTypeOptions } from "./collections/interface";
import attributes from "../services/attributes";
export interface FloatingButtonContext {
parentComponent: Component;
@ -310,13 +311,24 @@ function Backlinks({ note, isDefaultViewMode }: FloatingButtonContext) {
let [ popupOpen, setPopupOpen ] = useState(false);
const backlinksContainerRef = useRef<HTMLDivElement>(null);
useEffect(() => {
function refresh() {
if (!isDefaultViewMode) return;
server.get<BacklinkCountResponse>(`note-map/${note.noteId}/backlink-count`).then(resp => {
setBacklinkCount(resp.count);
});
}, [ note ]);
}
useEffect(() => refresh(), [ note ]);
useTriliumEvent("entitiesReloaded", ({ loadResults }) => {
loadResults.getAttributeRows().some(attr =>
attr.type === "relation" &&
attr.name === "internalLink" &&
attributes.isAffecting(attr, note))
{
refresh();
}
});
// Determine the max height of the container.
const { windowHeight } = useWindowSize();

View File

@ -14,8 +14,10 @@ import ws from "../services/ws";
import { UpdateAttributeResponse } from "@triliumnext/commons";
import attributes from "../services/attributes";
import debounce from "../services/debounce";
import { randomString } from "../services/utils";
interface Cell {
uniqueId: string;
definitionAttr: FAttribute;
definition: DefinitionObject;
valueAttr: Attribute;
@ -44,6 +46,7 @@ export default function PromotedAttributes() {
<div className="promoted-attributes-widget">
{cells && cells.length > 0 && <div className="promoted-attributes-container">
{note && cells?.map(cell => <PromotedAttributeCell
key={cell.uniqueId}
cell={cell}
cells={cells} setCells={setCells}
shouldFocus={cell === cellToFocus} setCellToFocus={setCellToFocus}
@ -103,7 +106,8 @@ function usePromotedAttributeData(note: FNote | null | undefined, componentId: s
valueAttr.attributeId = "";
}
cells.push({ definitionAttr, definition, valueAttr, valueName });
const uniqueId = randomString(10);
cells.push({ definitionAttr, definition, valueAttr, valueName, uniqueId });
}
}
setCells(cells);

View File

@ -2,9 +2,9 @@ import FNote from "../../../entities/fnote";
import NoteColorPicker from "../../../menus/custom-items/NoteColorPicker";
import contextMenu, { ContextMenuEvent } from "../../../menus/context_menu";
import link_context_menu from "../../../menus/link_context_menu";
import attributes from "../../../services/attributes";
import branches from "../../../services/branches";
import dialog from "../../../services/dialog";
import { getArchiveMenuItem } from "../../../menus/context_menu_utils";
import { t } from "../../../services/i18n";
import Api from "./api";
@ -43,17 +43,6 @@ export function openNoteContextMenu(api: Api, event: ContextMenuEvent, note: FNo
items: [
...link_context_menu.getItems(),
{ kind: "separator" },
{
title: t("board_view.move-to"),
uiIcon: "bx bx-transfer",
items: api.columns.map(columnToMoveTo => ({
title: columnToMoveTo,
enabled: columnToMoveTo !== column,
handler: () => api.changeColumn(note.noteId, columnToMoveTo)
})),
},
getArchiveMenuItem(note),
{ kind: "separator" },
{
title: t("board_view.insert-above"),
uiIcon: "bx bx-list-plus",
@ -65,6 +54,17 @@ export function openNoteContextMenu(api: Api, event: ContextMenuEvent, note: FNo
handler: () => api.insertRowAtPosition(column, branchId, "after")
},
{ kind: "separator" },
{
title: t("board_view.move-to"),
uiIcon: "bx bx-transfer",
items: api.columns.map(columnToMoveTo => ({
title: columnToMoveTo,
enabled: columnToMoveTo !== column,
handler: () => api.changeColumn(note.noteId, columnToMoveTo)
})),
},
{ kind: "separator" },
getArchiveMenuItem(note),
{
title: t("board_view.remove-from-board"),
uiIcon: "bx bx-task-x",
@ -85,20 +85,3 @@ export function openNoteContextMenu(api: Api, event: ContextMenuEvent, note: FNo
});
}
function getArchiveMenuItem(note: FNote) {
if (!note.isArchived) {
return {
title: t("board_view.archive-note"),
uiIcon: "bx bx-archive",
handler: () => attributes.addLabel(note.noteId, "archived")
}
} else {
return {
title: t("board_view.unarchive-note"),
uiIcon: "bx bx-archive-out",
handler: async () => {
attributes.removeOwnedLabelByName(note, "archived")
}
}
}
}

View File

@ -3,11 +3,10 @@ import FNote from "../../../entities/fnote";
import contextMenu, { ContextMenuEvent } from "../../../menus/context_menu";
import link_context_menu from "../../../menus/link_context_menu";
import branches from "../../../services/branches";
import froca from "../../../services/froca";
import { note } from "mermaid/dist/rendering-util/rendering-elements/shapes/note.js";
import { getArchiveMenuItem } from "../../../menus/context_menu_utils";
import { t } from "../../../services/i18n";
export function openCalendarContextMenu(e: ContextMenuEvent, noteId: string, parentNote: FNote) {
export function openCalendarContextMenu(e: ContextMenuEvent, note: FNote, parentNote: FNote) {
e.preventDefault();
e.stopPropagation();
@ -17,15 +16,13 @@ export function openCalendarContextMenu(e: ContextMenuEvent, noteId: string, par
items: [
...link_context_menu.getItems(),
{ kind: "separator" },
getArchiveMenuItem(note),
{
title: t("calendar_view.delete_note"),
uiIcon: "bx bx-trash",
handler: async () => {
const noteToDelete = await froca.getNote(noteId);
if (!noteToDelete) return;
let branchIdToDelete: string | null = null;
for (const parentBranch of noteToDelete.getParentBranches()) {
for (const parentBranch of note.getParentBranches()) {
const parentNote = await parentBranch.getNote();
if (parentNote?.hasAncestor(parentNote.noteId)) {
branchIdToDelete = parentBranch.branchId;
@ -40,9 +37,9 @@ export function openCalendarContextMenu(e: ContextMenuEvent, noteId: string, par
{ kind: "separator" },
{
kind: "custom",
componentFn: () => NoteColorPicker({note: noteId})
componentFn: () => NoteColorPicker({note: note})
}
],
selectMenuItemHandler: ({ command }) => link_context_menu.handleLinkContextMenuItem(command, noteId),
selectMenuItemHandler: ({ command }) => link_context_menu.handleLinkContextMenuItem(command, note.noteId),
})
}

View File

@ -3,8 +3,9 @@
--calendar-coll-event-background-lightness: 95%;
--calendar-coll-event-background-saturation: 80%;
--calendar-coll-event-background-color: var(--accented-background-color);
--calendar-coll-event-text-color: var(--primary-button-text-color);
--calendar-cell-event-hover-filter: none;
--calendar-coll-event-text-color: var(--main-text-color);
--calendar-coll-event-hover-filter: none;
--callendar-coll-event-archived-sripe-color: #00000013;
--calendar-coll-today-background-color: var(--more-accented-background-color);
}
@ -53,7 +54,23 @@
}
.calendar-container a.fc-event.archived {
opacity: 0.5;
opacity: .65;
}
.calendar-container a.fc-event.archived::after {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
z-index: -1;
--c1: transparent;
--c2: var(--callendar-coll-event-archived-sripe-color);
background: repeating-linear-gradient(45deg, var(--c1), var(--c1) 8px,
var(--c2) 8px, var(--c2) 16px) !important;
}
.calendar-container .fc-button {
@ -129,17 +146,18 @@ body.desktop:not(.zen) .calendar-view .calendar-header {
.calendar-view a.fc-timegrid-event:hover,
.calendar-view a.fc-daygrid-event:hover {
filter: var(--calendar-cell-event-hover-filter);
filter: var(--calendar-coll-event-hover-filter);
border-color: var(--fc-event-text-color);
text-decoration: none;
color: currentColor;
opacity: 1;
}
.calendar-view .fc-timegrid-event.with-hue,
.calendar-view .fc-daygrid-event.with-hue {
--fc-event-text-color: var(--custom-color);
background: hsl(var(--custom-color-hue),
--fc-event-bg-color: hsl(var(--custom-color-hue),
var(--calendar-coll-event-background-saturation),
var(--calendar-coll-event-background-lightness)) !important;
}

View File

@ -307,9 +307,11 @@ function useEventDisplayCustomization(parentNote: FNote) {
$(mainContainer ?? e.el).append($(promotedAttributesHtml));
}
e.el.addEventListener("contextmenu", (contextMenuEvent) => {
const noteId = e.event.extendedProps.noteId;
openCalendarContextMenu(contextMenuEvent, noteId, parentNote);
e.el.addEventListener("contextmenu", async (contextMenuEvent) => {
const note = await froca.getNote(e.event.extendedProps.noteId);
if (!note) return;
openCalendarContextMenu(contextMenuEvent, note, parentNote);
});
}, []);
return { eventDidMount };

View File

@ -0,0 +1,43 @@
import { t } from "../services/i18n";
import { useNoteContext, useTriliumEvent, useTriliumOption } from "./react/hooks";
import { useEffect, useState } from "preact/hooks";
import attributes from "../services/attributes";
import InfoBar from "./react/InfoBar";
import RawHtml from "./react/RawHtml";
import FNote from "../entities/fnote";
export default function OriginInfo() {
const { note } = useNoteContext();
const [link, setLink] = useState<string>();
function refresh() {
if (!note) return;
const pageUrl = getPageUrl(note);
if (!pageUrl) {
setLink(undefined);
return;
}
setLink(`<a href="${pageUrl}" class="external tn-link">${pageUrl}</a>`);
}
useEffect(refresh, [note]);
useTriliumEvent("entitiesReloaded", ({ loadResults }) => {
if (loadResults.getAttributeRows().find((attr) => attr.type === "label" && attr.name?.toString() === "pageUrl" && attributes.isAffecting(attr, note))) {
refresh();
}
});
return (
<InfoBar className="origin-info-widget" type="subtle" style={{ display: (!link) ? "none" : undefined }}>
{link && (
<RawHtml
html={`${t("note_properties.this_note_was_originally_taken_from")} ${link}`}
/>
)}
</InfoBar>
)
}
function getPageUrl(note: FNote) {
return note.getOwnedLabelValue("pageUrl");
}

View File

@ -1,20 +0,0 @@
import { t } from "../../services/i18n";
import { useNoteLabel } from "../react/hooks";
import { TabContext } from "./ribbon-interface";
/**
* TODO: figure out better name or conceptualize better.
*/
export default function NotePropertiesTab({ note }: TabContext) {
const [ pageUrl ] = useNoteLabel(note, "pageUrl");
return (
<div className="note-properties-widget" style={{ padding: "12px", color: "var(--muted-text-color)" }}>
{ pageUrl && (
<div style={{ overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap" }}>
{t("note_properties.this_note_was_originally_taken_from")} <a href={pageUrl} class="page-url external">{pageUrl}</a>
</div>
)}
</div>
)
}

View File

@ -1,6 +1,5 @@
import ScriptTab from "./ScriptTab";
import EditedNotesTab from "./EditedNotesTab";
import NotePropertiesTab from "./NotePropertiesTab";
import NoteInfoTab from "./NoteInfoTab";
import SimilarNotesTab from "./SimilarNotesTab";
import FilePropertiesTab from "./FilePropertiesTab";
@ -59,13 +58,6 @@ export const RIBBON_TAB_DEFINITIONS: TabConfiguration[] = [
show: ({ note }) => note?.type === "book" || note?.type === "search",
toggleCommand: "toggleRibbonTabBookProperties"
},
{
title: t("note_properties.info"),
icon: "bx bx-info-square",
content: NotePropertiesTab,
show: ({ note }) => !!note?.getLabelValue("pageUrl"),
activate: true
},
{
title: t("file_properties.title"),
icon: "bx bx-file",

View File

@ -7,7 +7,7 @@
"better-sqlite3": "12.5.0",
"mime-types": "3.0.2",
"sanitize-filename": "1.6.3",
"tsx": "4.20.6",
"tsx": "4.21.0",
"yargs": "18.0.0"
},
"devDependencies": {

View File

@ -43,7 +43,7 @@ test("User can change language from settings", async ({ page, context }) => {
// Check that the default value (English) is set.
await expect(app.currentNoteSplit).toContainText("First day of the week");
const languageCombobox = app.dropdown(app.currentNoteSplit.locator(".options-section .dropdown").first());
await expect(languageCombobox).toContainText("English");
await expect(languageCombobox).toContainText("English (United States)");
// Select Chinese and ensure the translation is set.
await languageCombobox.selectOptionByText("简体中文");
@ -53,8 +53,8 @@ test("User can change language from settings", async ({ page, context }) => {
await expect(languageCombobox).toContainText("简体中文");
// Select English again.
await languageCombobox.selectOptionByText("English");
await languageCombobox.selectOptionByText("English (United States)");
await app.currentNoteSplit.locator("button[name=restart-app-button]").click();
await expect(app.currentNoteSplit).toContainText("Language", { timeout: 15000 });
await expect(languageCombobox).toContainText("English");
await expect(languageCombobox).toContainText("English (United States)");
});

55
docs/README-fa.md vendored
View File

@ -33,50 +33,39 @@ quick overview:
<a href="https://triliumnext.github.io/Docs/Wiki/screenshot-tour"><img src="./docs/app.png" alt="Trilium Screenshot" width="1000"></a>
## ⏬ Download
- [Latest release](https://github.com/TriliumNext/Trilium/releases/latest)
stable version, recommended for most users.
## ⏬ دانلود
- [آخرین انتشار]{1} نسخه پایدار، برای بیشتر کاربران پیشنهاد می‌شود.
- [Nightly build](https://github.com/TriliumNext/Trilium/releases/tag/nightly)
unstable development version, updated daily with the latest features and
fixes.
## 📚 Documentation
## 📚 کتابچه راهنما
**Visit our comprehensive documentation at
[docs.triliumnotes.org](https://docs.triliumnotes.org/)**
Our documentation is available in multiple formats:
- **Online Documentation**: Browse the full documentation at
[docs.triliumnotes.org](https://docs.triliumnotes.org/)
- **In-App Help**: Press `F1` within Trilium to access the same documentation
directly in the application
- **GitHub**: Navigate through the [User
Guide](./docs/User%20Guide/User%20Guide/) in this repository
مستندات ما در چندین قالب مختلف در دسترس است:
- مستندات آنلاین: می‌توانید نسخهٔ کامل مستندات را در
[docs.triliumnotes.org](https://docs.triliumnotes.org/) مرور کنید
- ** In-App Help **: Press `F1 ` در Trilium برای دسترسی به همان اسناد به طور
مستقیم در برنامه
- ** GitHub **: از طریق [راهنمای کاربر] در این مخزن حرکت کنید
### Quick Links
- [Getting Started Guide](https://docs.triliumnotes.org/)
- [Installation
Instructions](./docs/User%20Guide/User%20Guide/Installation%20&%20Setup/Server%20Installation.md)
- [Docker
Setup](./docs/User%20Guide/User%20Guide/Installation%20&%20Setup/Server%20Installation/1.%20Installing%20the%20server/Using%20Docker.md)
- [Upgrading
TriliumNext](./docs/User%20Guide/User%20Guide/Installation%20%26%20Setup/Upgrading%20TriliumNext.md)
- [Basic Concepts and
Features](./docs/User%20Guide/User%20Guide/Basic%20Concepts%20and%20Features/Notes.md)
- [Patterns of Personal Knowledge
Base](https://triliumnext.github.io/Docs/Wiki/patterns-of-personal-knowledge)
### لینک‌های سریع
- راهنمای شروع کار
- دستورالعمل‌های نصب
- راه‌اندازی داکر
- ارتقای TriliumNext
- مفاهیم و ویژگی‌های پایه
- الگوهای پایگاه دانشی شخصی
## 🎁 Features
## 🎁 ویژگی‌ها
* Notes can be arranged into arbitrarily deep tree. Single note can be placed
into multiple places in the tree (see
[cloning](https://triliumnext.github.io/Docs/Wiki/cloning-notes))
* Rich WYSIWYG note editor including e.g. tables, images and
[math](https://triliumnext.github.io/Docs/Wiki/text-notes) with markdown
[autoformat](https://triliumnext.github.io/Docs/Wiki/text-notes#autoformat)
* Support for editing [notes with source
code](https://triliumnext.github.io/Docs/Wiki/code-notes), including syntax
highlighting
* یادداشت‌ها می‌توانند در یک درخت با عمق دلخواه سازمان‌دهی شوند. یک یادداشت
می‌تواند در چندین نقطهٔ مختلف از درخت قرار گیرد.
* ویرایشگر یادداشت غنی WYSIWYG از جمله جداول، تصاویر و [math] [1] با علامت گذاری
[autoformat] [2]
* پشتیبانی از ویرایش [یادداشت با کد منبع][۱]، از جمله نحو برجسته
* Fast and easy [navigation between
notes](https://triliumnext.github.io/Docs/Wiki/note-navigation), full text
search and [note

View File

@ -53,7 +53,7 @@
"esbuild": "0.27.0",
"eslint": "9.39.1",
"eslint-config-prettier": "10.1.8",
"eslint-plugin-playwright": "2.3.0",
"eslint-plugin-playwright": "2.4.0",
"eslint-plugin-react-hooks": "7.0.1",
"happy-dom": "~20.0.0",
"http-server": "14.1.1",
@ -62,7 +62,7 @@
"react-refresh": "0.18.0",
"rollup-plugin-webpack-stats": "2.1.8",
"tslib": "2.8.1",
"tsx": "4.20.6",
"tsx": "4.21.0",
"typescript": "~5.9.0",
"typescript-eslint": "8.48.0",
"upath": "2.0.1",

View File

@ -14,7 +14,7 @@ export interface Locale {
const UNSORTED_LOCALES = [
{ id: "cn", name: "简体中文", electronLocale: "zh_CN" },
{ id: "de", name: "Deutsch", electronLocale: "de" },
{ id: "en", name: "English", electronLocale: "en" },
{ id: "en", name: "English (United States)", electronLocale: "en" },
{ id: "en-GB", name: "English (United Kingdom)", electronLocale: "en_GB" },
{ id: "es", name: "Español", electronLocale: "es" },
{ id: "fr", name: "Français", electronLocale: "fr" },

434
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff