web: style tag list
This commit is contained in:
parent
c27bcac549
commit
6b3567fb1b
@ -1050,9 +1050,9 @@ pub fn tags(model: &Model) -> Node<Msg> {
|
|||||||
attrs! {
|
attrs! {
|
||||||
At::Href => href
|
At::Href => href
|
||||||
},
|
},
|
||||||
(0..indent).map(|_| span![C!["NOTPORTED", "tag-indent"], ""]),
|
(0..indent).map(|_| span![C!["pl-4"], ""]),
|
||||||
i![
|
i![
|
||||||
C!["NOTPORTED", "tag-tag", "fa-solid", "fa-tag"],
|
C!["px-1", "fa-solid", "fa-tag"],
|
||||||
style! {
|
style! {
|
||||||
//"--fa-primary-color" => t.fg_color,
|
//"--fa-primary-color" => t.fg_color,
|
||||||
St::Color => t.bg_color,
|
St::Color => t.bg_color,
|
||||||
@ -1112,13 +1112,11 @@ pub fn tags(model: &Model) -> Node<Msg> {
|
|||||||
let tags_open = use_state(|| false);
|
let tags_open = use_state(|| false);
|
||||||
let force_tags_open = unread.is_empty();
|
let force_tags_open = unread.is_empty();
|
||||||
aside![
|
aside![
|
||||||
C!["NOTPORTED", "tags-menu", "menu"],
|
IF!(!unread.is_empty() => p![ "Unread"]),
|
||||||
IF!(!unread.is_empty() => p![C!["NOTPORTED","menu-label"], "Unread"]),
|
IF!(!unread.is_empty() => ul![view_tag_list(unread.into_iter(), true)]),
|
||||||
IF!(!unread.is_empty() => ul![C!["NOTPORTED","menu-list"], view_tag_list(unread.into_iter(),true)]),
|
|
||||||
p![
|
p![
|
||||||
C!["NOTPORTED", "menu-label"],
|
|
||||||
IF!(!force_tags_open =>
|
IF!(!force_tags_open =>
|
||||||
i![C!["NOTPORTED",
|
i![C![
|
||||||
"fa-solid",
|
"fa-solid",
|
||||||
if tags_open.get() {
|
if tags_open.get() {
|
||||||
"fa-angle-up"
|
"fa-angle-up"
|
||||||
@ -1132,7 +1130,6 @@ pub fn tags(model: &Model) -> Node<Msg> {
|
|||||||
})
|
})
|
||||||
],
|
],
|
||||||
ul![
|
ul![
|
||||||
C!["NOTPORTED", "menu-list"],
|
|
||||||
IF!(force_tags_open||tags_open.get() => model.tags.as_ref().map(|tags| view_tag_list(tags.iter(),false))),
|
IF!(force_tags_open||tags_open.get() => model.tags.as_ref().map(|tags| view_tag_list(tags.iter(),false))),
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user