treewide: replace std hashers with rustc_hash alternatives; fix clippy
Signed-off-by: NotAShelf <raf@notashelf.dev> Change-Id: I766c36cb53d3d7f9e85b91a67c4131a66a6a6964
This commit is contained in:
parent
d73bb4580d
commit
f831e58723
53 changed files with 343 additions and 394 deletions
|
|
@ -1,9 +1,8 @@
|
|||
//! Graph visualization component for markdown note connections.
|
||||
//!
|
||||
//! Renders a force-directed graph showing connections between notes.
|
||||
use std::collections::HashMap;
|
||||
|
||||
use dioxus::prelude::*;
|
||||
use rustc_hash::FxHashMap;
|
||||
|
||||
use crate::client::{
|
||||
ApiClient,
|
||||
|
|
@ -298,7 +297,7 @@ fn ForceDirectedGraph(
|
|||
|
||||
// Create id to position map
|
||||
let nodes_read = physics_nodes.read();
|
||||
let id_to_pos: HashMap<&str, (f64, f64)> = nodes_read
|
||||
let id_to_pos: FxHashMap<&str, (f64, f64)> = nodes_read
|
||||
.iter()
|
||||
.map(|n| (n.id.as_str(), (n.x, n.y)))
|
||||
.collect();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue