diff --git a/dashboard/src/components/list/ListView.svelte b/dashboard/src/components/list/ListView.svelte
index b66c3ae8..9026b990 100644
--- a/dashboard/src/components/list/ListView.svelte
+++ b/dashboard/src/components/list/ListView.svelte
@@ -10,13 +10,13 @@
import MemberBody from '../member/Body.svelte';
import GroupBody from '../group/Body.svelte';
import CardsHeader from '../common/CardsHeader.svelte';
- import { defaultListOptions, type List, type ListOptions, type PageOptions } from './types';
+ import { defaultListOptions, type ListOptions, type PageOptions } from './types';
let settings = JSON.parse(localStorage.getItem("pk-settings"));
export let options: ListOptions = JSON.parse(JSON.stringify(defaultListOptions));
- export let otherList: List ;
- export let lists: List;
+ export let fullListLength: number;
+ export let currentList: Member[]|Group[];
export let pageOptions: PageOptions;
function getItemLink(item: Member | Group): string {
@@ -39,13 +39,13 @@
let el;
if (event.key === "ArrowDown") {
- if (index + 1 < indexStart + pageOptions.itemsPerPage && index + 1 < lists.processedList.length) el = document.getElementById(`${pageOptions.type}-card-${index + 1}`);
+ if (index + 1 < indexStart + pageOptions.itemsPerPage && index + 1 < fullListLength) el = document.getElementById(`${pageOptions.type}-card-${index + 1}`);
else el = document.getElementById(`${pageOptions.type}-card-${indexStart}`);
}
if (event.key === "ArrowUp") {
if (index - 1 >= indexStart) el = document.getElementById(`${pageOptions.type}-card-${index - 1}`);
- else if (lists.processedList.length <= indexStart + pageOptions.itemsPerPage) el = document.getElementById(`${pageOptions.type}-card-${lists.processedList.length - 1}`);
+ else if (fullListLength <= indexStart + pageOptions.itemsPerPage) el = document.getElementById(`${pageOptions.type}-card-${fullListLength - 1}`);
else el = document.getElementById(`${pageOptions.type}-card-${indexStart + pageOptions.itemsPerPage - 1}`);
}
@@ -114,12 +114,12 @@
{#if (settings && settings.accessibility ? (!settings.accessibility.expandedcards && !settings.accessibility.pagelinks) : true)}
- {#each lists.currentPage as item, index (pageOptions.randomized ? item.uuid + '-' + index : item.uuid)}
+ {#each currentList as item, index (pageOptions.randomized ? item.uuid + '-' + index : item.uuid)}
{:else if settings.accessibility.expandedcards}
- {#each lists.currentPage as item, index (pageOptions.randomized ? item.uuid + '-' + index : item.uuid)}
+ {#each currentList as item, index (pageOptions.randomized ? item.uuid + '-' + index : item.uuid)}
-
-{/if}
\ No newline at end of file
+{/if}
+
+
\ No newline at end of file
diff --git a/dashboard/src/components/list/MemberList.svelte b/dashboard/src/components/list/MemberList.svelte
new file mode 100644
index 00000000..7ed3b33e
--- /dev/null
+++ b/dashboard/src/components/list/MemberList.svelte
@@ -0,0 +1,103 @@
+
+
+
+
+{#if listLoading && !err}
+
+
+
+{:else if err}
+
+
+ {err}
+
+
+ Refresh
+
+
+{:else}
+{members.length} {pageOptions.type}s ({currentMembers.length} shown) {e.preventDefault(); fetchList()}}>Refresh list
+
+
+
+{#if !err && !pageOptions.isPublic}
+
+{/if}
+{#if pageOptions.view === "card"}
+
+{:else if pageOptions.view === "tiny"}
+ tiny!
+{:else}
+
+{/if}
+
+{/if}
+
+
\ No newline at end of file
diff --git a/dashboard/src/components/member/Body.svelte b/dashboard/src/components/member/Body.svelte
index 954c314d..0bc6293f 100644
--- a/dashboard/src/components/member/Body.svelte
+++ b/dashboard/src/components/member/Body.svelte
@@ -198,8 +198,8 @@
View system
{/if}
{:else if editMode}
-
+
{:else if groupMode}
-
+
{/if}
diff --git a/dashboard/src/components/member/CardView.svelte b/dashboard/src/components/member/CardView.svelte
index 147cbf87..d81c0390 100644
--- a/dashboard/src/components/member/CardView.svelte
+++ b/dashboard/src/components/member/CardView.svelte
@@ -1,5 +1,5 @@
{#if settings && settings.appearance.color_background && !notOwnSystem}
@@ -173,7 +162,7 @@
{:else if group && group.id}
-
+