Skip to content

Commit

Permalink
don't put experimental stuff in tutorial ascii table
Browse files Browse the repository at this point in the history
  • Loading branch information
kaikalii committed Nov 30, 2024
1 parent 965d461 commit 0a7a223
Showing 1 changed file with 13 additions and 11 deletions.
24 changes: 13 additions & 11 deletions site/src/tutorial.rs
Original file line number Diff line number Diff line change
Expand Up @@ -195,18 +195,20 @@ fn TutorialIntroduction() -> impl IntoView {
fn TutorialBasic() -> impl IntoView {
use Primitive::*;

let primitive_table: Vec<_> = Primitive::all()
let primitive_table: Vec<_> = Primitive::non_deprecated()
.filter_map(|p| {
if let (Some(ascii), Some(unicode)) = (p.ascii(), p.glyph()) {
if ascii.to_string() != unicode.to_string() {
return Some(view! {
<tr>
<td><code>{ p.name() }</code></td>
<td><code>{ ascii.to_string() }</code></td>
<td><Prim prim=p glyph_only=true/></td>
</tr>
});
}
if p.is_experimental() {
return None;
}
let (ascii, unicode) = (p.ascii()?, p.glyph()?);
if ascii.to_string() != unicode.to_string() {
return Some(view! {
<tr>
<td><code>{ p.name() }</code></td>
<td><code>{ ascii.to_string() }</code></td>
<td><Prim prim=p glyph_only=true/></td>
</tr>
});
}
None
})
Expand Down

0 comments on commit 0a7a223

Please sign in to comment.