The SPA now sends the user to a new /login page whenever an API call answers 401, remembering the page they were on. The OIDC callback always lands back on the configured post-login redirect, so the saved page is restored client-side once a session exists. - auth: save/restore the return path in sessionStorage; defer the navigation so the failing request can finish first - api: centralize 401 handling (me() still treats 401 as logged out) - login page + shared login card, extracted from the lobby - guard async signal writes so an in-flight request cannot touch a page unmounted by the redirect
24 lines
611 B
TOML
24 lines
611 B
TOML
[package]
|
|
name = "tavolo-web"
|
|
version = "0.1.0"
|
|
edition = "2021"
|
|
description = "Sycamore/WASM frontend for the tavolo card-game platform"
|
|
|
|
[dependencies]
|
|
sycamore = "0.9"
|
|
sycamore-router = "0.9"
|
|
gloo-net = { version = "0.6", features = ["websocket"] }
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
wasm-bindgen = "0.2"
|
|
wasm-bindgen-futures = "0.4"
|
|
futures = "0.3"
|
|
web-sys = { version = "0.3", features = ["Window", "Location", "Clipboard", "Navigator", "console", "Storage"] }
|
|
js-sys = "0.3"
|
|
gloo-timers = "0.3"
|
|
console_error_panic_hook = "0.1"
|
|
|
|
[profile.release]
|
|
opt-level = "z"
|
|
lto = true
|