TootList: mentions in toot links to profile page
All checks were successful
/ depoly (push) Successful in 1m17s

- bug: main toot in TootBottomSheet does not link
  profile
This commit is contained in:
thislight 2024-10-30 19:25:58 +08:00
parent 92cc451811
commit 31b27237cd
No known key found for this signature in database
GPG key ID: FCFE5192241CCD4E
5 changed files with 165 additions and 91 deletions

View file

@ -1,4 +1,5 @@
import {
catchError,
createRenderEffect,
createResource,
createSignal,
@ -77,13 +78,18 @@ const Profile: Component = () => {
);
onCleanup(() => obx.disconnect());
const [profile] = createResource(
const [profileErrorUncaught] = createResource(
() => [session().client, params.id] as const,
async ([client, id]) => {
return await client.v1.accounts.$select(id).fetch();
},
);
const profile = () =>
catchError(profileErrorUncaught, (err) => {
console.error(err);
});
const [recentTootFilter, setRecentTootFilter] = createSignal({
boost: false,
reply: true,
@ -271,7 +277,7 @@ const Profile: Component = () => {
ref={(e) => obx.observe(e)}
src={bannerImg()}
style={{
"object-fit": "contain",
"object-fit": "cover",
width: "100%",
height: "100%",
}}