+
+ {% let groups = user.memberships_without_self() %}
+ {% if groups.len() > 0 %}
+
Groups
+
+ {% for group in groups %}
+
{{ group }}
+ {% endfor %}
+
+ {% endif %}
+
+
App tokens
+
+
+
Name
+
Created at
+
+
+ {% for app_token in app_tokens %}
+
+
{{ app_token.name }}
+
+ {% if let Some(created_at) = app_token.created_at %}
+ {{ chrono_humanize::HumanTime::from(created_at.to_owned()) }}
+ {% endif %}
+
+
+
+
+
+ {% endfor %}
+
+
+
+
+
+
+
+ {% if is_apple %}
+
+ {% endif %}
+
+
+
+ {% if let Some(hostname) = davx5_hostname %}
+ Configure
+ in DAVx5
+ {% endif %}
+
diff --git a/crates/frontend/public/templates/pages/user.html b/crates/frontend/public/templates/pages/user.html
index 7a45c1b..cb009ef 100644
--- a/crates/frontend/public/templates/pages/user.html
+++ b/crates/frontend/public/templates/pages/user.html
@@ -11,183 +11,9 @@
Welcome {{ user.id }}!
-
-
Profile
+{% include "components/profile_section.html" %}
+{% include "components/calendars_section.html" %}
+{% include "components/addressbooks_section.html" %}
-
Groups
-
- {% for group in user.memberships() %}
-
{{ group }}
- {% endfor %}
-
-
-
App tokens
-
-
-
Name
-
Created at
-
-
- {% for app_token in app_tokens %}
-
-
{{ app_token.name }}
-
- {% if let Some(created_at) = app_token.created_at %}
- {{ chrono_humanize::HumanTime::from(created_at.to_owned()) }}
- {% endif %}
-
-
-
-
-
- {% endfor %}
-
-
-
-
-
-
-
- {% if is_apple %}
-
- {% endif %}
-
-
-
- {% if let Some(hostname) = davx5_hostname %}
- Configure in DAVx5
- {% endif %}
-
-
-
-
Calendars
-
- {% for calendar in calendars %}
- {% let color = calendar.color.to_owned().unwrap_or("transparent".to_owned()) %}
-