From 15fdbd4e9e36c858709651e035fe1339dba3a1e9 Mon Sep 17 00:00:00 2001 From: "Thomas F. K. Jorna" Date: Sat, 16 Oct 2021 22:21:24 +0200 Subject: feat(labels): better ui for labels --- pages/_app.tsx | 5 ++++- pages/index.tsx | 3 ++- 2 files changed, 6 insertions(+), 2 deletions(-) (limited to 'pages') diff --git a/pages/_app.tsx b/pages/_app.tsx index 9833717..3a0ffa0 100644 --- a/pages/_app.tsx +++ b/pages/_app.tsx @@ -180,7 +180,10 @@ function SubApp(props: any) { backgroundColor: highlightColor, }, filledTrack: { - backgroundColor: 'gray.200', + backgroundColor: 'gray.400', + }, + track: { + backgroundColor: 'gray.400', }, }), }, diff --git a/pages/index.tsx b/pages/index.tsx index 4878b0c..aa376d1 100644 --- a/pages/index.tsx +++ b/pages/index.tsx @@ -1137,6 +1137,7 @@ export const Graph = function (props: GraphProps) { const getNodeColor = (node: OrgRoamNode, theme: any) => { const needsHighlighting = highlightedNodes[node.id!] || previouslyHighlightedNodes[node.id!] + //const needsHighlighting = hoverNode?.id === node.id! || lastHoverNode?.current?.id === node.id // if we are matching the node color and don't have a highlight color // or we don't have our own scheme and we're not being highlighted if (visuals.emacsNodeColor && node.id === emacsNodeId) { @@ -1209,7 +1210,7 @@ export const Graph = function (props: GraphProps) { warmupTicks: scope.nodeIds.length === 1 ? 100 : scope.nodeIds.length > 1 ? 20 : 0, //onZoom: ({ k, x, y }) => setZoom(k), onZoom: ({ k, x, y }) => (scaleRef.current = k), - //nodeLabel: (node) => (node as OrgRoamNode).title, + //nodeLabel: (node) => , nodeColor: (node) => { return getNodeColor(node as OrgRoamNode, theme) }, -- cgit v1.2.3