Remove unused code
This commit is contained in:
parent
c466e0c279
commit
44f6d9cda0
1 changed files with 3 additions and 28 deletions
|
@ -25,20 +25,10 @@ import getHTMLText from '../utils/getHTMLText';
|
||||||
import niceDateTime from '../utils/nice-date-time';
|
import niceDateTime from '../utils/nice-date-time';
|
||||||
import shortenNumber from '../utils/shorten-number';
|
import shortenNumber from '../utils/shorten-number';
|
||||||
import showToast from '../utils/show-toast';
|
import showToast from '../utils/show-toast';
|
||||||
import states, { getStatus, saveStatus, statusKey } from '../utils/states';
|
import states, { statusKey } from '../utils/states';
|
||||||
import store from '../utils/store';
|
import store from '../utils/store';
|
||||||
import {
|
import { getCurrentAccountNS } from '../utils/store-utils';
|
||||||
getCurrentAccount,
|
import { assignFollowedTags } from '../utils/timeline-utils';
|
||||||
getCurrentAccountNS,
|
|
||||||
getCurrentInstance,
|
|
||||||
getCurrentInstanceConfiguration,
|
|
||||||
} from '../utils/store-utils';
|
|
||||||
import {
|
|
||||||
assignFollowedTags,
|
|
||||||
clearFollowedTagsState,
|
|
||||||
dedupeBoosts,
|
|
||||||
} from '../utils/timeline-utils';
|
|
||||||
import useScrollFn from '../utils/useScrollFn';
|
|
||||||
import useTitle from '../utils/useTitle';
|
import useTitle from '../utils/useTitle';
|
||||||
|
|
||||||
const FILTER_CONTEXT = 'home';
|
const FILTER_CONTEXT = 'home';
|
||||||
|
@ -469,20 +459,6 @@ function Catchup() {
|
||||||
}, [posts, filteredPosts]);
|
}, [posts, filteredPosts]);
|
||||||
|
|
||||||
const scrollableRef = useRef(null);
|
const scrollableRef = useRef(null);
|
||||||
const headerRef = useRef(null);
|
|
||||||
|
|
||||||
useScrollFn(
|
|
||||||
{
|
|
||||||
scrollableRef,
|
|
||||||
},
|
|
||||||
({ scrollDirection, nearReachStart }) => {
|
|
||||||
if (headerRef.current) {
|
|
||||||
const hiddenUI = scrollDirection === 'end' && !nearReachStart;
|
|
||||||
headerRef.current.hidden = hiddenUI;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
[],
|
|
||||||
);
|
|
||||||
|
|
||||||
// if range value exceeded lastCatchupEndAt, show error
|
// if range value exceeded lastCatchupEndAt, show error
|
||||||
const lastCatchupRange = useMemo(() => {
|
const lastCatchupRange = useMemo(() => {
|
||||||
|
@ -500,7 +476,6 @@ function Catchup() {
|
||||||
>
|
>
|
||||||
<div class="timeline-deck deck wide">
|
<div class="timeline-deck deck wide">
|
||||||
<header
|
<header
|
||||||
ref={headerRef}
|
|
||||||
class={`${uiState === 'loading' ? 'loading' : ''}`}
|
class={`${uiState === 'loading' ? 'loading' : ''}`}
|
||||||
onClick={(e) => {
|
onClick={(e) => {
|
||||||
if (!e.target.closest('a, button')) {
|
if (!e.target.closest('a, button')) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue