#13: Přidáno deprecation varování do původní html funkce.

This commit is contained in:
Jan Černohorský 2023-07-19 15:30:51 +02:00
parent fe0345570c
commit cfbe3e128d

View file

@ -13,8 +13,13 @@ from .util import inlinify
from .context import Group
from .images import ImageProcessor
import warnings
warnings.warn("The html function has been deprecated, is left only for reference and will be removed in future commits. HTML_generator should be used in its place.", DeprecationWarning)
def html(e: Union[Element, ListContainer], k: KatexClient, i: ImageProcessor, indent_level: int=0, indent_str: str="\t") -> str:
warnings.warn("The html function has been deprecated, is left only for reference and will be removed in future commits. HTML_generator should be used in its place.", DeprecationWarning)
# `only` attribute which makes transformed elements appear only in tex
# output or html output
if hasattr(e, "attributes") and "only" in e.attributes and e.attributes["only"] != "html":