diff --git a/locales/en-US.yml b/locales/en-US.yml
index 8fa7acf9a..973b9ab72 100644
--- a/locales/en-US.yml
+++ b/locales/en-US.yml
@@ -190,7 +190,9 @@ charts: "Charts"
perHour: "Per Hour"
perDay: "Per Day"
stopActivityDelivery: "Stop sending activities"
+stopActivityDeliveryDescription: "Local activities will not be sent to this instance. Receiving activities works as before."
blockThisInstance: "Block this instance"
+blockThisInstanceDescription: "Local activites will not be sent to this instance. Activites from this instance will be discarded."
operations: "Operations"
software: "Software"
version: "Version"
diff --git a/packages/client/src/pages/instance-info.vue b/packages/client/src/pages/instance-info.vue
index 62c6d1786..55e7627d8 100644
--- a/packages/client/src/pages/instance-info.vue
+++ b/packages/client/src/pages/instance-info.vue
@@ -26,8 +26,27 @@
Moderation
- {{ i18n.ts.stopActivityDelivery }}
- {{ i18n.ts.blockThisInstance }}
+ {suspended = newValue; toggleSuspend() }"
+ :disabled="isBlocked"
+ class="_formBlock"
+ >
+ {{ i18n.ts.stopActivityDelivery }}
+
+ {{ i18n.ts.stopActivityDeliveryDescription }}
+
+
+
+ {{ i18n.ts.blockThisInstance }}
+
+ {{ i18n.ts.blockThisInstanceDescription }}
+
+
Refresh metadata
@@ -152,7 +171,7 @@ const usersPagination = {
offsetMode: true,
};
-async function fetch() {
+async function fetch(): Promise {
instance = await os.api('federation/show-instance', {
host: props.host,
});
@@ -160,21 +179,21 @@ async function fetch() {
isBlocked = instance.isBlocked;
}
-async function toggleBlock(ev) {
+async function toggleBlock(): Promise {
if (meta == null) return;
await os.api('admin/update-meta', {
blockedHosts: isBlocked ? meta.blockedHosts.concat([instance.host]) : meta.blockedHosts.filter(x => x !== instance.host),
});
}
-async function toggleSuspend(v) {
+async function toggleSuspend(): Promise {
await os.api('admin/federation/update-instance', {
host: instance.host,
isSuspended: suspended,
});
}
-function refreshMetadata() {
+function refreshMetadata(): void {
os.api('admin/federation/refresh-remote-instance-metadata', {
host: instance.host,
});