Compare commits

..

No commits in common. "11c31f7f4275fa6c10ade4b6867c61442bc0e9da" and "69f7f37a2ce917763a4d4bc10a86bd66fff1958f" have entirely different histories.

2 changed files with 37 additions and 40 deletions

View file

@ -38,6 +38,7 @@ export function useTimeline(
async ([tl], info) => { async ([tl], info) => {
let tlChanged = false; let tlChanged = false;
if (otl !== tl) { if (otl !== tl) {
console.debug("timeline reset");
npager = opager = undefined; npager = opager = undefined;
otl = tl; otl = tl;
tlChanged = true; tlChanged = true;

View file

@ -11,7 +11,7 @@ import {
Suspense, Suspense,
Match, Match,
Switch as JsSwitch, Switch as JsSwitch,
ErrorBoundary, ErrorBoundary
} from "solid-js"; } from "solid-js";
import { useDocumentTitle } from "../utils"; import { useDocumentTitle } from "../utils";
import { type mastodon } from "masto"; import { type mastodon } from "masto";
@ -126,11 +126,9 @@ const TimelinePanel: Component<{
}; };
return ( return (
<ErrorBoundary <ErrorBoundary fallback={(err, reset) => {
fallback={(err, reset) => { return <p>Oops: {String(err)}</p>
return <p>Oops: {String(err)}</p>; }}>
}}
>
<PullDownToRefresh <PullDownToRefresh
linkedElement={scrollLinked()} linkedElement={scrollLinked()}
loading={snapshot.loading} loading={snapshot.loading}
@ -406,42 +404,40 @@ const Home: ParentComponent = (props) => {
} }
> >
<TimeSourceProvider value={now}> <TimeSourceProvider value={now}>
<Show when={!!client()}> <div class="panel-list" ref={panelList!}>
<div class="panel-list" ref={panelList!}> <div class="tab-panel">
<div class="tab-panel"> <div>
<div> <TimelinePanel
<TimelinePanel client={client()}
client={client()} name="home"
name="home" prefetch={prefetching()}
prefetch={prefetching()} openFullScreenToot={openFullScreenToot}
openFullScreenToot={openFullScreenToot} />
/>
</div>
</div> </div>
<div class="tab-panel">
<div>
<TimelinePanel
client={client()}
name="trends"
prefetch={prefetching()}
openFullScreenToot={openFullScreenToot}
fullRefetch={120}
/>
</div>
</div>
<div class="tab-panel">
<div>
<TimelinePanel
client={client()}
name="public"
prefetch={prefetching()}
openFullScreenToot={openFullScreenToot}
/>
</div>
</div>
<div></div>
</div> </div>
</Show> <div class="tab-panel">
<div>
<TimelinePanel
client={client()}
name="trends"
prefetch={prefetching()}
openFullScreenToot={openFullScreenToot}
fullRefetch={120}
/>
</div>
</div>
<div class="tab-panel">
<div>
<TimelinePanel
client={client()}
name="public"
prefetch={prefetching()}
openFullScreenToot={openFullScreenToot}
/>
</div>
</div>
<div></div>
</div>
</TimeSourceProvider> </TimeSourceProvider>
<Suspense> <Suspense>
<HeroSourceProvider value={[heroSrc, setHeroSrc]}> <HeroSourceProvider value={[heroSrc, setHeroSrc]}>