diff options
Diffstat (limited to 'ui')
| -rw-r--r-- | ui/client-style/src/layout.css | 4 | ||||
| -rw-r--r-- | ui/src/components/node_page.rs | 24 |
2 files changed, 19 insertions, 9 deletions
diff --git a/ui/client-style/src/layout.css b/ui/client-style/src/layout.css index a7f0b28..6eeea1c 100644 --- a/ui/client-style/src/layout.css +++ b/ui/client-style/src/layout.css @@ -141,10 +141,10 @@ summary h3 { width: max(10em, 40%); } -table.striped tr:nth-child(2n) { +table tr:nth-child(2n) { background-color: #fff2; } -table.striped td { +table td { border: none; padding: 5px; } diff --git a/ui/src/components/node_page.rs b/ui/src/components/node_page.rs index 38d82ba..9be20f2 100644 --- a/ui/src/components/node_page.rs +++ b/ui/src/components/node_page.rs @@ -118,13 +118,11 @@ markup::define! { summary { @tr(ri.lang, "node.external_ids") } table { @for (key, value) in idents.entries::<&str>() { tr { - tr { - td { @tr(ri.lang, &format!("tag.iden.{key}")) } - @if let Some(url) = external_id_url(key, value) { - td { a[href=url] { pre { @value } } } - } else { - td { pre { @value } } - } + td { @tr(ri.lang, &format!("tag.iden.{key}")) } + @if let Some(url) = external_id_url(key, value) { + td { a[href=url] { pre { @value } } } + } else { + td { pre { @value } } } }} } @@ -138,6 +136,18 @@ markup::define! { }} } } + @if node.has(NO_METASOURCE.0) { + details { + summary { @tr(ri.lang, "tag.msrc") } + table { + tr { th {"Attribute"} th {"Source"} } + @for (key, source) in node.get(NO_METASOURCE).unwrap_or_default().entries::<Tag>() { tr { + td { @tr(ri.lang, &format!("tag.{key}")) } + td { @tr(ri.lang, &format!("tag.msrc.{source}")) } + }} + } + } + } } // @if matches!(node.kind, NodeKind::Collection | NodeKind::Channel) { // @NodeFilterSortForm { f: filter, lang } |