Skip to content

Commit

Permalink
put back default start feed
Browse files Browse the repository at this point in the history
  • Loading branch information
Zir0h committed Feb 5, 2025
1 parent 00d5149 commit a485e9d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/components/header/feed_toolbar/FeedToolbar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@ import { SingleViewIcon, MasonryIcon, ChevronIcon } from '@icons'
import { Button } from '@atoms/button'

import { useLocalSettings } from '@context/localSettingsStore'
import { useLocation, useNavigate, useParams } from 'react-router'
import { useLocation, useNavigate } from 'react-router'
import { Line } from '@atoms/line'
import { shallow } from 'zustand/shallow'
import { useUserStore } from '@context/userStore'
import { DEFAULT_START_FEED } from '@constants'

// const MediaFilter = ({ label, tagline }) => {
// return (
Expand All @@ -23,6 +24,7 @@ import { useUserStore } from '@context/userStore'
// }

const locationMap = new Map([
['---sort_feeds', 'Sort Feeds'],
['/feed/sales', 'Recent Sales'],
['/feed/random', 'Random'],
['/feed/newobjkts', 'New OBJKTs'],
Expand Down Expand Up @@ -62,9 +64,7 @@ export const FeedToolbar = ({ feeds_menu = false }) => {
)
const location = useLocation()
const feedLabel =
[...locationMap.entries()].find(([key]) =>
location.pathname.startsWith(key.replace('*', ''))
)?.[1] || 'Sort Feed' // Default to "Sort" if no match is found
locationMap.get(location.pathname) || startFeed || DEFAULT_START_FEED

const navigate = useNavigate()
const walletAddress = useUserStore((st) => [st.address], shallow)
Expand Down

0 comments on commit a485e9d

Please sign in to comment.