Swap RichText
(#2934)
* Switch to new RT * Allow early exit from links * Build in tracking to text atoms * Clean up FeedSourceCard * Clean up leading after new default * Add deprecated notice
This commit is contained in:
parent
8a169dc6a1
commit
df5a8f1542
12 changed files with 65 additions and 43 deletions
|
@ -20,7 +20,8 @@ import {PostAlerts} from '../moderation/PostAlerts'
|
|||
import {makeProfileLink} from 'lib/routes/links'
|
||||
import {InfoCircleIcon} from 'lib/icons'
|
||||
import {Trans} from '@lingui/macro'
|
||||
import {RichText} from 'view/com/util/text/RichText'
|
||||
import {RichText} from '#/components/RichText'
|
||||
import {atoms as a} from '#/alf'
|
||||
|
||||
export function MaybeQuoteEmbed({
|
||||
embed,
|
||||
|
@ -127,11 +128,10 @@ export function QuoteEmbed({
|
|||
) : null}
|
||||
{richText ? (
|
||||
<RichText
|
||||
richText={richText}
|
||||
type="post-text"
|
||||
style={pal.text}
|
||||
value={richText}
|
||||
style={[a.text_md]}
|
||||
numberOfLines={20}
|
||||
noLinks
|
||||
disableLinks
|
||||
/>
|
||||
) : null}
|
||||
{embed && <PostEmbeds embed={embed} moderation={{}} />}
|
||||
|
|
|
@ -10,6 +10,9 @@ import {usePalette} from 'lib/hooks/usePalette'
|
|||
|
||||
const WORD_WRAP = {wordWrap: 1}
|
||||
|
||||
/**
|
||||
* @deprecated use `#/components/RichText`
|
||||
*/
|
||||
export function RichText({
|
||||
testID,
|
||||
type = 'md',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue