Responsive styling fix, shorter pages

Refs #102
This commit is contained in:
Andrew Godwin 2022-12-22 01:05:30 +00:00
parent 4657a1eece
commit f9b5f372ac
2 changed files with 7 additions and 6 deletions

View file

@ -23,7 +23,7 @@ class Home(TemplateView):
def get_context_data(self): def get_context_data(self):
events = TimelineService(self.request.identity).home() events = TimelineService(self.request.identity).home()
paginator = Paginator(events, 50) paginator = Paginator(events, 25)
page_number = self.request.GET.get("page") page_number = self.request.GET.get("page")
context = { context = {
"interactions": PostInteraction.get_event_interactions( "interactions": PostInteraction.get_event_interactions(
@ -48,7 +48,7 @@ class Tag(ListView):
"current_page": "tag", "current_page": "tag",
"allows_refresh": True, "allows_refresh": True,
} }
paginate_by = 50 paginate_by = 25
def get(self, request, hashtag, *args, **kwargs): def get(self, request, hashtag, *args, **kwargs):
tag = hashtag.lower().lstrip("#") tag = hashtag.lower().lstrip("#")
@ -80,7 +80,7 @@ class Local(ListView):
"current_page": "local", "current_page": "local",
"allows_refresh": True, "allows_refresh": True,
} }
paginate_by = 50 paginate_by = 25
def get_queryset(self): def get_queryset(self):
return TimelineService(self.request.identity).local() return TimelineService(self.request.identity).local()
@ -101,7 +101,7 @@ class Federated(ListView):
"current_page": "federated", "current_page": "federated",
"allows_refresh": True, "allows_refresh": True,
} }
paginate_by = 50 paginate_by = 25
def get_queryset(self): def get_queryset(self):
return TimelineService(self.request.identity).federated() return TimelineService(self.request.identity).federated()
@ -122,7 +122,7 @@ class Notifications(ListView):
"current_page": "notifications", "current_page": "notifications",
"allows_refresh": True, "allows_refresh": True,
} }
paginate_by = 50 paginate_by = 25
notification_types = { notification_types = {
"followed": TimelineEvent.Types.followed, "followed": TimelineEvent.Types.followed,
"boosted": TimelineEvent.Types.boosted, "boosted": TimelineEvent.Types.boosted,

View file

@ -1227,7 +1227,8 @@ table.metadata td .emoji {
} }
@media (max-width: 920px) or (display-mode: standalone) { @media (max-width: 920px),
(display-mode: standalone) {
html { html {
scrollbar-color: var(--color-bg-main) var(--color-text-duller); scrollbar-color: var(--color-bg-main) var(--color-text-duller);