2022-02-14 01:51:37 +01:00
|
|
|
@page "/administration"
|
2026-10-05 06:20:18 +02:00
|
|
|
@attribute [Authorize(Policy = Policies.IsModerator)]
|
2022-12-15 20:03:40 +01:00
|
|
|
@inherits LocalizableComponentBase
|
2022-02-14 01:51:37 +01:00
|
|
|
|
2026-10-05 06:20:18 +02:00
|
|
|
<Title>@Localizer["Administration"]</Title>
|
|
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
@* Moderators handle reports and read the staff's log. Administrators also say what the server is (Instance), set its
|
|
|
|
|
rules, write its announcements, block servers for everyone, choose its relays and media limits, read the federation
|
|
|
|
|
statistics, and back up and restore the server. PrivaPub checks the role on every call; the sections only follow it.
|
|
|
|
|
Each section is a collapse marked data-admin-section; its panel loads when the page opens. *@
|
2026-10-03 12:08:11 +02:00
|
|
|
<section class="block relative w-full h-full neo-inset neo-xs rounded-xl">
|
2022-02-14 01:51:37 +01:00
|
|
|
|
2026-10-03 12:08:11 +02:00
|
|
|
<div class="flex flex-col gap-4 p-4 md:p-5 w-full h-full absolute overflow-y-auto">
|
2022-02-15 00:08:41 +01:00
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="reports">
|
2026-10-03 12:08:11 +02:00
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
2026-10-17 04:32:57 +02:00
|
|
|
<i class="ion-md-flag text-xl"></i> <span>@Localizer["Reports"]</span>
|
2022-02-15 00:08:41 +01:00
|
|
|
</p>
|
2026-10-03 12:08:11 +02:00
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
2022-02-15 00:08:41 +01:00
|
|
|
<div class="block w-full p-3 md:p-4">
|
2026-10-17 04:32:57 +02:00
|
|
|
<ReportsPanel />
|
2022-02-15 00:08:41 +01:00
|
|
|
</div>
|
2026-10-03 12:08:11 +02:00
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
2022-02-15 00:08:41 +01:00
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="log">
|
2026-10-03 12:08:11 +02:00
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
2026-10-17 04:32:57 +02:00
|
|
|
<i class="ion-md-list-box text-xl"></i> <span>@Localizer["Moderation log"]</span>
|
2022-02-15 00:08:41 +01:00
|
|
|
</p>
|
2026-10-03 12:08:11 +02:00
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
2022-02-15 00:08:41 +01:00
|
|
|
<div class="block w-full p-3 md:p-4">
|
2026-10-17 04:32:57 +02:00
|
|
|
<ModerationLogPanel />
|
2022-02-15 00:08:41 +01:00
|
|
|
</div>
|
2026-10-03 12:08:11 +02:00
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
2022-02-15 00:08:41 +01:00
|
|
|
|
2026-10-05 06:20:18 +02:00
|
|
|
<AuthorizeView Policy="@Policies.IsAdmin">
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="instance">
|
2026-10-05 06:20:18 +02:00
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
2026-10-17 04:32:57 +02:00
|
|
|
<i class="ion-md-information-circle text-xl"></i> <span>@Localizer["Instance"]</span>
|
2026-10-05 06:20:18 +02:00
|
|
|
</p>
|
|
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
|
|
|
|
<div class="block w-full p-3 md:p-4">
|
2026-10-17 04:32:57 +02:00
|
|
|
<InstancePanel />
|
2026-10-05 06:20:18 +02:00
|
|
|
</div>
|
|
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
|
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="rules">
|
2026-10-05 06:20:18 +02:00
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
2026-10-17 04:32:57 +02:00
|
|
|
<i class="ion-md-book text-xl"></i> <span>@Localizer["Rules"]</span>
|
2026-10-05 06:20:18 +02:00
|
|
|
</p>
|
|
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
|
|
|
|
<div class="block w-full p-3 md:p-4">
|
2026-10-17 04:32:57 +02:00
|
|
|
<RulesPanel />
|
2026-10-05 06:20:18 +02:00
|
|
|
</div>
|
|
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
2026-10-07 12:45:30 +02:00
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="announcements">
|
2026-10-07 12:45:30 +02:00
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
2026-10-17 04:32:57 +02:00
|
|
|
<i class="ion-md-megaphone text-xl"></i> <span>@Localizer["Announcements"]</span>
|
2026-10-07 12:45:30 +02:00
|
|
|
</p>
|
|
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
|
|
|
|
<div class="block w-full p-3 md:p-4">
|
2026-10-17 04:32:57 +02:00
|
|
|
<AnnouncementsPanel />
|
2026-10-07 12:45:30 +02:00
|
|
|
</div>
|
|
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
2022-02-15 00:08:41 +01:00
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="blocks">
|
|
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
|
|
|
|
<i class="ion-md-globe text-xl"></i> <span>@Localizer["Blocked servers"]</span>
|
2022-02-15 00:08:41 +01:00
|
|
|
</p>
|
2026-10-17 04:32:57 +02:00
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
|
|
|
|
<div class="block w-full p-3 md:p-4">
|
|
|
|
|
<ServerBlocksPanel />
|
|
|
|
|
</div>
|
|
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
2022-02-15 00:08:41 +01:00
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="relays">
|
|
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
|
|
|
|
<i class="ion-md-radio text-xl"></i> <span>@Localizer["Relays"]</span>
|
2022-02-15 00:08:41 +01:00
|
|
|
</p>
|
2026-10-17 04:32:57 +02:00
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
|
|
|
|
<div class="block w-full p-3 md:p-4">
|
|
|
|
|
<RelaysPanel />
|
|
|
|
|
</div>
|
|
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
2022-02-15 00:08:41 +01:00
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="media">
|
|
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
|
|
|
|
<i class="ion-md-images text-xl"></i> <span>@Localizer["Media limits"]</span>
|
2022-02-15 00:08:41 +01:00
|
|
|
</p>
|
2026-10-17 04:32:57 +02:00
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
|
|
|
|
<div class="block w-full p-3 md:p-4">
|
|
|
|
|
<MediaLimitsPanel />
|
|
|
|
|
</div>
|
|
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
2022-02-15 00:08:41 +01:00
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="statistics">
|
|
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
|
|
|
|
<i class="ion-md-stats text-xl"></i> <span>@Localizer["Statistics"]</span>
|
2022-02-15 00:08:41 +01:00
|
|
|
</p>
|
2026-10-17 04:32:57 +02:00
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
|
|
|
|
<div class="block w-full p-3 md:p-4">
|
|
|
|
|
<StatisticsPanel />
|
|
|
|
|
</div>
|
|
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
2022-02-15 00:08:41 +01:00
|
|
|
|
2026-10-17 04:32:57 +02:00
|
|
|
<DCollapse Icon="DCollapseIcon.Arrow" data-admin-section="backups">
|
|
|
|
|
<Header>
|
|
|
|
|
<p class="inline-flex items-center gap-2">
|
|
|
|
|
<i class="ion-md-archive text-xl"></i> <span>@Localizer["Backups"]</span>
|
2022-02-15 00:08:41 +01:00
|
|
|
</p>
|
2026-10-17 04:32:57 +02:00
|
|
|
</Header>
|
|
|
|
|
<ChildContent>
|
|
|
|
|
<div class="block w-full p-3 md:p-4">
|
|
|
|
|
<BackupsPanel />
|
|
|
|
|
</div>
|
|
|
|
|
</ChildContent>
|
|
|
|
|
</DCollapse>
|
|
|
|
|
</AuthorizeView>
|
2022-02-15 00:08:41 +01:00
|
|
|
|
2022-02-14 01:51:37 +01:00
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</section>
|