pinakes-tui: add book management view and api key authentication
Signed-off-by: NotAShelf <raf@notashelf.dev> Change-Id: I20f205d9e06a93a89e8f4433ed6f80576a6a6964
This commit is contained in:
parent
3d9f8933d2
commit
66861b8a20
18 changed files with 917 additions and 251 deletions
|
|
@ -29,11 +29,10 @@ pub fn render(f: &mut Frame, state: &AppState, area: Rect) {
|
|||
} else {
|
||||
&item.media_id
|
||||
};
|
||||
let text = if let Some(ref artist) = item.artist {
|
||||
format!("{prefix}{} - {} [{}]", item.title, artist, id_suffix)
|
||||
} else {
|
||||
format!("{prefix}{} [{}]", item.title, id_suffix)
|
||||
};
|
||||
let text = item.artist.as_ref().map_or_else(
|
||||
|| format!("{prefix}{} [{id_suffix}]", item.title),
|
||||
|artist| format!("{prefix}{} - {artist} [{id_suffix}]", item.title),
|
||||
);
|
||||
|
||||
let style = if is_selected {
|
||||
Style::default()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue