From e557f108e73eedb95665aba834ec5ed05b628971 Mon Sep 17 00:00:00 2001 From: Robin Kaggl <48437174+kaggl@users.noreply.github.com> Date: Mon, 24 Jun 2024 14:45:18 +0200 Subject: [PATCH] Last june issues before i take my leave (#139) resolves #136 resolves #137 resolves #138 --------- Co-authored-by: Robin Kaggl --- .npmrc | 1 + components/tooltip.vue | 27 ----------- lib/helpers.ts | 2 +- locales/de.json | 5 +- locales/en.json | 5 +- package.json | 2 +- pages/detail/courts/[id].vue | 16 ++++-- pages/detail/institutions/[id].vue | 22 ++++++--- pages/detail/persons/[id].vue | 78 ++++++++++++++++++------------ pages/detail/places/[id].vue | 15 ++++-- pnpm-lock.yaml | 8 +-- 11 files changed, 100 insertions(+), 81 deletions(-) delete mode 100644 components/tooltip.vue diff --git a/.npmrc b/.npmrc index 87529f8..c044a35 100644 --- a/.npmrc +++ b/.npmrc @@ -4,3 +4,4 @@ engine-strict=true shamefully-hoist=true shell-emulator=true use-node-version=20.10.0 +package-manager-strict=false diff --git a/components/tooltip.vue b/components/tooltip.vue deleted file mode 100644 index db9c420..0000000 --- a/components/tooltip.vue +++ /dev/null @@ -1,27 +0,0 @@ - - - diff --git a/lib/helpers.ts b/lib/helpers.ts index ab84d57..9c0e9f7 100644 --- a/lib/helpers.ts +++ b/lib/helpers.ts @@ -13,6 +13,6 @@ export function detectURLsAddLinks(content: string) { /(https?:\/\/(?:www\.|(?!www))[a-zA-Z0-9][a-zA-Z0-9-]+[a-zA-Z0-9]\.[^\s]{2,}|www\.[a-zA-Z0-9][a-zA-Z0-9-]+[a-zA-Z0-9]\.[^\s]{2,}|https?:\/\/(?:www\.|(?!www))[a-zA-Z0-9]+\.[^\s]{2,}|www\.[a-zA-Z0-9]+\.[^\s]{2,})/; return content.replace( urlRegex, - '$1', + '$1↗', ); } diff --git a/locales/de.json b/locales/de.json index 36082de..f845cba 100644 --- a/locales/de.json +++ b/locales/de.json @@ -164,7 +164,10 @@ "allowance": "Zahlungen", "same_as": "Onlineressourcen", "confession": "Konfession", - "no-notes": "Keine Notizen vorhanden." + "no-notes": "Keine Notizen vorhanden.", + "notes": "Redaktioneller Hinweis", + "hierarchy": "Hierarchievisualisierung", + "citations": "Zitationsvorschlag" }, "viecpro_courts": { "model": "Modell", diff --git a/locales/en.json b/locales/en.json index 2204da5..2a16abc 100644 --- a/locales/en.json +++ b/locales/en.json @@ -163,7 +163,10 @@ "allowance": "Allowance", "same_as": "Online resources", "confession": "Confession", - "no-notes": "No notes provided." + "no-notes": "No notes provided.", + "notes": "Editor's note", + "hierarchy": "Hierarchy visualisation", + "citations": "Proposal for citation " }, "viecpro_courts": { "model": "Model", diff --git a/package.json b/package.json index e1f5cae..bc7319b 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "node": "20.x", "pnpm": "8.x" }, - "packageManager": "pnpm@8.10.5", + "packageManager": "pnpm@8.15.8", "scripts": { "build": "nuxt build", "dev": "nuxt dev", diff --git a/pages/detail/courts/[id].vue b/pages/detail/courts/[id].vue index 3f6e103..98b79af 100644 --- a/pages/detail/courts/[id].vue +++ b/pages/detail/courts/[id].vue @@ -42,7 +42,7 @@ definePageMeta({ }); const title = computed(() => { - if (data.value.entity.data?.name) + if (data.value.entity.data.name) return `${data.value.entity.data.name} - ${t("pages.searchviews.courts.sing")}`; return t("pages.searchviews.courts.sing"); }); @@ -74,15 +74,23 @@ useHead({ {{ data.entity.data?.name }}
- + - +
{{ t("ui.loading") }} diff --git a/pages/detail/institutions/[id].vue b/pages/detail/institutions/[id].vue index 00f9700..6139956 100644 --- a/pages/detail/institutions/[id].vue +++ b/pages/detail/institutions/[id].vue @@ -34,9 +34,11 @@ const data = ref({ const fetchCourts = computed(() => { if ( - data.value.details.error?.httpStatus && + data.value.details.error && + data.value.entity.error && + data.value.details.error.httpStatus && data.value.details.error.httpStatus === 404 && - data.value.entity.error?.httpStatus && + data.value.entity.error.httpStatus && data.value.entity.error.httpStatus === 404 ) return true; @@ -79,7 +81,7 @@ definePageMeta({ }); const title = computed(() => { - if (data.value.entity.data?.name) return `${data.value.entity.data.name} - Institution`; + if (data.value.entity.data.name) return `${data.value.entity.data.name} - Institution`; return "Institution"; }); @@ -113,15 +115,23 @@ useHead({ {{ data.entity.data?.name }}
- + - +
{{ t("ui.loading") }} diff --git a/pages/detail/persons/[id].vue b/pages/detail/persons/[id].vue index dd8bedd..1740a65 100644 --- a/pages/detail/persons/[id].vue +++ b/pages/detail/persons/[id].vue @@ -99,15 +99,42 @@ useHead({ {{ data.entity.data?.fullname }}
- + + + + + - - - - - +
{{ t("ui.loading") }} @@ -283,11 +294,21 @@ useHead({ >
-

+

{{ tag }}

diff --git a/pages/detail/places/[id].vue b/pages/detail/places/[id].vue index 1b7b864..46ed439 100644 --- a/pages/detail/places/[id].vue +++ b/pages/detail/places/[id].vue @@ -66,7 +66,7 @@ definePageMeta({ }); const title = computed(() => { - if (data.value.entity.data?.name) + if (data.value.entity.data.name) return `${data.value.entity.data.name} - ${t("pages.searchviews.places.sing")}`; return t("pages.searchviews.places.sing"); }); @@ -98,10 +98,17 @@ useHead({ {{ data.entity.data?.name }}
- + - +
{{ t("ui.loading") }} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index e86dbef..002434a 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1869,7 +1869,7 @@ packages: resolution: {integrity: sha512-7kZUAaLscfgbwBQRbvdMYaZOWyMEcPTH/tJjnyAWJ/dvvs9Ef+CERx/qJb9GExJpl1qipaDGn7KqHnFGGixd0w==} engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} dependencies: - semver: 7.5.4 + semver: 7.6.2 dev: false /@npmcli/git@5.0.3: @@ -4472,7 +4472,7 @@ packages: /builtins@5.0.1: resolution: {integrity: sha512-qwVpFEHNfhYJIzNRBvd2C1kyo6jz3ZSMPyyuR47OPdiKWlbYnZNyDWuyR175qDnAJLiCo5fBBqPb3RiXgWlkOQ==} dependencies: - semver: 7.5.4 + semver: 7.6.2 dev: false /bundle-name@3.0.0: @@ -8723,7 +8723,7 @@ packages: make-fetch-happen: 13.0.0 nopt: 7.2.0 proc-log: 3.0.0 - semver: 7.5.4 + semver: 7.6.2 tar: 6.2.0 which: 4.0.0 transitivePeerDependencies: @@ -8793,7 +8793,7 @@ packages: resolution: {integrity: sha512-W29RiK/xtpCGqn6f3ixfRYGk+zRyr+Ew9F2E20BfXxT5/euLdA/Nm7fO7OeTGuAmTs30cpgInyJ0cYe708YTZw==} engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} dependencies: - semver: 7.5.4 + semver: 7.6.2 dev: false /npm-normalize-package-bin@3.0.1: