File tree Expand file tree Collapse file tree 4 files changed +5
-13
lines changed Expand file tree Collapse file tree 4 files changed +5
-13
lines changed Original file line number Diff line number Diff line change 3737 'showHeader ' => true ,
3838 // the frontend HTML could use CSS "white-space: pre;" to visualize consecutive whitespaces
3939 // but if you want to visualize them in the backend with " ", you can set this to true
40- 'spacesToNbsp ' => false ,
40+ 'spacesToNbsp ' => true ,
4141 // HTML renderer tab width (negative = do not convert into spaces)
42- 'tabSize ' => 4 ,
42+ 'tabSize ' => 8 ,
4343 // this option is currently only for the Combined renderer.
4444 // it determines whether a replace-type block should be merged or not
4545 // depending on the content changed ratio, which values between 0 and 1.
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ Just a context separator. 1
77M
88N
99Do you know in Japanese, "魚の缶詰" means fish can.
10- Tab visualization test.
10+ a Tab visualization test.
1111G
1212Say hello to my neighbors.
1313A
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ Just a context separator. 1
66M
77N
88Do you know in Chinese, "金槍魚罐頭" means tuna can.
9- Tab visualization test.
9+ a Tab visualization test.
1010G
1111// remember to delete this line
1212Say hello to my neighbors.
Original file line number Diff line number Diff line change @@ -314,15 +314,7 @@ protected function htmlSafe(string $string): string
314314 */
315315 protected function htmlFixSpaces (string $ string ): string
316316 {
317- return \preg_replace_callback (
318- '/ {2,}/S ' , // only fix for more than 1 space
319- function (array $ matches ): string {
320- $ count = \strlen ($ matches [0 ]);
321-
322- return \str_repeat (' ' , $ count >> 1 ) . ($ count & 1 ? ' ' : '' );
323- },
324- $ string
325- );
317+ return \str_replace (' ' , ' ' , $ string );
326318 }
327319
328320 /**
You can’t perform that action at this time.
0 commit comments