also support zero-padded color codes
This commit is contained in:
parent
6d2c15ed2c
commit
5b70f37796
1 changed files with 1 additions and 1 deletions
|
@ -160,7 +160,7 @@ def _color_tokens(s: str) -> typing.List[str]:
|
||||||
can_add = True
|
can_add = True
|
||||||
current_color = background if is_background else foreground
|
current_color = background if is_background else foreground
|
||||||
if current_color:
|
if current_color:
|
||||||
can_add = int(current_color) == 1
|
can_add = int(current_color) < 2
|
||||||
|
|
||||||
if char.isdigit() and can_add:
|
if char.isdigit() and can_add:
|
||||||
if is_background:
|
if is_background:
|
||||||
|
|
Loading…
Reference in a new issue