File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -33,8 +33,8 @@ function formatMappingHelpPage(
3333) : Page [ ] {
3434 const operator = " ➙ " ;
3535 const spacer = " " ;
36- const lhsWidth = Math . max ( ...mappings . map ( ( { lhs } ) => lhs . length ) ) ;
37- const rhsWidth = Math . max ( ...mappings . map ( ( { rhs } ) => rhs . length ) ) ;
36+ const lhsWidth = Math . max ( ...mappings . map ( ( { lhs } ) => getByteLength ( lhs ) ) ) ;
37+ const rhsWidth = Math . max ( ...mappings . map ( ( { rhs } ) => getByteLength ( rhs ) ) ) ;
3838 const columnWidth = Math . min (
3939 width ,
4040 lhsWidth + rhsWidth + operator . length + spacer . length ,
@@ -58,7 +58,7 @@ function formatMappingHelpPage(
5858 const content = [ ...range ( 0 , height ) ]
5959 . map ( ( _ , i ) => {
6060 return columns
61- . map ( ( column ) => column [ i ] ?? "" )
61+ . map ( ( column ) => column [ i ] ?? " " . repeat ( columnWidth ) )
6262 . join ( spacer ) ;
6363 } )
6464 . filter ( ( c ) => c . trim ( ) !== "" ) ;
You can’t perform that action at this time.
0 commit comments