Contributed stubs for slugify package (#4429)

Co-authored-by: Eric Traut <erictr@microsoft.com>
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
This commit is contained in:
Eric Traut
2020-08-10 13:34:47 -07:00
committed by GitHub
parent 9a4df32d86
commit 0ee7b26ce1
3 changed files with 29 additions and 0 deletions

View File

@@ -0,0 +1,2 @@
from .slugify import *
from .special import *

19
third_party/2and3/slugify/slugify.pyi vendored Normal file
View File

@@ -0,0 +1,19 @@
from typing import Iterable, Optional
def smart_truncate(
string: str, max_length: int = ..., word_boundary: bool = ..., separator: str = ..., save_order: bool = ...
) -> str: ...
def slugify(
text: str,
entities: bool = ...,
decimal: bool = ...,
hexadecimal: bool = ...,
max_length: int = ...,
word_boundary: bool = ...,
separator: str = ...,
save_order: bool = ...,
stopwords: Iterable[str] = ...,
regex_pattern: Optional[str] = ...,
lowercase: bool = ...,
replacements: Iterable[str] = ...,
) -> str: ...

8
third_party/2and3/slugify/special.pyi vendored Normal file
View File

@@ -0,0 +1,8 @@
from typing import Sequence, Tuple
def add_uppercase_char(char_list: Sequence[Tuple[str, str]]) -> Sequence[Tuple[str, str]]: ...
CYRILLIC: Sequence[Tuple[str, str]]
GERMAN: Sequence[Tuple[str, str]]
GREEK: Sequence[Tuple[str, str]]
PRE_TRANSLATIONS: Sequence[Tuple[str, str]]