mirror of
https://github.com/davidhalter/django-stubs.git
synced 2025-12-07 04:34:29 +08:00
renderer = BaseRenderer instead of EngineMixin in Widget.render() (#481)
This commit is contained in:
@@ -3,7 +3,7 @@ from itertools import chain
|
||||
from typing import Any, Callable, Dict, Iterable, Iterator, List, Mapping, Optional, Sequence, Set, Tuple, Type, Union
|
||||
|
||||
from django.core.files.base import File
|
||||
from django.forms.renderers import EngineMixin
|
||||
from django.forms.renderers import BaseRenderer
|
||||
from django.utils.safestring import SafeText
|
||||
|
||||
_OptAttrs = Dict[str, Any]
|
||||
@@ -42,7 +42,7 @@ class Widget:
|
||||
def format_value(self, value: Any) -> Optional[str]: ...
|
||||
def get_context(self, name: str, value: Any, attrs: Optional[_OptAttrs]) -> Dict[str, Any]: ...
|
||||
def render(
|
||||
self, name: str, value: Any, attrs: Optional[_OptAttrs] = ..., renderer: Optional[EngineMixin] = ...
|
||||
self, name: str, value: Any, attrs: Optional[_OptAttrs] = ..., renderer: Optional[BaseRenderer] = ...
|
||||
) -> SafeText: ...
|
||||
def build_attrs(
|
||||
self, base_attrs: _OptAttrs, extra_attrs: Optional[_OptAttrs] = ...
|
||||
|
||||
Reference in New Issue
Block a user