onboarding ui: Add theme preview tiles and button functionality to basic page (#35413)
This PR polishes and adds functionality to the onboarding UI with a focus on the basic page. It added theme preview tiles, got the Vim, telemetry, crash reporting, and sign-in button working. The theme preview component was moved to the UI crate and it now can have a click handler on it. Finally, this commit also changed `client::User.github_login` and `client::UserStore.by_github_login` to use `SharedStrings` instead of `Strings`. This change was made because user.github_login was cloned in several areas including the UI, and was cast to a shared string in some cases too. Release Notes: - N/A --------- Co-authored-by: Remco Smits <djsmits12@gmail.com>
This commit is contained in:
parent
b59f992928
commit
c6947ee4f0
18 changed files with 295 additions and 83 deletions
|
@ -38,12 +38,12 @@ fn room_participants(room: &Entity<Room>, cx: &mut TestAppContext) -> RoomPartic
|
|||
let mut remote = room
|
||||
.remote_participants()
|
||||
.values()
|
||||
.map(|participant| participant.user.github_login.clone())
|
||||
.map(|participant| participant.user.github_login.clone().to_string())
|
||||
.collect::<Vec<_>>();
|
||||
let mut pending = room
|
||||
.pending_participants()
|
||||
.iter()
|
||||
.map(|user| user.github_login.clone())
|
||||
.map(|user| user.github_login.clone().to_string())
|
||||
.collect::<Vec<_>>();
|
||||
remote.sort();
|
||||
pending.sort();
|
||||
|
|
|
@ -1881,7 +1881,7 @@ async fn test_active_call_events(
|
|||
vec![room::Event::RemoteProjectShared {
|
||||
owner: Arc::new(User {
|
||||
id: client_a.user_id().unwrap(),
|
||||
github_login: "user_a".to_string(),
|
||||
github_login: "user_a".into(),
|
||||
avatar_uri: "avatar_a".into(),
|
||||
name: None,
|
||||
}),
|
||||
|
@ -1900,7 +1900,7 @@ async fn test_active_call_events(
|
|||
vec![room::Event::RemoteProjectShared {
|
||||
owner: Arc::new(User {
|
||||
id: client_b.user_id().unwrap(),
|
||||
github_login: "user_b".to_string(),
|
||||
github_login: "user_b".into(),
|
||||
avatar_uri: "avatar_b".into(),
|
||||
name: None,
|
||||
}),
|
||||
|
@ -6079,7 +6079,7 @@ async fn test_contacts(
|
|||
.iter()
|
||||
.map(|contact| {
|
||||
(
|
||||
contact.user.github_login.clone(),
|
||||
contact.user.github_login.clone().to_string(),
|
||||
if contact.online { "online" } else { "offline" },
|
||||
if contact.busy { "busy" } else { "free" },
|
||||
)
|
||||
|
|
|
@ -696,17 +696,17 @@ impl TestClient {
|
|||
current: store
|
||||
.contacts()
|
||||
.iter()
|
||||
.map(|contact| contact.user.github_login.clone())
|
||||
.map(|contact| contact.user.github_login.clone().to_string())
|
||||
.collect(),
|
||||
outgoing_requests: store
|
||||
.outgoing_contact_requests()
|
||||
.iter()
|
||||
.map(|user| user.github_login.clone())
|
||||
.map(|user| user.github_login.clone().to_string())
|
||||
.collect(),
|
||||
incoming_requests: store
|
||||
.incoming_contact_requests()
|
||||
.iter()
|
||||
.map(|user| user.github_login.clone())
|
||||
.map(|user| user.github_login.clone().to_string())
|
||||
.collect(),
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue