chore: Fix focusd_border typo in #635 (#637)

This commit is contained in:
Jason Lee 2025-02-17 17:29:40 +08:00 committed by GitHub
parent fa1a7a85ba
commit 75212c3aba
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 5 additions and 5 deletions

View file

@ -658,7 +658,7 @@ where
Length::Definite(l) => this.flex_none().w(l),
Length::Auto => this.w_full(),
})
.when(outline_visible, |this| this.focusd_border(cx))
.when(outline_visible, |this| this.focused_border(cx))
.input_size(self.size)
.when(allow_open, |this| {
this.on_click(cx.listener(Self::toggle_menu))

View file

@ -1649,7 +1649,7 @@ impl Render for TextInput {
.border_1()
.rounded(cx.theme().radius)
.when(cx.theme().shadow, |this| this.shadow_sm())
.when(focused, |this| this.focusd_border(cx))
.when(focused, |this| this.focused_border(cx))
})
.when(prefix.is_none(), |this| this.input_pl(self.size))
.when(suffix.is_none(), |this| this.input_pr(self.size))

View file

@ -182,7 +182,7 @@ impl Render for NumberInput {
.border_color(cx.theme().input)
.border_1()
.rounded(cx.theme().radius)
.when(focused, |this| this.focusd_border(cx))
.when(focused, |this| this.focused_border(cx))
.child(
Button::new("minus")
.ghost()

View file

@ -106,7 +106,7 @@ pub trait StyledExt: Styled + Sized {
/// Render a border with a width of 1px, color ring color
#[inline]
fn focusd_border(self, cx: &App) -> Self {
fn focused_border(self, cx: &App) -> Self {
self.border_color(cx.theme().ring)
}

View file

@ -325,7 +325,7 @@ impl Render for DatePicker {
.cursor_pointer()
.overflow_hidden()
.input_text_size(self.size)
.when(is_focused, |this| this.focusd_border(cx))
.when(is_focused, |this| this.focused_border(cx))
.input_size(self.size)
.when(!self.open, |this| {
this.on_click(cx.listener(Self::toggle_calendar))