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 3939 'showHeader ' => true ,
4040 // the frontend HTML could use CSS "white-space: pre;" to visualize consecutive whitespaces
4141 // but if you want to visualize them in the backend with " ", you can set this to true
42- 'spacesToNbsp ' => false ,
42+ 'spacesToNbsp ' => true ,
4343 // HTML renderer tab width (negative = do not convert into spaces)
44- 'tabSize ' => 4 ,
44+ 'tabSize ' => 8 ,
4545 // this option is currently only for the Combined renderer.
4646 // it determines whether a replace-type block should be merged or not
4747 // 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 @@ -312,15 +312,7 @@ protected function htmlSafe(string $string): string
312312 */
313313 protected function htmlFixSpaces (string $ string ): string
314314 {
315- return preg_replace_callback (
316- '/ {2,}/S ' , // only fix for more than 1 space
317- static function (array $ matches ): string {
318- $ count = \strlen ($ matches [0 ]);
319-
320- return str_repeat (' ' , $ count >> 1 ) . ($ count & 1 ? ' ' : '' );
321- },
322- $ string ,
323- );
315+ return str_replace (' ' , ' ' , $ string );
324316 }
325317
326318 /**
You can’t perform that action at this time.
0 commit comments