Cleanup
parent
f5d1a5c38d
commit
efbef238a8
|
@ -1,16 +1,16 @@
|
||||||
import React, {useEffect, useState, useRef} from 'react'
|
import React, {useEffect, useState, useRef} from 'react'
|
||||||
import {StyleSheet, Text, TextInput, View} from 'react-native'
|
import {StyleSheet, Text, TextInput, View} from 'react-native'
|
||||||
import {useSharedValue} from 'react-native-reanimated'
|
|
||||||
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
|
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
|
||||||
import {ProfileFollows as ProfileFollowsComponent} from '../com/profile/ProfileFollows'
|
import {ProfileFollows as ProfileFollowsComponent} from '../com/profile/ProfileFollows'
|
||||||
import {Selector} from '../com/util/Selector'
|
import {Selector} from '../com/util/Selector'
|
||||||
import {colors} from '../lib/styles'
|
import {colors} from '../lib/styles'
|
||||||
import {ScreenParams} from '../routes'
|
import {ScreenParams} from '../routes'
|
||||||
import {useStores} from '../../state'
|
import {useStores} from '../../state'
|
||||||
|
import {useAnimatedValue} from '../lib/useAnimatedValue'
|
||||||
|
|
||||||
export const Contacts = ({navIdx, visible, params}: ScreenParams) => {
|
export const Contacts = ({navIdx, visible, params}: ScreenParams) => {
|
||||||
const store = useStores()
|
const store = useStores()
|
||||||
const selectorInterp = useSharedValue(0)
|
const selectorInterp = useAnimatedValue(0)
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (visible) {
|
if (visible) {
|
||||||
|
@ -45,7 +45,7 @@ export const Contacts = ({navIdx, visible, params}: ScreenParams) => {
|
||||||
<Selector
|
<Selector
|
||||||
items={['All', 'Following', 'Scenes']}
|
items={['All', 'Following', 'Scenes']}
|
||||||
selectedIndex={0}
|
selectedIndex={0}
|
||||||
swipeGestureInterp={selectorInterp}
|
panX={selectorInterp}
|
||||||
/>
|
/>
|
||||||
{!!store.me.handle && <ProfileFollowsComponent name={store.me.handle} />}
|
{!!store.me.handle && <ProfileFollowsComponent name={store.me.handle} />}
|
||||||
</View>
|
</View>
|
||||||
|
|
|
@ -16,13 +16,12 @@ import {
|
||||||
import {ScreenContainer, Screen} from 'react-native-screens'
|
import {ScreenContainer, Screen} from 'react-native-screens'
|
||||||
import LinearGradient from 'react-native-linear-gradient'
|
import LinearGradient from 'react-native-linear-gradient'
|
||||||
import {useSafeAreaInsets} from 'react-native-safe-area-context'
|
import {useSafeAreaInsets} from 'react-native-safe-area-context'
|
||||||
import Animated, {
|
import {
|
||||||
Easing,
|
Easing,
|
||||||
useSharedValue,
|
useSharedValue,
|
||||||
useAnimatedStyle,
|
useAnimatedStyle,
|
||||||
withTiming,
|
withTiming,
|
||||||
runOnJS,
|
runOnJS,
|
||||||
interpolate,
|
|
||||||
} from 'react-native-reanimated'
|
} from 'react-native-reanimated'
|
||||||
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
|
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
|
||||||
import {IconProp} from '@fortawesome/fontawesome-svg-core'
|
import {IconProp} from '@fortawesome/fontawesome-svg-core'
|
||||||
|
|
Loading…
Reference in New Issue