from django import template
from django.template.base import FilterExpression, Parser, Token
from django.template.context import Context
from django.utils.functional import Promise
from django.utils.safestring import SafeString
from wagtail.models import Page, Site
from wagtail.rich_text import RichText

register: template.Library

def pageurl(context: Context, page: Page | None, fallback: str | None = ...) -> str | None: ...
def fullpageurl(context: Context, page: Page | None, fallback: str | None = ...) -> str | None: ...
def slugurl(context: Context, slug: str) -> str | None: ...
def wagtail_version() -> str: ...
def wagtail_documentation_path() -> str: ...
def wagtail_release_notes_path() -> str: ...
def wagtail_feature_release_whats_new_link() -> str: ...
def wagtail_feature_release_editor_guide_link() -> str: ...
def richtext(value: str | RichText | Promise | None) -> RichText | SafeString: ...

class IncludeBlockNode(template.Node):
    block_var: FilterExpression
    extra_context: dict[str, FilterExpression] | None
    use_parent_context: bool
    def __init__(
        self,
        block_var: FilterExpression,
        extra_context: dict[str, FilterExpression] | None,
        use_parent_context: bool,
    ) -> None: ...
    def render(self, context: Context) -> str: ...

def include_block(parser: Parser, token: Token) -> IncludeBlockNode: ...
def wagtail_site(context: Context) -> Site | None: ...
