Skip to content

Commit

Permalink
feat: add groups to app ctx
Browse files Browse the repository at this point in the history
  • Loading branch information
rubenfiszel committed Jul 4, 2023
1 parent dda9920 commit 499dd5b
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions frontend/src/lib/components/apps/editor/AppEditor.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
const pickVariableCallback: Writable<((path: string) => void) | undefined> = writable(undefined)
let context = {
email: $userStore?.email,
groups: $userStore?.groups,
username: $userStore?.username,
query: Object.fromEntries($page.url.searchParams.entries()),
hash: $page.url.hash,
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/routes/(root)/(logged)/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,8 @@
isEditor={false}
context={{
username: $userStore?.username ?? 'anonymous',
email: $userStore?.email ?? 'anonymous'
email: $userStore?.email ?? 'anonymous',
groups: $userStore?.groups ?? []
}}
summary={appViewerApp?.app.summary ?? ''}
noBackend
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
context={{
email: $userStore?.email,
username: $userStore?.username,
groups: $userStore?.groups,
query: Object.fromEntries($page.url.searchParams.entries()),
hash: $page.url.hash
}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
noBackend={false}
context={{
email: $userStore?.email,
groups: $userStore?.groups,
username: $userStore?.username,
query: Object.fromEntries($page.url.searchParams.entries()),
hash: $page.url.hash
Expand Down

0 comments on commit 499dd5b

Please sign in to comment.