"""
This type stub file was generated by pyright.
"""

from typing import Any, TYPE_CHECKING
from docutils import nodes
from docutils.parsers.rst.directives.admonitions import BaseAdmonition
from sphinx.domains import Domain
from sphinx.util.docutils import SphinxDirective
from docutils.nodes import Element, Node
from sphinx.application import Sphinx
from sphinx.environment import BuildEnvironment
from sphinx.util.typing import OptionSpec
from sphinx.writers.html import HTML5Translator
from sphinx.writers.latex import LaTeXTranslator

"""Allow todos to be inserted into your documentation.

Inclusion of todos can be switched of by a configuration variable.
The todolist directive collects all todos of your project and lists them along
with a backlink to the original location.
"""
if TYPE_CHECKING:
    ...
logger = ...
class todo_node(nodes.Admonition, nodes.Element):
    ...


class todolist(nodes.General, nodes.Element):
    ...


class Todo(BaseAdmonition, SphinxDirective):
    """
    A todo entry, displayed (if configured) in the form of an admonition.
    """
    node_class = todo_node
    has_content = ...
    required_arguments = ...
    optional_arguments = ...
    final_argument_whitespace = ...
    option_spec: OptionSpec = ...
    def run(self) -> list[Node]:
        ...
    


class TodoDomain(Domain):
    name = ...
    label = ...
    @property
    def todos(self) -> dict[str, list[todo_node]]:
        ...
    
    def clear_doc(self, docname: str) -> None:
        ...
    
    def merge_domaindata(self, docnames: list[str], otherdata: dict) -> None:
        ...
    
    def process_doc(self, env: BuildEnvironment, docname: str, document: nodes.document) -> None:
        ...
    


class TodoList(SphinxDirective):
    """
    A list of all todo entries.
    """
    has_content = ...
    required_arguments = ...
    optional_arguments = ...
    final_argument_whitespace = ...
    option_spec: OptionSpec = ...
    def run(self) -> list[Node]:
        ...
    


class TodoListProcessor:
    def __init__(self, app: Sphinx, doctree: nodes.document, docname: str) -> None:
        ...
    
    def process(self, doctree: nodes.document, docname: str) -> None:
        ...
    
    def create_todo_reference(self, todo: todo_node, docname: str) -> nodes.paragraph:
        ...
    
    def resolve_reference(self, todo: todo_node, docname: str) -> None:
        """Resolve references in the todo content."""
        ...
    


def visit_todo_node(self: HTML5Translator, node: todo_node) -> None:
    ...

def depart_todo_node(self: HTML5Translator, node: todo_node) -> None:
    ...

def latex_visit_todo_node(self: LaTeXTranslator, node: todo_node) -> None:
    ...

def latex_depart_todo_node(self: LaTeXTranslator, node: todo_node) -> None:
    ...

def setup(app: Sphinx) -> dict[str, Any]:
    ...

