python 3.9+
This commit is contained in:
parent
76d340a38b
commit
8ee3fb7a8b
@ -1,7 +1,9 @@
|
|||||||
"""Shiki syntax hghlighter component."""
|
"""Shiki syntax hghlighter component."""
|
||||||
|
|
||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
from collections import defaultdict
|
from collections import defaultdict
|
||||||
from typing import Any, Literal, Optional, Union
|
from typing import Any, Literal
|
||||||
|
|
||||||
from reflex.base import Base
|
from reflex.base import Base
|
||||||
from reflex.components.component import Component, ComponentNamespace
|
from reflex.components.component import Component, ComponentNamespace
|
||||||
@ -528,8 +530,8 @@ class ShikiHighLevelCodeBlock(ShikiCodeBlock):
|
|||||||
def create(
|
def create(
|
||||||
cls,
|
cls,
|
||||||
*children,
|
*children,
|
||||||
can_copy: Optional[bool] = False,
|
can_copy: bool | None = False,
|
||||||
copy_button: Optional[Union[bool, Component]] = None,
|
copy_button: bool | Component | None = None,
|
||||||
**props,
|
**props,
|
||||||
) -> Component:
|
) -> Component:
|
||||||
"""Create a code block component using [shiki syntax highlighter](https://shiki.matsu.io/).
|
"""Create a code block component using [shiki syntax highlighter](https://shiki.matsu.io/).
|
||||||
|
Loading…
Reference in New Issue
Block a user