Switch back border ordering
(cherry picked from commit 34e3789f8b410132c1390df3c2bb8257630ebdd9)
This commit is contained in:
@@ -260,6 +260,10 @@ export function Explore({
|
|||||||
const items = useMemo<ExploreScreenItems[]>(() => {
|
const items = useMemo<ExploreScreenItems[]>(() => {
|
||||||
const i: ExploreScreenItems[] = []
|
const i: ExploreScreenItems[] = []
|
||||||
|
|
||||||
|
const addTopBorder = () => {
|
||||||
|
i.push({type: 'topBorder', key: 'top-border'})
|
||||||
|
}
|
||||||
|
|
||||||
const addTrendingTopicsModule = () => {
|
const addTrendingTopicsModule = () => {
|
||||||
i.push({
|
i.push({
|
||||||
type: 'trendingTopics',
|
type: 'trendingTopics',
|
||||||
@@ -431,6 +435,8 @@ export function Explore({
|
|||||||
|
|
||||||
// Dynamic module ordering
|
// Dynamic module ordering
|
||||||
|
|
||||||
|
addTopBorder()
|
||||||
|
|
||||||
if (guide?.guide === 'follow-10' && !guide.isComplete) {
|
if (guide?.guide === 'follow-10' && !guide.isComplete) {
|
||||||
addSuggestedFollowsModule()
|
addSuggestedFollowsModule()
|
||||||
addTrendingTopicsModule()
|
addTrendingTopicsModule()
|
||||||
@@ -543,7 +549,7 @@ export function Explore({
|
|||||||
}
|
}
|
||||||
case 'loadMore': {
|
case 'loadMore': {
|
||||||
return (
|
return (
|
||||||
<View style={[a.border_t, t.atoms.border_contrast_low, a.pb_2xl]}>
|
<View style={[a.border_t, t.atoms.border_contrast_low]}>
|
||||||
<LoadMore item={item} />
|
<LoadMore item={item} />
|
||||||
</View>
|
</View>
|
||||||
)
|
)
|
||||||
@@ -598,7 +604,9 @@ export function Explore({
|
|||||||
() =>
|
() =>
|
||||||
items.reduce(
|
items.reduce(
|
||||||
(acc, curr) =>
|
(acc, curr) =>
|
||||||
[''].includes(curr.type) ? acc.concat(items.indexOf(curr)) : acc,
|
['topBorder'].includes(curr.type)
|
||||||
|
? acc.concat(items.indexOf(curr))
|
||||||
|
: acc,
|
||||||
[] as number[],
|
[] as number[],
|
||||||
),
|
),
|
||||||
[items],
|
[items],
|
||||||
|
|||||||
@@ -80,7 +80,7 @@ export function TrendRow({
|
|||||||
label={_(msg`Browse topic ${trend.displayName}`)}
|
label={_(msg`Browse topic ${trend.displayName}`)}
|
||||||
to={trend.link}
|
to={trend.link}
|
||||||
onPress={onPress}
|
onPress={onPress}
|
||||||
style={[a.border_t, t.atoms.border_contrast_low]}
|
style={[a.border_b, t.atoms.border_contrast_low]}
|
||||||
PressableComponent={Pressable}>
|
PressableComponent={Pressable}>
|
||||||
{({hovered, pressed}) => (
|
{({hovered, pressed}) => (
|
||||||
<>
|
<>
|
||||||
@@ -244,7 +244,7 @@ export function TrendingTopicRowSkeleton({}: {withPosts: boolean}) {
|
|||||||
a.py_lg,
|
a.py_lg,
|
||||||
a.flex_row,
|
a.flex_row,
|
||||||
a.gap_2xs,
|
a.gap_2xs,
|
||||||
a.border_t,
|
a.border_b,
|
||||||
t.atoms.border_contrast_low,
|
t.atoms.border_contrast_low,
|
||||||
]}>
|
]}>
|
||||||
<View style={[a.flex_1, a.gap_sm]}>
|
<View style={[a.flex_1, a.gap_sm]}>
|
||||||
|
|||||||
Reference in New Issue
Block a user