Model graph: decision and registry links on by default, placed near their elements

This commit is contained in:
root-at-skic committed 2026-10-21 22:33:02 +03:00
1 parent 27d1b4381c
commit bc9f55e2fa
4 files changed
+17 -8

No files matched your search

+3 -2
View File
@@ -131,6 +131,7 @@ class GraphPage {
this.saved = (host.getState().graphView as SavedView | undefined) ?? {};
if (initial.query !== undefined) this.saved.query = initial.query;
if (this.saved.labels === undefined) this.saved.labels = initial.graph.edges.length <= LABELS_UP_TO;
if (this.saved.links === undefined) this.saved.links = true;
this.hiddenTypes = new Set(this.saved.hidden ?? []);
this.applyTheme(this.saved.theme ?? archifyThemePreference());
this.index();
@@ -261,7 +262,7 @@ class GraphPage {
this.syncLayoutButton();
});
this.linksButton.type = 'button';
this.linksButton.title = 'Show the links from decisions and registries to their elements; off, they show for the selected element only';
this.linksButton.title = 'Links from decisions and registries to their elements: on for all, off for the selected element only';
this.linksButton.addEventListener('click', () => {
this.saved.links = !this.saved.links;
this.save();
@@ -300,7 +301,7 @@ class GraphPage {
table.appendChild(row);
}
this.help.appendChild(table);
this.help.appendChild(el('p', '', 'Matches stay bright, the rest dims. Connections show when both ends match. Click an element for its details; drag to move it; scroll to zoom. Press / to type a query. Layered puts clients on the left and data on the right, with registries before and decisions after; Links shows every decision and registry link instead of the selected element\u2019s only.'));
this.help.appendChild(el('p', '', 'Matches stay bright, the rest dims. Connections show when both ends match. Click an element for its details; drag to move it; scroll to zoom. Press / to type a query. Layered puts clients on the left and data on the right, with registries before and decisions after; Links switches the dotted decision and registry links between all of them and the selected element\u2019s only.'));
this.main.append(this.canvas, this.side, this.help);
this.root.append(top, bar, this.main);
document.body.appendChild(this.root);