-
Notifications
You must be signed in to change notification settings - Fork 240
Open
Labels
Bug Report 🐛Issue contains a bug reportIssue contains a bug reportNeeds triage 🔍Issue needs triagingIssue needs triaging
Description
Have you already looked into this bug?
- I've reviewed the release notes for relevant migration steps
- I've searched through existing issues for similar reports
- I've already searched online (e.g. Dash documentation) but couldn't find anything relevant
Which package?
vizro
Package version
Latest
Description
The default highlight.js code syntax highlighting is not readable in Virzo dark mode.
How to Reproduce
Add a vm.Text element to any dashboard as follows:
vm.Text(text="""```python
\"\"\"Module Docstring\"\"\"
import time as vizro_time
from typing import Optional
import regex
class MyClass(object):
def __init__(self, arg: int, *, kwarg=1, **kwargs):
# a comment
self._arg = arg
self._kwargs = dict(kw1=kwarg)
self._kwargs.update({k: w for k, w in kwargs.items() if k.startswith("kw")})
@property
def bad_arg(self) -> Optional[int]:
if vizro_time.time() % 2 == 0:
return self._arg >> 5
return None
@bad_arg.setter
def bad_arg(self, value: str):
\"\"\"
Sets bad_arg if the value is a string representing an integer.
Args:
value (str): The string to set as bad_arg.
\"\"\"
match = regex.match(r"^\d+$", value)
if match:
self._arg = int(value)
else:
raise ValueError("bad_arg must be a string representing an integer")
""")Output
Code of Conduct
- I agree to follow the Code of Conduct.
Metadata
Metadata
Assignees
Labels
Bug Report 🐛Issue contains a bug reportIssue contains a bug reportNeeds triage 🔍Issue needs triagingIssue needs triaging