Skip to content

Commit

Permalink
refactor: Remove unused func
Browse files Browse the repository at this point in the history
  • Loading branch information
attakei committed May 8, 2024
1 parent 296a13b commit 48ba84a
Showing 1 changed file with 1 addition and 21 deletions.
22 changes: 1 addition & 21 deletions sphinx_revealjs/writers.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
"""Custom write module."""

from docutils.nodes import ( # type: ignore
Element,
SkipNode,
comment,
literal_block,
section,
)
from docutils.nodes import SkipNode, comment, literal_block, section # type: ignore
from sphinx.util.docutils import nodes
from sphinx.util.logging import getLogger
from sphinx.writers.html5 import HTML5Translator
Expand All @@ -17,20 +11,6 @@
logger = getLogger(__name__)


def has_child_sections(node: Element, name: str):
"""Search has specified section in children."""
nodes = set([n.tagname for n in node.children])
return name in nodes


def find_child_section(node: Element, name: str):
"""Search and return first specified section in children."""
for n in node.children:
if n.tagname == name:
return n
return None


class RevealjsSlideTranslator(HTML5Translator):
"""Translate Reveal.js HTML class."""

Expand Down

0 comments on commit 48ba84a

Please sign in to comment.