Skip to content

Commit

Permalink
Add harvester blank state (#202)
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolaskempf57 authored Dec 16, 2024
1 parent 1a3f384 commit 6c93d1a
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 8 deletions.
7 changes: 4 additions & 3 deletions components/AdminPublishButton/AdminPublishButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@
<NuxtLinkLocale
v-if="!config.public.readOnlyMode"
:to="link"
:external="type === 'harvester'"
class="fr-btn fr-icon-add-line fr-btn--icon-left"
>
<span>{{ t("Publish on") }}</span>
<span v-if="type === 'harvester'">{{ t("Create an harvester on") }}</span>
<span v-else>{{ t("Publish on") }}</span>
<SiteLogo
class="ml-1.5 mt-0.5 h-4"
white
Expand All @@ -29,8 +31,7 @@ const link = computed(() => {
case 'dataset':
return '/beta/admin/datasets/new'
case 'harvester':
return ''
// return `${admin_root}harvester/new/`;
return `/admin/harvester/new/`
case 'reuse':
return '/beta/admin/reuses/new'
case 'dataservice':
Expand Down
11 changes: 6 additions & 5 deletions components/Harvesters/AdminHarvestersPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -114,13 +114,14 @@
v-else
class="flex flex-col items-center"
>
<!-- <nuxt-img
src="/illustrations/reuse.svg"
class="h-20"
/> -->
<nuxt-img
src="/illustrations/harvester.svg"
class="w-24"
/>
<p class="fr-text--bold fr-my-3v">
{{ t(`There is no harvesters yet`) }}
{{ t(`You haven't published a harvester yet`) }}
</p>
<AdminPublishButton type="harvester" />
</div>
<Pagination
v-if="status === 'success' && pageData.total > pageSize"
Expand Down
3 changes: 3 additions & 0 deletions lang/en-US.json
Original file line number Diff line number Diff line change
Expand Up @@ -755,6 +755,9 @@
"{n} users": "{n} users | {n} user | {n} users",
"Transfer to {recipient} already requested the {date}": "Transfer to {recipient} already requested the {date}",
"by {user}": "by {user}",
"Users": "Users",
"You haven't published a harvester yet": "You haven't published a harvester yet",
"Create an harvester on": "Create an harvester on",
"Profile picture": "Profile picture",
"": ""
}
3 changes: 3 additions & 0 deletions lang/es-ES.json
Original file line number Diff line number Diff line change
Expand Up @@ -748,6 +748,9 @@
"The dataset will only be visible to members of your organization.": "The dataset will only be visible to members of your organization.",
"The dataservice will only be visible to members of your organization.": "The dataservice will only be visible to members of your organization.",
"The reuse will only be visible to members of your organization.": "The reuse will only be visible to members of your organization.",
"Users": "Users",
"You haven't published a harvester yet": "You haven't published a harvester yet",
"Create an harvester on": "Create an harvester on",
"Profile picture": "Profile picture",
"": ""
}
3 changes: 3 additions & 0 deletions lang/fr-FR.json
Original file line number Diff line number Diff line change
Expand Up @@ -777,6 +777,9 @@
"Transfer to {recipient} already requested the {date}": "Transfert vers {recipient} déjà demandé le {date}",
"by {user}": "par {user}",
"Transfer requested. A notification has been sent to the recipient.": "Transfert demandé. Une notification a été envoyé au destinataire.",
"Users": "Utilisateurs",
"You haven't published a harvester yet": "Vous n'avez pas encore publié de moissonneur",
"Create an harvester on": "Créer un moissoneur sur",
"Profile picture": "Image de profil",
"": ""
}
17 changes: 17 additions & 0 deletions public/illustrations/harvester.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 6c93d1a

Please sign in to comment.