from typing import Any

from django.http import HttpRequest
from django.http.response import HttpResponseBase
from django.template.response import TemplateResponse
from django.utils.functional import _StrPromise

class PreviewableMixin:
    DEFAULT_PREVIEW_MODES: list[tuple[str, _StrPromise]]
    DEFAULT_PREVIEW_SIZES: list[dict[str, str | int | _StrPromise]]

    @property
    def preview_modes(self) -> list[tuple[str, _StrPromise]]: ...
    @property
    def default_preview_mode(self) -> str: ...
    @property
    def preview_sizes(self) -> list[dict[str, str | int | _StrPromise]]: ...
    @property
    def default_preview_size(self) -> str: ...
    @property
    def full_url(self) -> str | None: ...
    def get_full_url(self) -> str | None: ...
    def make_preview_request(
        self,
        original_request: HttpRequest | None = ...,
        preview_mode: str | None = ...,
        extra_request_attrs: dict[str, Any] | None = ...,
    ) -> HttpResponseBase: ...
    def _get_fallback_hostname(self) -> str: ...
    def _get_dummy_headers(self, original_request: HttpRequest | None = ...) -> dict[str, str]: ...
    def _get_dummy_header_url(self, original_request: HttpRequest | None = ...) -> str | None: ...
    def is_previewable(self) -> bool: ...
    def serve_preview(self, request: HttpRequest, mode_name: str) -> TemplateResponse: ...
    def get_preview_context(self, request: HttpRequest, mode_name: str) -> dict[str, Any]: ...
    def get_preview_template(self, request: HttpRequest, mode_name: str) -> str: ...
