fix: hide unavailable database type
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
- [x] feature: ability to give the connection configs a custom name (control how they're displayed in the sidebar)
|
||||
- [x] feature: ability to remove a database connection
|
||||
- [x] feature: line numbers in gutter of sql editor
|
||||
- [ ] bug: database type should display nothing instead of `-` when no database is connected. (it should only show the type when it's available)
|
||||
- [x] bug: database type should display nothing instead of `-` when no database is connected. (it should only show the type when it's available)
|
||||
+1
-1
@@ -55,7 +55,7 @@ pub fn run(terminal: &mut DefaultTerminal, initial: Option<Database>) -> Result<
|
||||
&& browser.as_ref().is_some_and(App::query_insert_mode)
|
||||
};
|
||||
let name = connection_label.as_deref().unwrap_or_else(|| browser.as_ref().map_or("Not connected", App::database_name));
|
||||
draw_bars(frame, top, bottom, browser.as_ref().map_or("—", App::provider), name, insert, position);
|
||||
draw_bars(frame, top, bottom, browser.as_ref().map_or("", App::provider), name, insert, position);
|
||||
let [sidebar, content] = Layout::horizontal([Constraint::Length(32), Constraint::Min(1)])
|
||||
.areas(workspace);
|
||||
let items = entries.iter().map(|entry| {
|
||||
|
||||
Reference in New Issue
Block a user