File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ import VerificationCheck from '../VerificationCheck/VerificationCheck';
1010import styles from './Avatar.module.scss' ;
1111import { useAppContext } from '../../contexts/AppContext' ;
1212import { LegendCustomizationConfig } from '../../lib/premium' ;
13+ import { useSearchParams } from '@solidjs/router' ;
1314
1415const Avatar : Component < {
1516 src ?: string | undefined ,
@@ -25,6 +26,7 @@ const Avatar: Component<{
2526
2627 const media = useMediaContext ( ) ;
2728 const app = useAppContext ( ) ;
29+ const [ searchParams , setSearchParams ] = useSearchParams ( ) ;
2830
2931 const [ isCached , setIsCached ] = createSignal ( false ) ;
3032
@@ -243,7 +245,7 @@ const Avatar: Component<{
243245 </ div >
244246 </ Show >
245247
246- < Show when = { media ?. actions . isStreaming ( props . user ?. pubkey || 'n/a' ) } >
248+ < Show when = { searchParams . live === '1' && media ?. actions . isStreaming ( props . user ?. pubkey || 'n/a' ) } >
247249 < div class = { styles . centerBottom } >
248250 < a
249251 id = { props . id }
Original file line number Diff line number Diff line change @@ -27,6 +27,7 @@ import { userName } from '../../stores/profile';
2727import { date } from '../../lib/dates' ;
2828import { useAppContext } from '../../contexts/AppContext' ;
2929import LiveEventSidebarSkeleton from '../Skeleton/LiveEventSidebarSkeleton' ;
30+ import { useSearchParams } from '@solidjs/router' ;
3031
3132const sidebarOptions = [
3233 {
@@ -140,6 +141,7 @@ const HomeSidebar: Component< { id?: string } > = (props) => {
140141 const account = useAccountContext ( ) ;
141142 const home = useHomeContext ( ) ;
142143 const app = useAppContext ( ) ;
144+ const [ searchParams , setSearchParams ] = useSearchParams ( ) ;
143145
144146 const subId = `live_events_sidebar_${ APP_ID } ` ;
145147
@@ -243,7 +245,7 @@ const HomeSidebar: Component< { id?: string } > = (props) => {
243245
244246 return (
245247 < div id = { props . id } >
246- < Show when = { liveEvents . length > 0 } >
248+ < Show when = { searchParams . live === '1' && liveEvents . length > 0 } >
247249 < div class = { styles . headingLive } >
248250 < div >
249251 Live on Nostr
You can’t perform that action at this time.
0 commit comments