Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 9 additions & 20 deletions shared/chat/audio/audio-recorder.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import {useConversationSendActions} from '@/chat/conversation/send-actions'
const {useSharedValue, Extrapolation, useAnimatedStyle} = Reanimated
const {interpolate, withSequence, withSpring, runOnJS} = Reanimated
const {useAnimatedReaction, withDelay, withTiming, interpolateColor, default: Animated} = Reanimated
const AnimatedBox2 = Animated.createAnimatedComponent(Kb.Box2)
type SVN = Reanimated.SharedValue<number>

type Props = {
Expand Down Expand Up @@ -668,18 +669,12 @@ const LockHint = (props: {fadeSV: SVN; lockedSV: SVN; dragXSV: SVN; dragYSV: SVN
})
return (
<>
<Kb.Box2Animated
direction="vertical"
style={[styles.lockHintStyle, arrowStyle as Kb.Styles._StylesCrossPlatform]}
>
<AnimatedBox2 direction="vertical" style={[styles.lockHintStyle, arrowStyle as Kb.Styles._StylesCrossPlatform]}>
<Kb.Icon type="iconfont-arrow-up" sizeType="Tiny" />
</Kb.Box2Animated>
<Kb.Box2Animated
direction="vertical"
style={[styles.lockHintStyle, lockStyle as Kb.Styles._StylesCrossPlatform]}
>
</AnimatedBox2>
<AnimatedBox2 direction="vertical" style={[styles.lockHintStyle, lockStyle as Kb.Styles._StylesCrossPlatform]}>
<Kb.Icon type="iconfont-lock" />
</Kb.Box2Animated>
</AnimatedBox2>
</>
)
}
Expand Down Expand Up @@ -749,18 +744,12 @@ const CancelHint = (props: {fadeSV: SVN; dragXSV: SVN; lockedSV: SVN; onCancel:

return (
<>
<Kb.Box2Animated
direction="vertical"
style={[styles.cancelHintStyle, arrowStyle as Kb.Styles._StylesCrossPlatform]}
>
<AnimatedBox2 direction="vertical" style={[styles.cancelHintStyle, arrowStyle as Kb.Styles._StylesCrossPlatform]}>
<Kb.Icon sizeType="Tiny" type={'iconfont-arrow-left'} />
</Kb.Box2Animated>
<Kb.Box2Animated
direction="vertical"
style={[styles.cancelHintStyle, closeStyle as Kb.Styles._StylesCrossPlatform]}
>
</AnimatedBox2>
<AnimatedBox2 direction="vertical" style={[styles.cancelHintStyle, closeStyle as Kb.Styles._StylesCrossPlatform]}>
<Kb.Icon sizeType="Tiny" type={'iconfont-close'} color={Kb.Styles.globalColors.black_20} />
</Kb.Box2Animated>
</AnimatedBox2>
<AnimatedText
type="BodySmallPrimaryLink"
onClick={onCancel}
Expand Down
2 changes: 1 addition & 1 deletion shared/chat/conversation/info-panel/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ const TeamHeader = (props: {conversationIDKey: T.Chat.ConversationIDKey}) => {
{popup}
{isSmallTeam ? (
<>
<Kb.ConnectedNameWithIcon
<Kb.NameWithIcon
containerStyle={styles.flexOne}
horizontal={true}
teamname={teamname}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import * as Chat from '@/constants/chat'
import type * as React from 'react'
import * as T from '@/constants/types'
import * as Kb from '@/common-adapters'
import TimelineMarker from './timeline-marker'
import UserNotice from '../user-notice'
import * as FS from '@/constants/fs'
import {useCurrentUserState} from '@/stores/current-user'
Expand Down Expand Up @@ -122,7 +123,7 @@ const GitPushDefault = (props: PushDefaultProps) => {
<Kb.Box2 direction="vertical" alignSelf="flex-start">
{(commitRef.commits || []).map((commit, i) => (
<Kb.Box2 direction="horizontal" key={commit.commitHash} alignSelf="flex-start">
<Kb.TimelineMarker
<TimelineMarker
idx={i}
max={commitRef.commits ? commitRef.commits.length - 1 : 0}
style={styles.marker}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import {Box2} from './box'
import {Box2} from '@/common-adapters'
import * as Styles from '@/styles'
import {timeline_grey} from './timeline-marker.meta'

const Kb = {
Box2,
}
const timeline_grey = '#D3DCE2'

const Kb = {Box2}

export type Props = {
idx: number
Expand Down
8 changes: 0 additions & 8 deletions shared/common-adapters/box.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import type * as React from 'react'
import * as Styles from '@/styles'
import {View} from 'react-native'
import Reanimated from 'react-native-reanimated'
import type {MeasureRef} from '@/common-adapters/measure-ref'
import type {NativeSyntheticEvent} from 'react-native'
import './box.css'
Expand Down Expand Up @@ -253,13 +252,6 @@ export const Box2 = (p: Box2Props & {ref?: React.Ref<MeasureRef>}) => {
return <View {...props} testID={testID} ref={ref as React.Ref<View>} />
}

export const Box2Animated = (p: Box2Props & {ref?: React.Ref<MeasureRef>}) => {
if (!isMobile) return <Box2 {...p} />
const {ref, ...rest} = p
const props = box2SharedProps(rest)
return <Reanimated.View {...props} ref={ref as React.Ref<View>} />
}

const common = {
alignItems: 'stretch',
justifyContent: 'flex-start',
Expand Down
14 changes: 1 addition & 13 deletions shared/common-adapters/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,22 +8,15 @@ export type {AnimationType} from './animation'
export const LayoutAnimation: typeof NativeLayoutAnimation = isMobile
? NativeLayoutAnimation
: ({} as typeof NativeLayoutAnimation)
export const ReAnimated = {}

export {
BottomSheetModal,
BottomSheetBackdrop,
BottomSheetScrollView,
type BottomSheetBackdropProps,
} from './popup/bottom-sheet'
export {default as Animation} from './animation'
export {default as Avatar} from './avatar/index'
export {default as AvatarLine} from './avatar/avatar-line'
export {BottomAccessory} from './bottom-accessory'
export {default as BackButton} from './back-button'
export {default as Badge} from './badge'
export {Banner, BannerParagraph} from './banner'
export {Box2, Box2Animated} from './box'
export {Box2} from './box'
export type {LayoutEvent} from './box'
export type {MeasureRef} from './measure-ref'
export {default as ButtonBar} from './button-bar'
Expand Down Expand Up @@ -65,12 +58,9 @@ export {default as LoadingLine} from './loading-line'
export {default as Markdown} from './markdown'
export {default as Meta} from './meta'
export {default as NameWithIcon} from './name-with-icon'
export {default as ConnectedNameWithIcon} from './name-with-icon'
export {default as Popup, type PopupProps} from './popup/index'
export {default as PhoneInput} from './phone-input'
export {default as Placeholder} from './placeholder'
export {default as PlatformIcon} from './platform-icon'
export {default as ProfileCard} from './profile-card'
export {default as ProgressBar} from './progress-bar'
export {default as ProgressIndicator} from './progress-indicator'
export {default as ProofBrokenBanner} from './proof-broken-banner'
Expand All @@ -86,12 +76,10 @@ export {default as ScrollView, type ScrollViewRef} from './scroll-view'
export {default as SectionList, type SectionListRef, type SectionType} from './section-list'
export {default as Switch} from './switch'
export {default as Tabs} from './tabs'
export {default as TeamWithPopup} from './team-with-popup'
export {default as Text} from './text'
export {useClickURL} from './text-url'
export {default as Toast} from './toast'
export {default as SimpleToast} from './simple-toast'
export {default as TimelineMarker} from './timeline-marker'
export {default as ConnectedUsernames} from './usernames'
export {default as WaitingButton} from './waiting-button'
export {default as WaveButton} from './wave-button'
Expand Down
152 changes: 0 additions & 152 deletions shared/common-adapters/team-with-popup.tsx

This file was deleted.

1 change: 0 additions & 1 deletion shared/common-adapters/timeline-marker.meta.tsx

This file was deleted.

2 changes: 1 addition & 1 deletion shared/people/follow-suggestions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const FollowSuggestions = (props: Props) => (
contentContainerStyle={styles.scrollViewContainer}
>
{props.suggestions.map(suggestion => (
<Kb.ConnectedNameWithIcon
<Kb.NameWithIcon
key={suggestion.username}
username={suggestion.username}
metaOne={suggestion.fullName}
Expand Down
7 changes: 4 additions & 3 deletions shared/profile/generic/proofs-list.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import * as C from '@/constants'
import * as Kb from '@/common-adapters'
import PlatformIcon from '../platform-icon'
import * as React from 'react'
import * as T from '@/constants/types'
import {makeInsertMatcher} from '@/util/string'
Expand Down Expand Up @@ -723,7 +724,7 @@ const EnterUsername = ({
{pt.headerText}
</Kb.Text>
)}
<Kb.PlatformIcon
<PlatformIcon
style={styles.centered}
platform={platform}
overlay="icon-proof-unfinished"
Expand Down Expand Up @@ -942,7 +943,7 @@ const PostProof = ({
</Kb.Text>
</Kb.Box2>
)}
<Kb.PlatformIcon
<PlatformIcon
platform={step.platform}
style={styles.center}
overlay="icon-proof-unfinished"
Expand Down Expand Up @@ -1020,7 +1021,7 @@ const ConfirmOrPending = ({
<Kb.Text negative={true} type="BodySemibold">
{title}
</Kb.Text>
<Kb.PlatformIcon
<PlatformIcon
style={styles.center}
platform={step.platform}
overlay={platformIconOverlay}
Expand Down
7 changes: 4 additions & 3 deletions shared/profile/pgp/choice/index.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import * as Kb from '@/common-adapters'
import PlatformIcon from '@/profile/platform-icon'
import * as C from '@/constants'
import * as React from 'react'
import * as T from '@/constants/types'
Expand Down Expand Up @@ -186,7 +187,7 @@ export default function Choice() {
return (
<>
<Kb.Box2 direction="vertical" fullWidth={true} gap="tiny" flex={1}>
<Kb.PlatformIcon platform="pgp" overlay="icon-proof-unfinished" style={styles.centered} />
<PlatformIcon platform="pgp" overlay="icon-proof-unfinished" style={styles.centered} />
<Kb.Text type="BodySemibold" style={styles.centered}>
Fill in your public info.
</Kb.Text>
Expand Down Expand Up @@ -235,7 +236,7 @@ export default function Choice() {
case 'generate':
return (
<Kb.Box2 direction="vertical" gap="small" alignItems="center">
<Kb.PlatformIcon platform="pgp" overlay="icon-proof-unfinished" />
<PlatformIcon platform="pgp" overlay="icon-proof-unfinished" />
<Kb.Text type="Header">Generating your unique key...</Kb.Text>
<Kb.Text type="Body">
Math time! You are about to discover a 4096-bit key pair.
Expand Down Expand Up @@ -278,7 +279,7 @@ const Finished = (props: {

return (
<Kb.Box2 direction="vertical" alignItems="center" gap="tiny">
<Kb.PlatformIcon platform="pgp" overlay="icon-proof-success" />
<PlatformIcon platform="pgp" overlay="icon-proof-success" />
<Kb.Text type="Header">Here is your unique public key!</Kb.Text>
<Kb.Text type="Body">
{'Your private key has been written to Keybase\'s local keychain. You can learn to use it with `keybase pgp help` from your terminal. If you have GPG installed, it has also been written to GPG\'s keychain.'}
Expand Down
Loading