From 6d5ff8d4698fa51ac944b4599368237dede4aef9 Mon Sep 17 00:00:00 2001 From: "Timothy J. Baek" Date: Sat, 9 Mar 2024 01:50:31 -0800 Subject: [PATCH] feat: frontend whitelist model selector --- .../components/admin/Settings/Users.svelte | 104 +++++++++++------- 1 file changed, 64 insertions(+), 40 deletions(-) diff --git a/src/lib/components/admin/Settings/Users.svelte b/src/lib/components/admin/Settings/Users.svelte index 437e437e..8f00d020 100644 --- a/src/lib/components/admin/Settings/Users.svelte +++ b/src/lib/components/admin/Settings/Users.svelte @@ -7,9 +7,7 @@ export let saveHandler: Function; let whitelistEnabled = false; - let whitelistModels = []; - let selectedModelId = ''; - + let whitelistModels = ['']; let permissions = { chat: { deletion: true @@ -102,47 +100,73 @@ {#if whitelistEnabled}
-
+
+ {#each whitelistModels as modelId, modelIdx} +
+
+ +
+ + {#if modelIdx === 0} + + {:else} + + {/if} +
+ {/each} +
+ +
{whitelistModels.length} Model(s) Whitelisted
- -
-
- -
- -
{/if}