MilanoteUnofficialApi.elements.tasklist

 1from .element import Element
 2from .location import Location
 3from .meta import Meta
 4
 5
 6class TaskList(Element):
 7    """
 8    A Milanote task list contains Tasks.
 9    """
10
11    id: str
12    """ID of the element."""
13    element_type: str
14    """Type of the element."""
15    meta: Meta
16    """Metadata of the element."""
17    location: Location
18    """Location of the element."""
19    title: str
20    """Title of the task list."""
21
22    def __init__(self, data: dict):
23        super().__init__(data)
24        self.title = data["content"]["title"]
25
26    def __repr__(self):
27        return f"TaskList(id={self.id}, title={self.title})"
class TaskList(MilanoteUnofficialApi.elements.element.Element):
 7class TaskList(Element):
 8    """
 9    A Milanote task list contains Tasks.
10    """
11
12    id: str
13    """ID of the element."""
14    element_type: str
15    """Type of the element."""
16    meta: Meta
17    """Metadata of the element."""
18    location: Location
19    """Location of the element."""
20    title: str
21    """Title of the task list."""
22
23    def __init__(self, data: dict):
24        super().__init__(data)
25        self.title = data["content"]["title"]
26
27    def __repr__(self):
28        return f"TaskList(id={self.id}, title={self.title})"

A Milanote task list contains Tasks.

TaskList(data: dict)
23    def __init__(self, data: dict):
24        super().__init__(data)
25        self.title = data["content"]["title"]
id: str

ID of the element.

element_type: str

Type of the element.

Metadata of the element.

Location of the element.

title: str

Title of the task list.