@@ -14,18 +14,27 @@ import ClipBanner from './clip_banner.jsx';
1414export type SessionHeadProps = {
1515 className ?: string ;
1616 head : t . SessionHead ;
17- withAuthor ?: boolean ;
1817} ;
1918
20- export function SessionHead ( { className, withAuthor, head } : SessionHeadProps ) {
19+ export function SessionHead ( { className, head } : SessionHeadProps ) {
20+ // const tags = lib.getHashTags(head);
21+ // const tagsStr = _.truncate(_.take(tags, 6).join(' '), { length: 60 });
22+
2123 return (
2224 < WithAvatar className = { cn ( 'session-head' , className ) } username = { head . author } >
23- < div className = "title" > { head . title || 'Untitled' } </ div >
24- { withAuthor && (
25- < div className = "footer" >
26- < span className = "footer-item author" > { head . author || 'anonymous' } </ span >
27- </ div >
28- ) }
25+ < div className = "title" >
26+ { head . title || 'Untitled' }
27+ { /* <span className="tags">{tagsStr}</span>*/ }
28+ </ div >
29+ < div className = "footer" >
30+ < span className = "footer-item author" title = { `@${ head . author || 'anonymous' } /${ head . handle } ` } >
31+ { head . author || 'anonymous' }
32+ < span className = "handle" >
33+ < span className = "no-select" > </ span > /< span className = "no-select" > </ span >
34+ { head . handle }
35+ </ span >
36+ </ span >
37+ </ div >
2938 </ WithAvatar >
3039 ) ;
3140}
@@ -82,6 +91,9 @@ export function SessionListing(props: SessionListingProps) {
8291 } ,
8392 ] ) ;
8493
94+ const tags = lib . getHashTags ( head ) ;
95+ const tagsStr = _ . truncate ( _ . take ( tags , 3 ) . join ( ' ' ) , { length : 30 } ) ;
96+
8597 return (
8698 < div className = { cn ( 'session-listing' , props . className ) } onClick = { ( ) => props . onClick ( head . id ) } tabIndex = { 0 } >
8799 < div className = "cover-container" >
@@ -95,7 +107,9 @@ export function SessionListing(props: SessionListingProps) {
95107 ) : null }
96108 </ div >
97109 < WithAvatar username = { head . author } className = "caption" small >
98- < div className = "title" > { head . title || 'Untitled' } </ div >
110+ < div className = "title" >
111+ { head . title || 'Untitled' } < span className = "tags" > { tagsStr } </ span >
112+ </ div >
99113 { /*head.description && (
100114 <div className="description">
101115 <TextToParagraphs text={head.description} />
0 commit comments