Skip to content

Commit

Permalink
Merge pull request #33 from holonauts/feat/my-applications
Browse files Browse the repository at this point in the history
feat(ui): my applications page
  • Loading branch information
mattyg committed Feb 29, 2024
2 parents 175dfa1 + dd28824 commit bd3000d
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 4 deletions.
4 changes: 2 additions & 2 deletions ui/src/lib/components/BaseNavbar.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
<div class="flex items-center space-x-8">
<NavLi href="/time-periods">Time Periods</NavLi>
<NavLi href="/grant-pools">Grant Pools</NavLi>
<NavLi>My Applications</NavLi>
<NavLi>My Evaluations</NavLi>
<NavLi href="/my-applications">My Applications</NavLi>
<NavLi href="/my-evaluations">My Evaluations</NavLi>
<Button
color="alternative"
size="xs"
Expand Down
2 changes: 1 addition & 1 deletion ui/src/lib/components/RecordList.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script lang="ts">
import { toasts } from '$lib/stores/toast';
import type { GrantsSignal } from '../../grant_pools/grants/types';
import type { ActionHash, AppAgentCallZomeRequest, Link } from '@holochain/client';
import type { ActionHash, AgentPubKey, AppAgentCallZomeRequest, Link } from '@holochain/client';
import { onMount } from 'svelte';
import { holochainClient } from '$lib/stores/holochainClient';
import Alert from 'flowbite-svelte/Alert.svelte';
Expand Down
Empty file.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script lang="ts">
import ApplicationListItem from './ApplicationListItem.svelte';
import ApplicationListItem from '$lib/components/ApplicationListItem.svelte';
import RecordList from '$lib/components/RecordList.svelte';
import { decodeHashFromBase64 } from '@holochain/client';
import { page } from '$app/stores';
Expand Down
23 changes: 23 additions & 0 deletions ui/src/routes/my-applications/+page.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<script lang="ts">
import ApplicationListItem from '$lib/components/ApplicationListItem.svelte';
import BaseBreadcrumbs from '$lib/components/BaseBreadcrumbs.svelte';
import RecordList from '$lib/components/RecordList.svelte';
import { holochainClient } from '$lib/stores/holochainClient';
</script>

<BaseBreadcrumbs title="My Applications" />

<RecordList
entryType=" "
callZomeRequest={{
cap_secret: null,
role_name: 'grant_pools',
zome_name: 'grants',
fn_name: 'get_my_applications',
payload: $holochainClient.client.myPubKey
}}
>
<svelte:fragment let:hash>
<ApplicationListItem applicationHash={hash} />
</svelte:fragment>
</RecordList>

0 comments on commit bd3000d

Please sign in to comment.