1
0
Fork 0
bookwyrm/bookwyrm/activitypub/image.py

21 lines
357 B
Python
Raw Normal View History

2021-03-08 08:49:10 -08:00
""" an image, nothing fancy """
2020-11-27 17:58:21 -08:00
from dataclasses import dataclass
2020-11-27 20:11:22 -08:00
from .base_activity import ActivityObject
2020-11-27 17:58:21 -08:00
2021-03-08 08:49:10 -08:00
2020-11-27 20:11:22 -08:00
@dataclass(init=False)
2021-04-15 16:35:04 -07:00
class Document(ActivityObject):
2021-04-26 09:15:42 -07:00
"""a document"""
2021-03-08 08:49:10 -08:00
2020-11-27 17:58:21 -08:00
url: str
2021-03-08 08:49:10 -08:00
name: str = ""
2021-03-15 13:55:48 -07:00
type: str = "Document"
id: str = None
2021-04-17 11:47:48 -07:00
2021-04-17 11:57:06 -07:00
2021-04-17 11:47:48 -07:00
@dataclass(init=False)
class Image(Document):
2021-04-26 09:15:42 -07:00
"""an image"""
2021-04-17 11:57:06 -07:00
2021-04-17 11:47:48 -07:00
type: str = "Image"