Generate more semantic HTML
Dependencies
- [2]
MIY7QPYKRefactor argument handling into a separate file - [3]
C73UJ7ZYCreate simple `xilem_html` demo - [4]
A4E5KLI2Turn arguments into sidebar - [5]
ALCCL4VKCreate basic styling
Change contents
- replacement in src/arg.rs at line 26
el::div((match supported_type_description {ArgType::String => "string",ArgType::Other => "other",},el::div("placeholder content").attr("class", "hover_content"),)).attr("class", "hoverable")el::span(match supported_type_description {ArgType::String => "string",ArgType::Other => "other",}) - edit in src/arg.rs at line 35
.map(el::span) - replacement in src/arg.rs at line 58
Some(el::div((Some(el::section(( - replacement in src/arg.rs at line 65
String::from(if let Ok(arg_matches) = state.arg_matches.as_ref() {el::span(if let Ok(arg_matches) = state.arg_matches.as_ref() { - edit in src/arg.rs at line 81
fn documentation(arg: &Arg) -> impl ViewSequence<Arg> {if let Some(short_help) = arg.get_help() {Some(el::details((el::summary(short_help.to_string()),arg.get_long_help().map(ToString::to_string).unwrap_or_default().strip_prefix(&short_help.to_string()).unwrap_or("No description provided").to_string(),)))} else {None}} - replacement in src/arg.rs at line 122
el::div((el::section(( - edit in src/arg.rs at line 127
el::br(()), - replacement in src/arg.rs at line 128
el::div((env(arg), aliases(arg))),env(arg),aliases(arg), - replacement in src/arg.rs at line 131
el::div((// One-line short helparg.get_help().map(|short_help| el::i(short_help.to_string())),el::br(()),// Long-form helparg.get_long_help().map(|long_help| el::q(long_help.to_string())),)),documentation(arg), - edit in index.html at line 5
.hoverable {position: relative;display: inline-block;padding-bottom: 5px;border-bottom: 2px dashed black;}.hoverable .hover_content {display: none;visibility: hidden;position: absolute;left: 125%;top: 0%;}.hoverable:hover .hover_content {display: block;visibility: visible;} - replacement in index.html at line 19
flex-shrink: 1;flex-wrap: nowrap;margin-right: 80%; - edit in index.html at line 29
blockquote {margin-left: 0px;padding-left: 5px;border-left: 3px solid #ccc;}section {display: flex;flex-direction: column;flex-wrap: nowrap;}