40 lines
792 B
Python
40 lines
792 B
Python
from __future__ import annotations
|
|
from typing import TypedDict, List
|
|
|
|
|
|
class ArticleConfig(TypedDict):
|
|
slug: str
|
|
name: str
|
|
iso_date: str
|
|
author: str
|
|
|
|
|
|
class ArticleContext(TypedDict):
|
|
slug: str
|
|
name: str
|
|
url: str
|
|
link: str
|
|
date: str
|
|
iso_date: str
|
|
author: str
|
|
|
|
translations: List[ArticleTranslationContext]
|
|
children: List[ArticleContext]
|
|
linked: List[ArticleContext]
|
|
related: List[ArticleContext]
|
|
|
|
|
|
class ArticleTranslationContext(TypedDict):
|
|
slug: str
|
|
name: str
|
|
url: str
|
|
link: str
|
|
date: str
|
|
iso_date: str
|
|
author: str
|
|
|
|
translations: List[ArticleTranslationContext]
|
|
children: List[ArticleTranslationContext]
|
|
linked: List[ArticleTranslationContext]
|
|
related: List[ArticleTranslationContext]
|