Skip to content

Commit

Permalink
TYP: annotate in style_render
Browse files Browse the repository at this point in the history
  • Loading branch information
jbrockmendel committed Oct 7, 2023
1 parent 35bcf18 commit a50f4a2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pandas/io/formats/style_render.py
Original file line number Diff line number Diff line change
Expand Up @@ -2357,7 +2357,7 @@ def color(value, user_arg, command, comm_arg):
return latex_styles


def _escape_latex(s):
def _escape_latex(s: str) -> str:
r"""
Replace the characters ``&``, ``%``, ``$``, ``#``, ``_``, ``{``, ``}``,
``~``, ``^``, and ``\`` in the string with LaTeX-safe sequences.
Expand Down Expand Up @@ -2392,7 +2392,7 @@ def _escape_latex(s):
)


def _math_mode_with_dollar(s):
def _math_mode_with_dollar(s: str) -> str:
r"""
All characters in LaTeX math mode are preserved.
Expand Down Expand Up @@ -2425,7 +2425,7 @@ def _math_mode_with_dollar(s):
return "".join(res).replace(r"rt8§=§7wz", r"\$")


def _math_mode_with_parentheses(s):
def _math_mode_with_parentheses(s: str) -> str:
r"""
All characters in LaTeX math mode are preserved.
Expand Down Expand Up @@ -2461,7 +2461,7 @@ def _math_mode_with_parentheses(s):
return "".join(res)


def _escape_latex_math(s):
def _escape_latex_math(s: str) -> str:
r"""
All characters in LaTeX math mode are preserved.
Expand Down

0 comments on commit a50f4a2

Please sign in to comment.