[Glitch] Add notification policies and notification requests in web UI

Port c10bbf5fe3 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
Eugen Rochko
2024-03-11 16:02:21 +01:00
committed by Claire
parent 3631ddbfc9
commit 13c9524436
27 changed files with 1324 additions and 291 deletions

View File

@@ -69,3 +69,11 @@ export function pluralReady(
export function roundTo10(num: number): number {
return Math.round(num * 0.1) / 0.1;
}
export function toCappedNumber(num: string): string {
if (parseInt(num) > 99) {
return '99+';
} else {
return num;
}
}