Bluesky app fork with some witchin' additions 💫
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Replace `import hairlineWidth =` with const (#4831)

* replace import with const

* just use `StyleSheet.hairlineWidth`

---------

Co-authored-by: Samuel Newman <10959775+mozzius@users.noreply.github.com>

authored by

Samuel Newman
Samuel Newman
and committed by
GitHub
401e92ed 00240b95

+81 -105
+5 -6
src/alf/atoms.ts
··· 2 2 3 3 import * as tokens from '#/alf/tokens' 4 4 import {native, web} from '#/alf/util/platform' 5 - import hairlineWidth = StyleSheet.hairlineWidth 6 5 7 6 export const atoms = { 8 7 /* ··· 284 283 borderWidth: 0, 285 284 }, 286 285 border: { 287 - borderWidth: hairlineWidth, 286 + borderWidth: StyleSheet.hairlineWidth, 288 287 }, 289 288 border_t: { 290 - borderTopWidth: hairlineWidth, 289 + borderTopWidth: StyleSheet.hairlineWidth, 291 290 }, 292 291 border_b: { 293 - borderBottomWidth: hairlineWidth, 292 + borderBottomWidth: StyleSheet.hairlineWidth, 294 293 }, 295 294 border_l: { 296 - borderLeftWidth: hairlineWidth, 295 + borderLeftWidth: StyleSheet.hairlineWidth, 297 296 }, 298 297 border_r: { 299 - borderRightWidth: hairlineWidth, 298 + borderRightWidth: StyleSheet.hairlineWidth, 300 299 }, 301 300 302 301 /*
+4 -5
src/view/com/composer/Composer.tsx
··· 99 99 import {useVideoState} from './videos/state' 100 100 import {VideoPreview} from './videos/VideoPreview' 101 101 import {VideoTranscodeProgress} from './videos/VideoTranscodeProgress' 102 - import hairlineWidth = StyleSheet.hairlineWidth 103 102 104 103 type CancelRef = { 105 104 onPressCancel: () => void ··· 763 762 764 763 const topBarAnimatedStyle = useAnimatedStyle(() => { 765 764 return { 766 - borderBottomWidth: hairlineWidth, 765 + borderBottomWidth: StyleSheet.hairlineWidth, 767 766 borderColor: interpolateColor( 768 767 hasScrolledTop.value, 769 768 [0, 1], ··· 773 772 }) 774 773 const bottomBarAnimatedStyle = useAnimatedStyle(() => { 775 774 return { 776 - borderTopWidth: hairlineWidth, 775 + borderTopWidth: StyleSheet.hairlineWidth, 777 776 borderColor: interpolateColor( 778 777 hasScrolledBottom.value, 779 778 [0, 1], ··· 855 854 marginBottom: 8, 856 855 }, 857 856 errorIcon: { 858 - borderWidth: hairlineWidth, 857 + borderWidth: StyleSheet.hairlineWidth, 859 858 borderColor: colors.red4, 860 859 color: colors.red4, 861 860 borderRadius: 30, ··· 891 890 paddingLeft: 7, 892 891 paddingRight: 16, 893 892 alignItems: 'center', 894 - borderTopWidth: hairlineWidth, 893 + borderTopWidth: StyleSheet.hairlineWidth, 895 894 }, 896 895 })
+1 -2
src/view/com/composer/Prompt.tsx
··· 9 9 import {useWebMediaQueries} from 'lib/hooks/useWebMediaQueries' 10 10 import {Text} from '../util/text/Text' 11 11 import {UserAvatar} from '../util/UserAvatar' 12 - import hairlineWidth = StyleSheet.hairlineWidth 13 12 14 13 export function ComposePrompt({onPressCompose}: {onPressCompose: () => void}) { 15 14 const {currentAccount} = useSession() ··· 49 48 paddingBottom: 10, 50 49 flexDirection: 'row', 51 50 alignItems: 'center', 52 - borderTopWidth: hairlineWidth, 51 + borderTopWidth: StyleSheet.hairlineWidth, 53 52 }, 54 53 labelMobile: { 55 54 paddingLeft: 12,
+3 -4
src/view/com/feeds/FeedSourceCard.tsx
··· 13 13 import {useLingui} from '@lingui/react' 14 14 15 15 import {logger} from '#/logger' 16 + import {shouldClickOpenNewTab} from '#/platform/urls' 16 17 import {FeedSourceInfo, useFeedSourceInfoQuery} from '#/state/queries/feed' 17 18 import { 18 19 useAddSavedFeedsMutation, ··· 32 33 import {RichText} from '#/components/RichText' 33 34 import {Text} from '../util/text/Text' 34 35 import {UserAvatar} from '../util/UserAvatar' 35 - import hairlineWidth = StyleSheet.hairlineWidth 36 - import {shouldClickOpenNewTab} from '#/platform/urls' 37 36 38 37 export function FeedSourceCard({ 39 38 feedUri, ··· 209 208 styles.container, 210 209 pal.border, 211 210 style, 212 - {borderTopWidth: hideTopBorder ? 0 : hairlineWidth}, 211 + {borderTopWidth: hideTopBorder ? 0 : StyleSheet.hairlineWidth}, 213 212 ]} 214 213 onPress={e => { 215 214 const shouldOpenInNewTab = shouldClickOpenNewTab(e) ··· 330 329 gap: 14, 331 330 }, 332 331 border: { 333 - borderTopWidth: hairlineWidth, 332 + borderTopWidth: StyleSheet.hairlineWidth, 334 333 }, 335 334 headerContainer: { 336 335 flexDirection: 'row',
+1 -2
src/view/com/lists/ListCard.tsx
··· 14 14 import {Link} from '../util/Link' 15 15 import {Text} from '../util/text/Text' 16 16 import {UserAvatar} from '../util/UserAvatar' 17 - import hairlineWidth = StyleSheet.hairlineWidth 18 17 19 18 export const ListCard = ({ 20 19 testID, ··· 134 133 135 134 const styles = StyleSheet.create({ 136 135 outer: { 137 - borderTopWidth: hairlineWidth, 136 + borderTopWidth: StyleSheet.hairlineWidth, 138 137 paddingHorizontal: 6, 139 138 }, 140 139 outerNoBorder: {
+3 -4
src/view/com/modals/UserAddRemoveLists.tsx
··· 29 29 import {Text} from '../util/text/Text' 30 30 import * as Toast from '../util/Toast' 31 31 import {UserAvatar} from '../util/UserAvatar' 32 - import hairlineWidth = StyleSheet.hairlineWidth 33 32 34 33 export const snapPoints = ['fullscreen'] 35 34 ··· 63 62 return [pal.border, {height: screenHeight / 1.5}] 64 63 } 65 64 66 - return [pal.border, {flex: 1, borderTopWidth: hairlineWidth}] 65 + return [pal.border, {flex: 1, borderTopWidth: StyleSheet.hairlineWidth}] 67 66 }, [pal.border, screenHeight]) 68 67 69 68 return ( ··· 188 187 style={[ 189 188 styles.listItem, 190 189 pal.border, 191 - index !== 0 && {borderTopWidth: hairlineWidth}, 190 + index !== 0 && {borderTopWidth: StyleSheet.hairlineWidth}, 192 191 ]}> 193 192 <View style={styles.listItemAvi}> 194 193 <UserAvatar size={40} avatar={list.avatar} type="list" /> ··· 248 247 gap: 10, 249 248 paddingTop: 10, 250 249 paddingBottom: isAndroid ? 10 : 0, 251 - borderTopWidth: hairlineWidth, 250 + borderTopWidth: StyleSheet.hairlineWidth, 252 251 }, 253 252 footerBtn: { 254 253 paddingHorizontal: 24,
+1 -2
src/view/com/notifications/Feed.tsx
··· 24 24 import {LoadMoreRetryBtn} from '#/view/com/util/LoadMoreRetryBtn' 25 25 import {CenteredView} from '#/view/com/util/Views' 26 26 import {FeedItem} from './FeedItem' 27 - import hairlineWidth = StyleSheet.hairlineWidth 28 27 29 28 const EMPTY_FEED_ITEM = {_reactKey: '__empty__'} 30 29 const LOAD_MORE_ERROR_ITEM = {_reactKey: '__load_more_error__'} ··· 137 136 <View 138 137 style={[ 139 138 pal.border, 140 - !isTabletOrMobile && {borderTopWidth: hairlineWidth}, 139 + !isTabletOrMobile && {borderTopWidth: StyleSheet.hairlineWidth}, 141 140 ]}> 142 141 <NotificationFeedLoadingPlaceholder /> 143 142 </View>
+11 -14
src/view/com/notifications/FeedItem.tsx
··· 20 20 import {AtUri} from '@atproto/api' 21 21 import {msg, plural, Trans} from '@lingui/macro' 22 22 import {useLingui} from '@lingui/react' 23 + import {useNavigation} from '@react-navigation/native' 23 24 import {useQueryClient} from '@tanstack/react-query' 24 25 25 26 import {useGate} from '#/lib/statsig/statsig' 27 + import {parseTenorGif} from '#/lib/strings/embed-player' 28 + import {logger} from '#/logger' 26 29 import {FeedNotification} from '#/state/queries/notifications/feed' 27 30 import {useAnimatedValue} from 'lib/hooks/useAnimatedValue' 28 31 import {usePalette} from 'lib/hooks/usePalette' 29 32 import {makeProfileLink} from 'lib/routes/links' 33 + import {NavigationProp} from 'lib/routes/types' 34 + import {forceLTR} from 'lib/strings/bidi' 30 35 import {sanitizeDisplayName} from 'lib/strings/display-names' 31 36 import {sanitizeHandle} from 'lib/strings/handles' 32 37 import {niceDate} from 'lib/strings/time' 33 38 import {colors, s} from 'lib/styles' 34 39 import {isWeb} from 'platform/detection' 40 + import {DM_SERVICE_HEADERS} from 'state/queries/messages/const' 35 41 import {precacheProfile} from 'state/queries/profile' 42 + import {useAgent} from 'state/session' 36 43 import {atoms as a, useTheme} from '#/alf' 44 + import {Button, ButtonText} from '#/components/Button' 37 45 import { 38 46 ChevronBottom_Stroke2_Corner0_Rounded as ChevronDownIcon, 39 47 ChevronTop_Stroke2_Corner0_Rounded as ChevronUpIcon, ··· 41 49 import {Heart2_Filled_Stroke2_Corner0_Rounded as HeartIconFilled} from '#/components/icons/Heart2' 42 50 import {PersonPlus_Filled_Stroke2_Corner0_Rounded as PersonPlusIcon} from '#/components/icons/Person' 43 51 import {Repost_Stroke2_Corner2_Rounded as RepostIcon} from '#/components/icons/Repost' 52 + import {StarterPack} from '#/components/icons/StarterPack' 44 53 import {Link as NewLink} from '#/components/Link' 45 54 import {ProfileHoverCard} from '#/components/ProfileHoverCard' 55 + import {Notification as StarterPackCard} from '#/components/StarterPack/StarterPackCard' 46 56 import {FeedSourceCard} from '../feeds/FeedSourceCard' 47 57 import {Post} from '../post/Post' 48 58 import {ImageHorzList} from '../util/images/ImageHorzList' ··· 51 61 import {Text} from '../util/text/Text' 52 62 import {TimeElapsed} from '../util/TimeElapsed' 53 63 import {PreviewableUserAvatar, UserAvatar} from '../util/UserAvatar' 54 - 55 - import hairlineWidth = StyleSheet.hairlineWidth 56 - import {useNavigation} from '@react-navigation/native' 57 - 58 - import {parseTenorGif} from '#/lib/strings/embed-player' 59 - import {logger} from '#/logger' 60 - import {NavigationProp} from 'lib/routes/types' 61 - import {forceLTR} from 'lib/strings/bidi' 62 - import {DM_SERVICE_HEADERS} from 'state/queries/messages/const' 63 - import {useAgent} from 'state/session' 64 - import {Button, ButtonText} from '#/components/Button' 65 - import {StarterPack} from '#/components/icons/StarterPack' 66 - import {Notification as StarterPackCard} from '#/components/StarterPack/StarterPackCard' 67 64 68 65 const MAX_AUTHORS = 5 69 66 ··· 222 219 backgroundColor: pal.colors.unreadNotifBg, 223 220 borderColor: pal.colors.unreadNotifBorder, 224 221 }, 225 - {borderTopWidth: hideTopBorder ? 0 : hairlineWidth}, 222 + {borderTopWidth: hideTopBorder ? 0 : StyleSheet.hairlineWidth}, 226 223 ]} 227 224 href={itemHref} 228 225 noFeedback
+1 -2
src/view/com/pager/TabBar.tsx
··· 7 7 import {PressableWithHover} from '../util/PressableWithHover' 8 8 import {Text} from '../util/text/Text' 9 9 import {DraggableScrollView} from './DraggableScrollView' 10 - import hairlineWidth = StyleSheet.hairlineWidth 11 10 12 11 export interface TabBarProps { 13 12 testID?: string ··· 208 207 left: 0, 209 208 right: 0, 210 209 top: '100%', 211 - borderBottomWidth: hairlineWidth, 210 + borderBottomWidth: StyleSheet.hairlineWidth, 212 211 }, 213 212 })
+5 -6
src/view/com/post-thread/PostThreadItem.tsx
··· 44 44 import {PostMeta} from '../util/PostMeta' 45 45 import {Text} from '../util/text/Text' 46 46 import {PreviewableUserAvatar} from '../util/UserAvatar' 47 - import hairlineWidth = StyleSheet.hairlineWidth 48 47 49 48 export function PostThreadItem({ 50 49 post, ··· 604 603 { 605 604 flexDirection: 'row', 606 605 paddingHorizontal: isMobile ? 10 : 6, 607 - borderTopWidth: depth === 1 ? hairlineWidth : 0, 606 + borderTopWidth: depth === 1 ? StyleSheet.hairlineWidth : 0, 608 607 }, 609 608 ]}> 610 609 {Array.from(Array(depth - 1)).map((_, n: number) => ( ··· 699 698 700 699 const styles = StyleSheet.create({ 701 700 outer: { 702 - borderTopWidth: hairlineWidth, 701 + borderTopWidth: StyleSheet.hairlineWidth, 703 702 paddingLeft: 8, 704 703 }, 705 704 outerHighlighted: { ··· 709 708 paddingRight: 8, 710 709 }, 711 710 outerHighlightedRoot: { 712 - borderTopWidth: hairlineWidth, 711 + borderTopWidth: StyleSheet.hairlineWidth, 713 712 paddingTop: 16, 714 713 }, 715 714 noTopBorder: { ··· 761 760 expandedInfo: { 762 761 flexDirection: 'row', 763 762 padding: 10, 764 - borderTopWidth: hairlineWidth, 765 - borderBottomWidth: hairlineWidth, 763 + borderTopWidth: StyleSheet.hairlineWidth, 764 + borderBottomWidth: StyleSheet.hairlineWidth, 766 765 marginTop: 5, 767 766 marginBottom: 10, 768 767 },
+1 -2
src/view/com/post/Post.tsx
··· 37 37 import {Text} from '../util/text/Text' 38 38 import {PreviewableUserAvatar} from '../util/UserAvatar' 39 39 import {UserInfoText} from '../util/UserInfoText' 40 - import hairlineWidth = StyleSheet.hairlineWidth 41 40 42 41 export function Post({ 43 42 post, ··· 155 154 style={[ 156 155 styles.outer, 157 156 pal.border, 158 - !hideTopBorder && {borderTopWidth: hairlineWidth}, 157 + !hideTopBorder && {borderTopWidth: StyleSheet.hairlineWidth}, 159 158 style, 160 159 ]} 161 160 onBeforePress={onBeforePress}>
+2 -2
src/view/com/posts/FeedItem.tsx
··· 46 46 import {Text} from '../util/text/Text' 47 47 import {PreviewableUserAvatar} from '../util/UserAvatar' 48 48 import {AviFollowButton} from './AviFollowButton' 49 - import hairlineWidth = StyleSheet.hairlineWidth 50 49 51 50 interface FeedItemProps { 52 51 record: AppBskyFeedPost.Record ··· 205 204 isThreadLastChild || (!isThreadChild && !isThreadParent) 206 205 ? 8 207 206 : undefined, 208 - borderTopWidth: hideTopBorder || isThreadChild ? 0 : hairlineWidth, 207 + borderTopWidth: 208 + hideTopBorder || isThreadChild ? 0 : StyleSheet.hairlineWidth, 209 209 }, 210 210 ] 211 211
+2 -3
src/view/com/profile/ProfileCard.tsx
··· 23 23 KnownFollowers, 24 24 shouldShowKnownFollowers, 25 25 } from '#/components/KnownFollowers' 26 + import * as Pills from '#/components/Pills' 26 27 import {Link} from '../util/Link' 27 28 import {Text} from '../util/text/Text' 28 29 import {PreviewableUserAvatar} from '../util/UserAvatar' 29 30 import {FollowButton} from './FollowButton' 30 - import hairlineWidth = StyleSheet.hairlineWidth 31 - import * as Pills from '#/components/Pills' 32 31 33 32 export function ProfileCard({ 34 33 testID, ··· 217 216 218 217 const styles = StyleSheet.create({ 219 218 outer: { 220 - borderTopWidth: hairlineWidth, 219 + borderTopWidth: StyleSheet.hairlineWidth, 221 220 paddingHorizontal: 6, 222 221 paddingVertical: 4, 223 222 },
+3 -5
src/view/com/profile/ProfileSubpageHeader.tsx
··· 15 15 import {NavigationProp} from 'lib/routes/types' 16 16 import {sanitizeHandle} from 'lib/strings/handles' 17 17 import {isNative} from 'platform/detection' 18 + import {Menu_Stroke2_Corner0_Rounded as Menu} from '#/components/icons/Menu' 19 + import {StarterPack} from '#/components/icons/StarterPack' 18 20 import {TextLink} from '../util/Link' 19 21 import {LoadingPlaceholder} from '../util/LoadingPlaceholder' 20 22 import {Text} from '../util/text/Text' 21 23 import {UserAvatar, UserAvatarType} from '../util/UserAvatar' 22 24 import {CenteredView} from '../util/Views' 23 - import hairlineWidth = StyleSheet.hairlineWidth 24 - 25 - import {Menu_Stroke2_Corner0_Rounded as Menu} from '#/components/icons/Menu' 26 - import {StarterPack} from '#/components/icons/StarterPack' 27 25 28 26 export function ProfileSubpageHeader({ 29 27 isLoading, ··· 84 82 { 85 83 flexDirection: 'row', 86 84 alignItems: 'center', 87 - borderBottomWidth: hairlineWidth, 85 + borderBottomWidth: StyleSheet.hairlineWidth, 88 86 paddingTop: isNative ? 0 : 8, 89 87 paddingBottom: 8, 90 88 paddingHorizontal: isMobile ? 12 : 14,
+1 -2
src/view/com/util/LoadingPlaceholder.tsx
··· 17 17 Heart2_Stroke2_Corner0_Rounded as HeartIconOutline, 18 18 } from '#/components/icons/Heart2' 19 19 import {Repost_Stroke2_Corner2_Rounded as Repost} from '#/components/icons/Repost' 20 - import hairlineWidth = StyleSheet.hairlineWidth 21 20 22 21 export function LoadingPlaceholder({ 23 22 width, ··· 236 235 { 237 236 paddingHorizontal: 12, 238 237 paddingVertical: 18, 239 - borderTopWidth: showTopBorder ? hairlineWidth : 0, 238 + borderTopWidth: showTopBorder ? StyleSheet.hairlineWidth : 0, 240 239 }, 241 240 pal.border, 242 241 style,
+3 -4
src/view/com/util/ViewHeader.tsx
··· 13 13 import {useWebMediaQueries} from 'lib/hooks/useWebMediaQueries' 14 14 import {NavigationProp} from 'lib/routes/types' 15 15 import {useTheme} from '#/alf' 16 + import {Menu_Stroke2_Corner0_Rounded as Menu} from '#/components/icons/Menu' 16 17 import {Text} from './text/Text' 17 18 import {CenteredView} from './Views' 18 - import hairlineWidth = StyleSheet.hairlineWidth 19 - import {Menu_Stroke2_Corner0_Rounded as Menu} from '#/components/icons/Menu' 20 19 21 20 const BACK_HITSLOP = {left: 20, top: 20, right: 50, bottom: 20} 22 21 ··· 154 153 styles.desktopHeader, 155 154 pal.border, 156 155 { 157 - borderBottomWidth: showBorder ? hairlineWidth : 0, 156 + borderBottomWidth: showBorder ? StyleSheet.hairlineWidth : 0, 158 157 }, 159 158 {display: 'flex', flexDirection: 'column'}, 160 159 ]}> ··· 243 242 marginRight: 'auto', 244 243 }, 245 244 border: { 246 - borderBottomWidth: hairlineWidth, 245 + borderBottomWidth: StyleSheet.hairlineWidth, 247 246 }, 248 247 titleContainer: { 249 248 marginLeft: 'auto',
+4 -5
src/view/com/util/Views.web.tsx
··· 26 26 import {usePalette} from 'lib/hooks/usePalette' 27 27 import {useWebMediaQueries} from 'lib/hooks/useWebMediaQueries' 28 28 import {addStyle} from 'lib/styles' 29 - import hairlineWidth = StyleSheet.hairlineWidth 30 29 31 30 interface AddedProps { 32 31 desktopFixedHeight?: boolean | number ··· 50 49 } 51 50 if (sideBorders) { 52 51 style = addStyle(style, { 53 - borderLeftWidth: hairlineWidth, 54 - borderRightWidth: hairlineWidth, 52 + borderLeftWidth: StyleSheet.hairlineWidth, 53 + borderRightWidth: StyleSheet.hairlineWidth, 55 54 }) 56 55 style = addStyle(style, pal.border) 57 56 } ··· 163 162 164 163 const styles = StyleSheet.create({ 165 164 contentContainer: { 166 - borderLeftWidth: hairlineWidth, 167 - borderRightWidth: hairlineWidth, 165 + borderLeftWidth: StyleSheet.hairlineWidth, 166 + borderRightWidth: StyleSheet.hairlineWidth, 168 167 // @ts-ignore web only 169 168 minHeight: '100vh', 170 169 },
+1 -2
src/view/com/util/load-latest/LoadLatestBtn.tsx
··· 13 13 import {colors} from '#/lib/styles' 14 14 import {isWeb} from '#/platform/detection' 15 15 import {useSession} from '#/state/session' 16 - import hairlineWidth = StyleSheet.hairlineWidth 17 16 18 17 const AnimatedTouchableOpacity = 19 18 Animated.createAnimatedComponent(TouchableOpacity) ··· 74 73 // @ts-ignore 'fixed' is web only -prf 75 74 position: isWeb ? 'fixed' : 'absolute', 76 75 left: 18, 77 - borderWidth: hairlineWidth, 76 + borderWidth: StyleSheet.hairlineWidth, 78 77 width: 52, 79 78 height: 52, 80 79 borderRadius: 26,
+2 -3
src/view/com/util/post-embeds/QuoteEmbed.tsx
··· 39 39 import {PostMeta} from '../PostMeta' 40 40 import {Text} from '../text/Text' 41 41 import {PostEmbeds} from '.' 42 - import hairlineWidth = StyleSheet.hairlineWidth 43 42 44 43 export function MaybeQuoteEmbed({ 45 44 embed, ··· 262 261 marginTop: 8, 263 262 paddingVertical: 12, 264 263 paddingHorizontal: 12, 265 - borderWidth: hairlineWidth, 264 + borderWidth: StyleSheet.hairlineWidth, 266 265 }, 267 266 errorContainer: { 268 267 flexDirection: 'row', ··· 272 271 marginTop: 8, 273 272 paddingVertical: 14, 274 273 paddingHorizontal: 14, 275 - borderWidth: hairlineWidth, 274 + borderWidth: StyleSheet.hairlineWidth, 276 275 }, 277 276 alert: { 278 277 marginBottom: 6,
+3 -4
src/view/com/util/post-embeds/index.tsx
··· 19 19 } from '@atproto/api' 20 20 21 21 import {ImagesLightbox, useLightboxControls} from '#/state/lightbox' 22 + import {useLargeAltBadgeEnabled} from '#/state/preferences/large-alt-badge' 22 23 import {usePalette} from 'lib/hooks/usePalette' 23 24 import {FeedSourceCard} from 'view/com/feeds/FeedSourceCard' 24 25 import {atoms as a} from '#/alf' 26 + import {Embed as StarterPackCard} from '#/components/StarterPack/StarterPackCard' 25 27 import {ContentHider} from '../../../../components/moderation/ContentHider' 26 28 import {AutoSizedImage} from '../images/AutoSizedImage' 27 29 import {ImageLayoutGrid} from '../images/ImageLayoutGrid' 28 30 import {ExternalLinkEmbed} from './ExternalLinkEmbed' 29 31 import {ListEmbed} from './ListEmbed' 30 32 import {MaybeQuoteEmbed} from './QuoteEmbed' 31 - import hairlineWidth = StyleSheet.hairlineWidth 32 - import {useLargeAltBadgeEnabled} from '#/state/preferences/large-alt-badge' 33 - import {Embed as StarterPackCard} from '#/components/StarterPack/StarterPackCard' 34 33 35 34 type Embed = 36 35 | AppBskyEmbedRecord.View ··· 205 204 fontWeight: 'bold', 206 205 }, 207 206 customFeedOuter: { 208 - borderWidth: hairlineWidth, 207 + borderWidth: StyleSheet.hairlineWidth, 209 208 borderRadius: 8, 210 209 marginTop: 4, 211 210 paddingHorizontal: 12,
+5 -6
src/view/screens/Feeds.tsx
··· 33 33 import {NoFollowingFeed} from '#/screens/Feeds/NoFollowingFeed' 34 34 import {NoSavedFeedsOfAnyType} from '#/screens/Feeds/NoSavedFeedsOfAnyType' 35 35 import {atoms as a, useTheme} from '#/alf' 36 + import {Divider} from '#/components/Divider' 37 + import * as FeedCard from '#/components/FeedCard' 36 38 import {IconCircle} from '#/components/IconCircle' 39 + import {ChevronRight_Stroke2_Corner0_Rounded as ChevronRight} from '#/components/icons/Chevron' 37 40 import {FilterTimeline_Stroke2_Corner0_Rounded as FilterTimeline} from '#/components/icons/FilterTimeline' 38 41 import {ListMagnifyingGlass_Stroke2_Corner0_Rounded} from '#/components/icons/ListMagnifyingGlass' 39 42 import {ListSparkle_Stroke2_Corner0_Rounded} from '#/components/icons/ListSparkle' 40 - import hairlineWidth = StyleSheet.hairlineWidth 41 - import {Divider} from '#/components/Divider' 42 - import * as FeedCard from '#/components/FeedCard' 43 - import {ChevronRight_Stroke2_Corner0_Rounded as ChevronRight} from '#/components/icons/Chevron' 44 43 import * as ListCard from '#/components/ListCard' 45 44 46 45 type Props = NativeStackScreenProps<CommonNavigatorParams, 'Feeds'> ··· 793 792 paddingHorizontal: 16, 794 793 paddingVertical: 14, 795 794 gap: 12, 796 - borderBottomWidth: hairlineWidth, 795 + borderBottomWidth: StyleSheet.hairlineWidth, 797 796 }, 798 797 savedFeedMobile: { 799 798 paddingVertical: 10, 800 799 }, 801 800 offlineSlug: { 802 - borderWidth: hairlineWidth, 801 + borderWidth: StyleSheet.hairlineWidth, 803 802 borderRadius: 4, 804 803 paddingHorizontal: 4, 805 804 paddingVertical: 2,
+5 -3
src/view/screens/Lists.tsx
··· 16 16 import {Button} from 'view/com/util/forms/Button' 17 17 import {SimpleViewHeader} from 'view/com/util/SimpleViewHeader' 18 18 import {Text} from 'view/com/util/text/Text' 19 - import hairlineWidth = StyleSheet.hairlineWidth 20 19 21 20 type Props = NativeStackScreenProps<CommonNavigatorParams, 'Lists'> 22 21 export function ListsScreen({}: Props) { ··· 55 54 style={[ 56 55 pal.border, 57 56 isMobile 58 - ? {borderBottomWidth: hairlineWidth} 59 - : {borderLeftWidth: hairlineWidth, borderRightWidth: hairlineWidth}, 57 + ? {borderBottomWidth: StyleSheet.hairlineWidth} 58 + : { 59 + borderLeftWidth: StyleSheet.hairlineWidth, 60 + borderRightWidth: StyleSheet.hairlineWidth, 61 + }, 60 62 ]}> 61 63 <View style={{flex: 1}}> 62 64 <Text type="title-lg" style={[pal.text, {fontWeight: 'bold'}]}>
+2 -3
src/view/screens/ProfileList.tsx
··· 65 65 import * as Prompt from '#/components/Prompt' 66 66 import {ReportDialog, useReportDialogControl} from '#/components/ReportDialog' 67 67 import {RichText} from '#/components/RichText' 68 - import hairlineWidth = StyleSheet.hairlineWidth 69 68 70 69 const SECTION_TITLES_CURATE = ['Posts', 'About'] 71 70 const SECTION_TITLES_MOD = ['About'] ··· 803 802 <View 804 803 style={[ 805 804 { 806 - borderTopWidth: hairlineWidth, 805 + borderTopWidth: StyleSheet.hairlineWidth, 807 806 padding: isMobile ? 14 : 20, 808 807 gap: 12, 809 808 }, ··· 954 953 marginTop: 10, 955 954 paddingHorizontal: 18, 956 955 paddingVertical: 14, 957 - borderTopWidth: hairlineWidth, 956 + borderTopWidth: StyleSheet.hairlineWidth, 958 957 }, 959 958 ]}> 960 959 <Text type="title-lg" style={[pal.text, s.mb10]}>
+6 -5
src/view/screens/SavedFeeds.tsx
··· 32 32 import {NoSavedFeedsOfAnyType} from '#/screens/Feeds/NoSavedFeedsOfAnyType' 33 33 import {atoms as a, useTheme} from '#/alf' 34 34 import {FilterTimeline_Stroke2_Corner0_Rounded as FilterTimeline} from '#/components/icons/FilterTimeline' 35 - import hairlineWidth = StyleSheet.hairlineWidth 36 35 37 36 const HITSLOP_TOP = { 38 37 top: 20, ··· 93 92 <ViewHeader title={_(msg`Edit My Feeds`)} showOnDesktop showBorder /> 94 93 <ScrollView style={s.flex1} contentContainerStyle={[styles.noBorder]}> 95 94 {noSavedFeedsOfAnyType && ( 96 - <View style={[pal.border, {borderBottomWidth: hairlineWidth}]}> 95 + <View 96 + style={[pal.border, {borderBottomWidth: StyleSheet.hairlineWidth}]}> 97 97 <NoSavedFeedsOfAnyType /> 98 98 </View> 99 99 )} ··· 135 135 )} 136 136 137 137 {noFollowingFeed && ( 138 - <View style={[pal.border, {borderBottomWidth: hairlineWidth}]}> 138 + <View 139 + style={[pal.border, {borderBottomWidth: StyleSheet.hairlineWidth}]}> 139 140 <NoFollowingFeed /> 140 141 </View> 141 142 )} ··· 437 438 paddingHorizontal: 14, 438 439 paddingTop: 20, 439 440 paddingBottom: 10, 440 - borderBottomWidth: hairlineWidth, 441 + borderBottomWidth: StyleSheet.hairlineWidth, 441 442 }, 442 443 itemContainer: { 443 444 flexDirection: 'row', 444 445 alignItems: 'center', 445 - borderBottomWidth: hairlineWidth, 446 + borderBottomWidth: StyleSheet.hairlineWidth, 446 447 }, 447 448 footerText: { 448 449 paddingHorizontal: 26,
+2 -3
src/view/screens/Settings/index.tsx
··· 62 62 import {ScrollView} from 'view/com/util/Views' 63 63 import {DeactivateAccountDialog} from '#/screens/Settings/components/DeactivateAccountDialog' 64 64 import {useTheme} from '#/alf' 65 + import {atoms as a} from '#/alf' 65 66 import {useDialogControl} from '#/components/Dialog' 66 67 import {BirthDateSettingsDialog} from '#/components/dialogs/BirthDateSettings' 67 68 import {navigate, resetToTab} from '#/Navigation' 68 69 import {Email2FAToggle} from './Email2FAToggle' 69 70 import {ExportCarDialog} from './ExportCarDialog' 70 - import hairlineWidth = StyleSheet.hairlineWidth 71 - import {atoms as a} from '#/alf' 72 71 73 72 function SettingsAccountCard({ 74 73 account, ··· 326 325 showBackButton={isMobile} 327 326 style={[ 328 327 pal.border, 329 - {borderBottomWidth: hairlineWidth}, 328 + {borderBottomWidth: StyleSheet.hairlineWidth}, 330 329 !isMobile && {borderLeftWidth: 1, borderRightWidth: 1}, 331 330 ]}> 332 331 <View style={{flex: 1}}>
+1 -2
src/view/shell/bottom-bar/BottomBarStyles.tsx
··· 1 1 import {StyleSheet} from 'react-native' 2 2 3 3 import {colors} from 'lib/styles' 4 - import hairlineWidth = StyleSheet.hairlineWidth 5 4 6 5 export const styles = StyleSheet.create({ 7 6 bottomBar: { ··· 10 9 left: 0, 11 10 right: 0, 12 11 flexDirection: 'row', 13 - borderTopWidth: hairlineWidth, 12 + borderTopWidth: StyleSheet.hairlineWidth, 14 13 paddingLeft: 5, 15 14 paddingRight: 10, 16 15 },
+3 -4
src/view/shell/desktop/RightNav.tsx
··· 11 11 import {s} from 'lib/styles' 12 12 import {TextLink} from 'view/com/util/Link' 13 13 import {Text} from 'view/com/util/text/Text' 14 + import {ProgressGuideList} from '#/components/ProgressGuide/List' 14 15 import {DesktopFeeds} from './Feeds' 15 16 import {DesktopSearch} from './Search' 16 - import hairlineWidth = StyleSheet.hairlineWidth 17 - import {ProgressGuideList} from '#/components/ProgressGuide/List' 18 17 19 18 export function DesktopRightNav({routeName}: {routeName: string}) { 20 19 const pal = usePalette('default') ··· 135 134 marginBottom: 10, 136 135 }, 137 136 desktopFeedsContainer: { 138 - borderTopWidth: hairlineWidth, 139 - borderBottomWidth: hairlineWidth, 137 + borderTopWidth: StyleSheet.hairlineWidth, 138 + borderBottomWidth: StyleSheet.hairlineWidth, 140 139 marginTop: 18, 141 140 marginBottom: 18, 142 141 },