examples: fix hackernews examples oops

This commit is contained in:
Greg Johnston 2023-09-29 13:36:13 -04:00
parent fb914e1a50
commit f7adf6f73d
3 changed files with 7 additions and 13 deletions

View file

@ -16,10 +16,7 @@ actix-web = { version = "4", optional = true, features = ["macros"] }
console_log = "1"
console_error_panic_hook = "0.1"
cfg-if = "1"
leptos = { path = "../../leptos", features = [
"nightly",
"experimental-islands",
] }
leptos = { path = "../../leptos", features = ["nightly"] }
leptos_meta = { path = "../../meta", features = ["nightly"] }
leptos_actix = { path = "../../integrations/actix", optional = true }
leptos_router = { path = "../../router", features = ["nightly"] }

View file

@ -41,13 +41,11 @@ pub fn Stories() -> impl IntoView {
};
view! {
<div class="news-view">
<div class="news-list-nav">
<span>
{move || if page() > 1 {
view! {
<a class="page-link"
href=move || format!("/{}?page={}", story_type(), page() - 1)
attr:aria_label="Previous Page"
@ -57,7 +55,6 @@ pub fn Stories() -> impl IntoView {
}.into_any()
} else {
view! {
<span class="page-link disabled" aria-hidden="true">
"< prev"
</span>

View file

@ -70,7 +70,7 @@ pub fn Stories() -> impl IntoView {
>
<a href=move || format!("/{}?page={}", story_type(), page() + 1)
aria-label="Next Page"
>=
>
"more >"
</a>
</span>