File tree Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -60,7 +60,7 @@ function MeunItemView(props: { path?: string; filepath?: string; size?: number }
6060 { ...menuProps }
6161 text = { props . filepath ! . replace ( / ^ \/ / , '' ) }
6262 />
63- ) ,
63+ ) ,
6464 // eslint-disable-next-line react-hooks/exhaustive-deps
6565 [ props . path , props . size , props . filepath ] ,
6666 ) ;
@@ -74,7 +74,7 @@ export default function DirectoryTrees() {
7474 pkgname : global . pkgname ,
7575 } ) ) ;
7676
77- const pathname = location . pathname . replace ( new RegExp ( `/pkg/${ pkgname } /file` ) , '' )
77+ const pathname = location . pathname . replace ( new RegExp ( `/pkg/${ pkgname } /file` ) , '' ) ;
7878
7979 function renderMenuItem ( data : Files [ ] = [ ] , menuItems : any = [ ] ) {
8080 data . forEach ( ( item , idx ) => {
@@ -85,7 +85,7 @@ export default function DirectoryTrees() {
8585 key = { idx }
8686 icon = "folder"
8787 overlayProps = { {
88- isOpen : collapse
88+ isOpen : collapse ,
8989 } }
9090 style = { { color : '#1d64ce' } }
9191 text = { item . path . replace ( / ^ \/ / , '' ) . replace ( / ( .+ ?) .\/ / g, '' ) }
Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ export default function Preview() {
5656 size = "small"
5757 type = "link"
5858 onClick = { ( ) => dispatch . global . update ( { showSearch : true } ) }
59- style = { { fontSize : 21 } }
59+ style = { { fontSize : 21 , whiteSpace : 'nowrap' } }
6060 >
6161 { Info && Info . name ? `${ Info . name } @${ Info . version } ` : path . pkgName }
6262 </ Button >
@@ -128,7 +128,9 @@ export default function Preview() {
128128 { Info . description && (
129129 < Fragment >
130130 < Divider type = "vertical" />
131- < span title = { Info . description } > { Info . description } </ span >
131+ < span title = { Info . description } style = { { flex : 1 , whiteSpace : 'nowrap' , overflow : 'hidden' } } >
132+ { Info . description }
133+ </ span >
132134 </ Fragment >
133135 ) }
134136 </ Fragment >
You can’t perform that action at this time.
0 commit comments