This commit is contained in:
2026-10-22 15:58:24 +07:00
parent 49f2d9edc1
commit bebb4cebbf
25 changed files with 147 additions and 100 deletions
+5 -10
View File
@@ -1,8 +1,8 @@
use gpui_kit::component::button::{Button, ButtonCustomVariant, ButtonVariants};
use gpui_kit::component::{Sizable, v_flex};
use std::time::{SystemTime, UNIX_EPOCH};
use gpui::{AnyElement, App, IntoElement, ParentElement, SharedString, Styled, Window, img};
use gpui_kit::component::button::{Button, ButtonVariants};
use gpui_kit::component::{Sizable, v_flex};
use crate::dialogs::import;
@@ -16,11 +16,12 @@ pub(super) fn pick_banner() -> SharedString {
.map(|elapsed| elapsed.subsec_nanos())
.unwrap_or_default();
let index = nanos as usize % SIGNED_OUT_BANNERS.len();
SIGNED_OUT_BANNERS[index].into()
}
/// The headline and identity import shown while signed out.
pub(super) fn render_signed_out(_window: &mut Window, cx: &mut App) -> AnyElement {
pub(super) fn render_signed_out(_window: &mut Window, _cx: &mut App) -> AnyElement {
v_flex()
.size_full()
.justify_end()
@@ -30,13 +31,7 @@ pub(super) fn render_signed_out(_window: &mut Window, cx: &mut App) -> AnyElemen
.child(
Button::new("import")
.label("Import Identity")
.custom(
ButtonCustomVariant::new(cx)
.color(gpui::white())
.foreground(gpui::black())
.hover(gpui::white().opacity(0.9))
.active(gpui::white().opacity(0.8)),
)
.primary()
.large()
.on_click(|_, window, cx| {
import::open(window, cx);