summaryrefslogtreecommitdiffstats
path: root/activities
diff options
context:
space:
mode:
authorAndrew Godwin2022-11-22 19:21:01 -0700
committerAndrew Godwin2022-11-22 19:21:01 -0700
commit9c424d9bb6aa0eb606128bcce3e33816967a2e8d (patch)
tree6a30edbc00381ce919e17caa89d6eaad54c586e4 /activities
parentaaad289c5211570ec98ddd9d753517ef827686dc (diff)
downloadtakahe-9c424d9bb6aa0eb606128bcce3e33816967a2e8d.tar.gz
takahe-9c424d9bb6aa0eb606128bcce3e33816967a2e8d.tar.bz2
takahe-9c424d9bb6aa0eb606128bcce3e33816967a2e8d.zip
Add manual HTMX refresh of timelines
Refs #33
Diffstat (limited to 'activities')
-rw-r--r--activities/views/timelines.py16
1 files changed, 13 insertions, 3 deletions
diff --git a/activities/views/timelines.py b/activities/views/timelines.py
index e8e74ed..e4c9920 100644
--- a/activities/views/timelines.py
+++ b/activities/views/timelines.py
@@ -46,6 +46,7 @@ class Home(FormView):
context["events"], self.request.identity
)
context["current_page"] = "home"
+ context["allows_refresh"] = True
return context
def form_valid(self, form):
@@ -60,7 +61,10 @@ class Home(FormView):
class Local(ListView):
template_name = "activities/local.html"
- extra_context = {"current_page": "local"}
+ extra_context = {
+ "current_page": "local",
+ "allows_refresh": True,
+ }
paginate_by = 50
def get_queryset(self):
@@ -76,7 +80,10 @@ class Local(ListView):
class Federated(ListView):
template_name = "activities/federated.html"
- extra_context = {"current_page": "federated"}
+ extra_context = {
+ "current_page": "federated",
+ "allows_refresh": True,
+ }
paginate_by = 50
def get_queryset(self):
@@ -92,7 +99,10 @@ class Federated(ListView):
class Notifications(ListView):
template_name = "activities/notifications.html"
- extra_context = {"current_page": "notifications"}
+ extra_context = {
+ "current_page": "notifications",
+ "allows_refresh": True,
+ }
paginate_by = 50
def get_queryset(self):