Bluesky app fork with some witchin' additions 💫

Remove record-with-media side-by-side layout (#5182)

authored by

Eric Bailey and committed by
GitHub
b90cd683 55468595

+11 -42
+11 -42
src/view/com/util/post-embeds/QuoteEmbed.tsx
··· 33 33 import {makeProfileLink} from 'lib/routes/links' 34 34 import {precacheProfile} from 'state/queries/profile' 35 35 import {ComposerOptsQuote} from 'state/shell/composer' 36 - import {atoms as a, useBreakpoints} from '#/alf' 36 + import {atoms as a} from '#/alf' 37 37 import {RichText} from '#/components/RichText' 38 38 import {ContentHider} from '../../../../components/moderation/ContentHider' 39 39 import {PostAlerts} from '../../../../components/moderation/PostAlerts' ··· 41 41 import {PostMeta} from '../PostMeta' 42 42 import {Text} from '../text/Text' 43 43 import {PostEmbeds} from '.' 44 - import {PostEmbedViewContext, QuoteEmbedViewContext} from './types' 44 + import {QuoteEmbedViewContext} from './types' 45 45 46 46 export function MaybeQuoteEmbed({ 47 47 embed, ··· 161 161 onOpen, 162 162 style, 163 163 allowNestedQuotes, 164 - viewContext, 165 164 }: { 166 165 quote: ComposerOptsQuote 167 166 moderation?: ModerationDecision ··· 175 174 const itemUrip = new AtUri(quote.uri) 176 175 const itemHref = makeProfileLink(quote.author, 'post', itemUrip.rkey) 177 176 const itemTitle = `Post by ${quote.author.handle}` 178 - const {gtMobile} = useBreakpoints() 179 177 180 178 const richText = React.useMemo( 181 179 () => ··· 207 205 } 208 206 } 209 207 }, [quote.embeds, allowNestedQuotes]) 210 - const isImagesEmbed = AppBskyEmbedImages.isView(embed) 211 208 212 209 const onBeforePress = React.useCallback(() => { 213 210 precacheProfile(queryClient, quote.author) ··· 237 234 {moderation ? ( 238 235 <PostAlerts modui={moderation.ui('contentView')} style={[a.py_xs]} /> 239 236 ) : null} 240 - 241 - {viewContext === QuoteEmbedViewContext.FeedEmbedRecordWithMedia && 242 - isImagesEmbed ? ( 243 - <View style={[a.flex_row, a.gap_md]}> 244 - {embed && ( 245 - <View style={[{width: gtMobile ? 100 : 80}]}> 246 - <PostEmbeds 247 - embed={embed} 248 - moderation={moderation} 249 - viewContext={PostEmbedViewContext.FeedEmbedRecordWithMedia} 250 - /> 251 - </View> 252 - )} 253 - {richText ? ( 254 - <View style={[a.flex_1, a.pt_xs]}> 255 - <RichText 256 - value={richText} 257 - style={a.text_md} 258 - numberOfLines={20} 259 - disableLinks 260 - /> 261 - </View> 262 - ) : null} 263 - </View> 264 - ) : ( 265 - <> 266 - {richText ? ( 267 - <RichText 268 - value={richText} 269 - style={a.text_md} 270 - numberOfLines={20} 271 - disableLinks 272 - /> 273 - ) : null} 274 - {embed && <PostEmbeds embed={embed} moderation={moderation} />} 275 - </> 276 - )} 237 + {richText ? ( 238 + <RichText 239 + value={richText} 240 + style={a.text_md} 241 + numberOfLines={20} 242 + disableLinks 243 + /> 244 + ) : null} 245 + {embed && <PostEmbeds embed={embed} moderation={moderation} />} 277 246 </Link> 278 247 </ContentHider> 279 248 )