mirror of
https://github.com/web3privacy/explorer-app.git
synced 2024-10-15 16:46:26 +02:00
fix: fundings
This commit is contained in:
parent
45b00432e9
commit
caf8f42620
1 changed files with 4 additions and 4 deletions
|
@ -11,7 +11,7 @@ type Fundings = {
|
|||
}
|
||||
|
||||
function useFundings(project?: Partial<Project>) {
|
||||
const fundings = ref<Fundings[]>(Array.isArray(project?.funding) ? project?.funding as unknown as Fundings[] : [project?.funding as unknown as Fundings])
|
||||
const fundings = ref(Array.isArray(project?.funding) ? project.funding : (project?.funding ? [project.funding] : []))
|
||||
const newFunding = reactive<Fundings>({
|
||||
name: '',
|
||||
link: '',
|
||||
|
@ -58,7 +58,7 @@ defineExpose({
|
|||
/>
|
||||
<ProjectCreateComponentsItem
|
||||
v-for="funding in fundings"
|
||||
:key="funding.name"
|
||||
:key="funding?.name"
|
||||
@remove="() => removeFunding(fundings?.indexOf(funding))"
|
||||
>
|
||||
<template #label>
|
||||
|
@ -69,13 +69,13 @@ defineExpose({
|
|||
<span
|
||||
class="text-app-black text-14px font-700"
|
||||
lg="text-16px"
|
||||
> {{ funding.name }}
|
||||
> {{ funding?.name }}
|
||||
</span>
|
||||
</div>
|
||||
</template>
|
||||
<template #desc>
|
||||
<NuxtLink
|
||||
:to="funding.link"
|
||||
:to="funding?.link"
|
||||
hover:text-app-black
|
||||
class="text-app-black/50 text-16px hidden"
|
||||
lg="block"
|
||||
|
|
Loading…
Reference in a new issue