first prototype of StackedRouter
This commit is contained in:
parent
607fa64c05
commit
0710aaf4f3
21 changed files with 442 additions and 109 deletions
|
@ -1,4 +1,6 @@
|
|||
.Profile {
|
||||
height: 100%;
|
||||
|
||||
.intro {
|
||||
background-color: var(--tutu-color-surface-d);
|
||||
color: var(--tutu-color-on-surface);
|
||||
|
|
|
@ -45,7 +45,7 @@ import {
|
|||
Verified,
|
||||
} from "@suid/icons-material";
|
||||
import { Body2, Title } from "../material/typography";
|
||||
import { useNavigate, useParams } from "@solidjs/router";
|
||||
import { useParams } from "@solidjs/router";
|
||||
import { useSessionForAcctStr } from "../masto/clients";
|
||||
import { resolveCustomEmoji } from "../masto/toot";
|
||||
import { FastAverageColor } from "fast-average-color";
|
||||
|
@ -57,9 +57,10 @@ import TootFilterButton from "./TootFilterButton";
|
|||
import Menu, { createManagedMenuState } from "../material/Menu";
|
||||
import { share } from "../platform/share";
|
||||
import "./Profile.css";
|
||||
import { useNavigator } from "../platform/StackedRouter";
|
||||
|
||||
const Profile: Component = () => {
|
||||
const navigate = useNavigate();
|
||||
const { pop } = useNavigator();
|
||||
const params = useParams<{ acct: string; id: string }>();
|
||||
const acctText = () => decodeURIComponent(params.acct);
|
||||
const session = useSessionForAcctStr(acctText);
|
||||
|
@ -209,11 +210,7 @@ const Profile: Component = () => {
|
|||
paddingTop: "var(--safe-area-inset-top)",
|
||||
}}
|
||||
>
|
||||
<IconButton
|
||||
color="inherit"
|
||||
onClick={[navigate, -1]}
|
||||
aria-label="Close"
|
||||
>
|
||||
<IconButton color="inherit" onClick={[pop, 1]} aria-label="Close">
|
||||
<Close />
|
||||
</IconButton>
|
||||
<Title
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue