Cleaned up some Author related displays.
It was determined to use the Author's desired name and no handle. The handle will only be used for unique linking. Also, the CyberMages LLC was dropped from the Author metadata until a company can be specified per Author. Not all users will be associated with CyberMages.
This commit is contained in:
@ -15,6 +15,13 @@ pub fn BlogItem(title: String, slug: String, author: String, summary: String,
|
||||
tags: Vec<String>)
|
||||
-> Element
|
||||
{
|
||||
let author_future = use_server_future(move ||
|
||||
{
|
||||
let handle: String = author.clone();
|
||||
|
||||
async move { get_author(handle).await }
|
||||
})?;
|
||||
|
||||
rsx!
|
||||
{
|
||||
article
|
||||
@ -42,7 +49,24 @@ pub fn BlogItem(title: String, slug: String, author: String, summary: String,
|
||||
}
|
||||
}
|
||||
|
||||
p { b { "Author: {author}" } }
|
||||
if let Some(Ok(Some(adventurer))) = (author_future.value())()
|
||||
{
|
||||
p
|
||||
{
|
||||
b
|
||||
{
|
||||
"Author: "
|
||||
a
|
||||
{
|
||||
href: "{adventurer.legend.profile}", "{adventurer.name}"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
p { "Loading author..." }
|
||||
}
|
||||
|
||||
p { "{summary}" }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user