diff --git a/frontend/src/lib/components/AdventureModal.svelte b/frontend/src/lib/components/AdventureModal.svelte
index add0ef4..016e0f1 100644
--- a/frontend/src/lib/components/AdventureModal.svelte
+++ b/frontend/src/lib/components/AdventureModal.svelte
@@ -463,6 +463,13 @@
event.preventDefault();
triggerMarkVisted = true;
+ // if category icon is empty, set it to the default icon
+ if (adventure.category?.icon == '' || adventure.category?.icon == null) {
+ if (adventure.category) {
+ adventure.category.icon = '🌍';
+ }
+ }
+
if (adventure.id === '') {
if (adventure.category?.display_name == '') {
if (categories.some((category) => category.name === 'general')) {
@@ -479,6 +486,7 @@
};
}
}
+
let res = await fetch('/api/adventures', {
method: 'POST',
headers: {
@@ -708,8 +716,10 @@
{$t('adventures.warning')}: {warningMessage}
{/if}
-
-
+
+
+
+
diff --git a/frontend/src/lib/components/DateRangeCollapse.svelte b/frontend/src/lib/components/DateRangeCollapse.svelte
index 5a4198a..33d0066 100644
--- a/frontend/src/lib/components/DateRangeCollapse.svelte
+++ b/frontend/src/lib/components/DateRangeCollapse.svelte
@@ -258,119 +258,6 @@
>
{/if}
-
-
-
- {#if !validateDateRange(localStartDate, localEndDate).valid}
-
-
-
{$t('adventures.invalid_date_range')}
-
- {/if}
-
- {#if visits && visits.length > 0}
-
- {#each visits as visit}
-
-
- {#if isAllDay(visit.start_date)}
- {$t('adventures.all_day')}
- {visit.start_date.split('T')[0]} – {visit.end_date.split('T')[0]}
- {:else}
- {new Date(visit.start_date).toLocaleString()} – {new Date(
- visit.end_date
- ).toLocaleString()}
- {/if}
-
-
-
-
- {#if visit.notes}
-
- "{visit.notes}"
-
- {/if}
-
-
-
-
-
-
-
- {/each}
-
- {/if}
-
-
{#if type === 'adventure'}
+
+
+ {#if !validateDateRange(localStartDate, localEndDate).valid}
+
+
+
{$t('adventures.invalid_date_range')}
+
+ {/if}
+
+ {#if type === 'adventure'}
+
+
+ {$t('adventures.visits')}
+
+
+
+ {#if visits && visits.length === 0}
+
+ {$t('adventures.no_visits')}
+
+ {/if}
+
+
+ {#if visits && visits.length > 0}
+
+ {#each visits as visit}
+
+
+ {#if isAllDay(visit.start_date)}
+ {$t('adventures.all_day')}
+ {visit.start_date.split('T')[0]} – {visit.end_date.split('T')[0]}
+ {:else}
+ {new Date(visit.start_date).toLocaleString()} – {new Date(
+ visit.end_date
+ ).toLocaleString()}
+ {/if}
+
+
+
+
+ {#if visit.notes}
+
+ "{visit.notes}"
+
+ {/if}
+
+
+
+
+
+
+ {/each}
+
+ {/if}
+ {/if}
diff --git a/frontend/src/locales/de.json b/frontend/src/locales/de.json
index 18488ae..9808cd1 100644
--- a/frontend/src/locales/de.json
+++ b/frontend/src/locales/de.json
@@ -256,7 +256,8 @@
"additional_info": "Weitere Informationen",
"invalid_date_range": "Ungültiger Datumsbereich",
"sunrise_sunset": "Sonnenaufgang",
- "timezone": "Zeitzone"
+ "timezone": "Zeitzone",
+ "no_visits": "Keine Besuche"
},
"home": {
"desc_1": "Entdecken, planen und erkunden Sie mühelos",
diff --git a/frontend/src/locales/en.json b/frontend/src/locales/en.json
index 9ab91c0..2a837de 100644
--- a/frontend/src/locales/en.json
+++ b/frontend/src/locales/en.json
@@ -64,6 +64,7 @@
"collection_link_success": "Adventure linked to collection successfully!",
"invalid_date_range": "Invalid date range",
"timezone": "Timezone",
+ "no_visits": "No visits",
"no_image_found": "No image found",
"collection_link_error": "Error linking adventure to collection",
"adventure_delete_confirm": "Are you sure you want to delete this adventure? This action cannot be undone.",
diff --git a/frontend/src/locales/es.json b/frontend/src/locales/es.json
index 6070d2d..14f8ec3 100644
--- a/frontend/src/locales/es.json
+++ b/frontend/src/locales/es.json
@@ -304,7 +304,8 @@
"additional_info": "información adicional",
"invalid_date_range": "Rango de fechas no válido",
"sunrise_sunset": "Amanecer",
- "timezone": "Zona horaria"
+ "timezone": "Zona horaria",
+ "no_visits": "No hay visitas"
},
"worldtravel": {
"all": "Todo",
diff --git a/frontend/src/locales/fr.json b/frontend/src/locales/fr.json
index 2f9b4ad..206bcf0 100644
--- a/frontend/src/locales/fr.json
+++ b/frontend/src/locales/fr.json
@@ -256,7 +256,8 @@
"additional_info": "Informations Complémentaires",
"invalid_date_range": "Plage de dates non valide",
"sunrise_sunset": "Lever du soleil",
- "timezone": "Fuseau horaire"
+ "timezone": "Fuseau horaire",
+ "no_visits": "Pas de visites"
},
"home": {
"desc_1": "Découvrez, planifiez et explorez en toute simplicité",
diff --git a/frontend/src/locales/it.json b/frontend/src/locales/it.json
index ecaef2d..e34c06a 100644
--- a/frontend/src/locales/it.json
+++ b/frontend/src/locales/it.json
@@ -256,7 +256,8 @@
"additional_info": "Ulteriori informazioni",
"invalid_date_range": "Intervallo di date non valido",
"sunrise_sunset": "Alba",
- "timezone": "Fuso orario"
+ "timezone": "Fuso orario",
+ "no_visits": "Nessuna visita"
},
"home": {
"desc_1": "Scopri, pianifica ed esplora con facilità",
diff --git a/frontend/src/locales/ko.json b/frontend/src/locales/ko.json
index fd47b52..8925ef2 100644
--- a/frontend/src/locales/ko.json
+++ b/frontend/src/locales/ko.json
@@ -256,7 +256,8 @@
"additional_info": "추가 정보",
"invalid_date_range": "잘못된 날짜 범위",
"sunrise_sunset": "해돋이",
- "timezone": "시간대"
+ "timezone": "시간대",
+ "no_visits": "방문 없음"
},
"auth": {
"both_passwords_required": "두 암호 모두 필요합니다",
diff --git a/frontend/src/locales/nl.json b/frontend/src/locales/nl.json
index 08f013d..8226e11 100644
--- a/frontend/src/locales/nl.json
+++ b/frontend/src/locales/nl.json
@@ -256,7 +256,8 @@
"additional_info": "Aanvullende informatie",
"invalid_date_range": "Ongeldige datumbereik",
"sunrise_sunset": "Zonsopgang",
- "timezone": "Tijdzone"
+ "timezone": "Tijdzone",
+ "no_visits": "Geen bezoeken"
},
"home": {
"desc_1": "Ontdek, plan en verken met gemak",
diff --git a/frontend/src/locales/no.json b/frontend/src/locales/no.json
index 9aeb95e..f43f284 100644
--- a/frontend/src/locales/no.json
+++ b/frontend/src/locales/no.json
@@ -304,7 +304,8 @@
"no_ordered_items": "Legg til varer med datoer i samlingen for å se dem her.",
"ordered_itinerary": "Bestilt reiserute",
"sunrise_sunset": "Soloppgang",
- "timezone": "Tidssone"
+ "timezone": "Tidssone",
+ "no_visits": "Ingen besøk"
},
"worldtravel": {
"country_list": "Liste over land",
diff --git a/frontend/src/locales/pl.json b/frontend/src/locales/pl.json
index 512fcac..bb0554b 100644
--- a/frontend/src/locales/pl.json
+++ b/frontend/src/locales/pl.json
@@ -304,7 +304,8 @@
"additional_info": "Dodatkowe informacje",
"invalid_date_range": "Niepoprawny zakres dat",
"sunrise_sunset": "Wschód słońca",
- "timezone": "Strefa czasowa"
+ "timezone": "Strefa czasowa",
+ "no_visits": "Brak wizyt"
},
"worldtravel": {
"country_list": "Lista krajów",
diff --git a/frontend/src/locales/sv.json b/frontend/src/locales/sv.json
index b4e596d..a9aefb9 100644
--- a/frontend/src/locales/sv.json
+++ b/frontend/src/locales/sv.json
@@ -256,7 +256,8 @@
"additional_info": "Ytterligare information",
"invalid_date_range": "Ogiltigt datumintervall",
"sunrise_sunset": "Soluppgång",
- "timezone": "Tidszon"
+ "timezone": "Tidszon",
+ "no_visits": "Inga besök"
},
"home": {
"desc_1": "Upptäck, planera och utforska med lätthet",
diff --git a/frontend/src/locales/zh.json b/frontend/src/locales/zh.json
index b8ea77c..98993fa 100644
--- a/frontend/src/locales/zh.json
+++ b/frontend/src/locales/zh.json
@@ -304,7 +304,8 @@
"additional_info": "附加信息",
"invalid_date_range": "无效的日期范围",
"sunrise_sunset": "日出",
- "timezone": "时区"
+ "timezone": "时区",
+ "no_visits": "没有访问"
},
"auth": {
"forgot_password": "忘记密码?",