chore: improve performance (#42)

* use uniform list for rooms list

* move profile cache to outside gpui context

* update comment

* refactor

* refactor

* .

* .

* add avatar component

* .

* refactor

* .
This commit is contained in:
reya
2025-05-27 07:34:22 +07:00
committed by GitHub
parent 45564c7722
commit 0f884f8142
25 changed files with 1087 additions and 1373 deletions

View File

@@ -1,4 +1,4 @@
use common::profile::SharedProfile;
use common::profile::RenderProfile;
use gpui::{
AnyElement, AnyView, App, ElementId, FontWeight, HighlightStyle, InteractiveText, IntoElement,
SharedString, StyledText, UnderlineStyle, Window,
@@ -273,7 +273,7 @@ pub fn render_plain_text_mut(
if let Some(profile) = profile_match {
// Profile found - create a mention
let display_name = format!("@{}", profile.shared_name());
let display_name = format!("@{}", profile.render_name());
// Replace mention with profile name
text.replace_range(range.clone(), &display_name);