diff --git a/crates/notedeck_columns/src/relay_config.rs b/crates/notedeck_columns/src/relay_config.rs index 0de62f7..79f406a 100644 --- a/crates/notedeck_columns/src/relay_config.rs +++ b/crates/notedeck_columns/src/relay_config.rs @@ -64,7 +64,7 @@ impl RelayConfig { impl Default for RelayConfig { fn default() -> Self { - Self::default_relays() + Self::new() } } diff --git a/crates/notedeck_columns/src/timeline/kind.rs b/crates/notedeck_columns/src/timeline/kind.rs index 6bfa2dd..853dab9 100644 --- a/crates/notedeck_columns/src/timeline/kind.rs +++ b/crates/notedeck_columns/src/timeline/kind.rs @@ -515,7 +515,7 @@ impl TimelineKind { } TimelineKind::Hashtag(hashtag) => { - let filters = hashtag + let mut filters: Vec = hashtag .iter() .filter(|tag| !tag.is_empty()) .map(|tag| { @@ -525,7 +525,17 @@ impl TimelineKind { .tags([tag.to_lowercase().as_str()], 't') .build() }) - .collect::>(); + .collect(); + + // If no valid hashtags were provided, show all notes + if filters.is_empty() { + filters.push( + Filter::new() + .kinds([1]) + .limit(filter::default_limit()) + .build() + ); + } FilterState::ready(filters) } diff --git a/crates/notedeck_columns/src/ui/channel_dialog.rs b/crates/notedeck_columns/src/ui/channel_dialog.rs index 8b98c22..0d41513 100644 --- a/crates/notedeck_columns/src/ui/channel_dialog.rs +++ b/crates/notedeck_columns/src/ui/channel_dialog.rs @@ -6,6 +6,7 @@ pub struct ChannelDialog { pub name: String, pub hashtags: String, pub is_open: bool, + pub focus_requested: bool, } pub enum ChannelDialogAction { @@ -19,6 +20,7 @@ impl ChannelDialog { name: String::new(), hashtags: String::new(), is_open: false, + focus_requested: false, } } @@ -26,6 +28,7 @@ impl ChannelDialog { self.is_open = true; self.name.clear(); self.hashtags.clear(); + self.focus_requested = false; } pub fn close(&mut self) { @@ -70,8 +73,11 @@ impl ChannelDialog { .desired_width(f32::INFINITY), ); - // Auto-focus on name field when opened - name_response.request_focus(); + // Auto-focus on name field when first opened + if !self.focus_requested { + name_response.request_focus(); + self.focus_requested = true; + } ui.add_space(16.0);