From 9e937050c4acf03ddce7c99779e264a58ec7e47b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Enrique=20Jim=C3=A9nez?=
Date: Sun, 14 Jul 2024 14:12:06 +0000
Subject: [PATCH] Add Chicago Links
---
src/fragmentarium/domain/Fragment.test.ts | 1 +
src/fragmentarium/domain/FragmentDtos.ts | 1 +
.../LatestTransliterations.test.tsx.snap | 63 +++++++++--------
.../ui/info/ExternalNumberLink.tsx | 9 +++
.../ui/info/ExternalResources.test.tsx | 4 ++
.../ui/info/ExternalResources.tsx | 2 +
.../ExternalResources.test.tsx.snap | 12 ++++
.../FragmentariumSearch.test.tsx.snap | 69 +++++++++----------
src/test-support/fragment-data-fixtures.tsx | 1 +
src/test-support/test-fragment.ts | 1 +
10 files changed, 97 insertions(+), 66 deletions(-)
diff --git a/src/fragmentarium/domain/Fragment.test.ts b/src/fragmentarium/domain/Fragment.test.ts
index 75836d057..2ed98b720 100644
--- a/src/fragmentarium/domain/Fragment.test.ts
+++ b/src/fragmentarium/domain/Fragment.test.ts
@@ -121,6 +121,7 @@ const config: Parameters[0] = {
bmIdNumber: 'W_1848-0720-117',
archibabNumber: '42',
bdtnsNumber: '99',
+ chicagoIsacNumber: 'd0be123f-2411-4dcd-b930-74d2eb9f19a4',
urOnlineNumber: '123',
hilprechtJenaNumber: '123',
hilprechtHeidelbergNumber: '123',
diff --git a/src/fragmentarium/domain/FragmentDtos.ts b/src/fragmentarium/domain/FragmentDtos.ts
index 453a6547b..5d7fade5b 100644
--- a/src/fragmentarium/domain/FragmentDtos.ts
+++ b/src/fragmentarium/domain/FragmentDtos.ts
@@ -66,6 +66,7 @@ export const ExternalNumberTypes = [
'bmIdNumber',
'archibabNumber',
'bdtnsNumber',
+ 'chicagoIsacNumber',
'urOnlineNumber',
'hilprechtJenaNumber',
'hilprechtHeidelbergNumber',
diff --git a/src/fragmentarium/ui/front-page/__snapshots__/LatestTransliterations.test.tsx.snap b/src/fragmentarium/ui/front-page/__snapshots__/LatestTransliterations.test.tsx.snap
index e506b0d32..c5cc6a1db 100644
--- a/src/fragmentarium/ui/front-page/__snapshots__/LatestTransliterations.test.tsx.snap
+++ b/src/fragmentarium/ui/front-page/__snapshots__/LatestTransliterations.test.tsx.snap
@@ -37,11 +37,11 @@ exports[`Snapshot 1`] = `
Excavation no.:
- ucotes.1
+ ed.1
Provenance:
- Eridu
+ Dugirdkhan
@@ -5851,11 +5851,11 @@ exports[`Snapshot 1`] = `
class="fragment-result__fragment-number"
>
- ke.2
+ etkoclo.2
- (Ur3)
+ (JN)
Accession no.:
- wugutkoc.2
+ baj.2
Excavation no.:
- jozi.2
+ jil.2
Provenance:
- Qatara
+ Tall Imlīḥiyah
@@ -5883,11 +5883,6 @@ exports[`Snapshot 1`] = `
class="text-secondary fragment-result__genre col-sm-4 col-12"
>
-
-
- ARCHIVE ➝ Administrative ➝ Lists
-
-
Other ➝ Fake ➝ Certain
@@ -5904,17 +5899,7 @@ exports[`Snapshot 1`] = `
-
- Romolini
- (
- Transliteration
- ,
-
-
- )
+ No record
@@ -5959,9 +5944,9 @@ exports[`Snapshot 1`] = `
- Garrido & Tinti, 2055: 5928983864541184-7552106621829120
+ Checcucci & Tomlinson, 2026: 4727451873705984-8024100712742912
[
- l. 4'.2., 1.
+ l. 3'., 1.
]
- Dong & Ducci, 2026: 3794580308754432-4010327748378624
+ Chirici & Borchi, 2066: 1964069523292160-4777479967342592
[
- l. 3'., 4'.2.
+ l. 4'.2., 2.
]
+ >
+
+
+ Something's gone wrong.
+
+
+ Our team has been notified, but you can fill out a report by clicking the button below.
+
+
+
+
+
+
diff --git a/src/fragmentarium/ui/info/ExternalNumberLink.tsx b/src/fragmentarium/ui/info/ExternalNumberLink.tsx
index 91de36ed3..98f20495e 100644
--- a/src/fragmentarium/ui/info/ExternalNumberLink.tsx
+++ b/src/fragmentarium/ui/info/ExternalNumberLink.tsx
@@ -46,6 +46,15 @@ export function BdtnsLink({ number }: { number: string }): JSX.Element {
/>
)
}
+export function ChicagoIsacLink({ number }: { number: string }): JSX.Element {
+ return (
+
+ )
+}
export function ArchibabLink({ number }: { number: string }): JSX.Element {
return (
{
cdliNumber,
bmIdNumber,
bdtnsNumber,
+ chicagoIsacNumber,
archibabNumber,
urOnlineNumber,
hilprechtJenaNumber,
@@ -61,6 +63,7 @@ describe('external resources', () => {
bmIdNumber,
],
['BDTNS', 'http://bdtns.filol.csic.es/', bdtnsNumber],
+ ['Chicago ISAC', 'https://isac-idb.uchicago.edu/id/', chicagoIsacNumber],
['Archibab', 'http://www.archibab.fr/', archibabNumber],
['Ur Online', 'http://www.ur-online.org/subject/', urOnlineNumber],
[
@@ -135,6 +138,7 @@ describe('missing external resources', () => {
'CDLI',
'The British Museum',
'BDTNS',
+ 'Chicago ISAC',
'Archibab',
'Ur Online',
'Hilprecht Collection',
diff --git a/src/fragmentarium/ui/info/ExternalResources.tsx b/src/fragmentarium/ui/info/ExternalResources.tsx
index 9c8befe0d..c7330628c 100644
--- a/src/fragmentarium/ui/info/ExternalResources.tsx
+++ b/src/fragmentarium/ui/info/ExternalResources.tsx
@@ -4,6 +4,7 @@ import './ExternalResources.sass'
import {
BdtnsLink,
CdliLink,
+ ChicagoIsacLink,
ArchibabLink,
UrOnlineLink,
HilprechtJenaLink,
@@ -41,6 +42,7 @@ export default function ExternalResources({
[fragment.getExternalNumber('bmIdNumber'), BmIdLink],
[fragment.getExternalNumber('cdliNumber'), CdliLink],
[fragment.getExternalNumber('bdtnsNumber'), BdtnsLink],
+ [fragment.getExternalNumber('chicagoIsacNumber'), ChicagoIsacLink],
[fragment.getExternalNumber('archibabNumber'), ArchibabLink],
[fragment.getExternalNumber('urOnlineNumber'), UrOnlineLink],
[fragment.getExternalNumber('hilprechtJenaNumber'), HilprechtJenaLink],
diff --git a/src/fragmentarium/ui/info/__snapshots__/ExternalResources.test.tsx.snap b/src/fragmentarium/ui/info/__snapshots__/ExternalResources.test.tsx.snap
index dca76c7ab..edc941415 100644
--- a/src/fragmentarium/ui/info/__snapshots__/ExternalResources.test.tsx.snap
+++ b/src/fragmentarium/ui/info/__snapshots__/ExternalResources.test.tsx.snap
@@ -41,6 +41,18 @@ exports[`external resources Snapshot 1`] = `
)
+ -
+ Chicago ISAC (
+
+ d0be123f-2411-4dcd-b930-74d2eb9f19a4
+
+ )
+
-
Archibab (
- uc.9
+ hohoru.9
- (Hit)
+ (Par)
Accession no.:
- titeba.9
+ id.9
Excavation no.:
- jora.9
+ ovhun.9
Provenance:
- Sippar
+ Nippur
@@ -853,11 +853,6 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
class="text-secondary fragment-result__genre col-sm-4 col-12"
>
-
-
- ARCHIVE ➝ Administrative ➝ Lists
-
-
Other ➝ Fake ➝ Certain
@@ -909,14 +904,14 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
- Giles & Alvarez, 2087: 5582194326110208-1406653725409280
+ Duran & Boon, 2075: 1233275364311040-5892501091123200
[
- l. 1., 3'.
+ l. 4'.2., 1.
]
- (C)
+ (E)
@@ -928,14 +923,14 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
- Shaw & Robert, 2046: 6150545542742016-5917511180615680
+ Hansen & van Ommen, 2050: 522493473325056-5682457787498496
[
- l. 2., 1.
+ l. 4'.2., 1.
]
- (P)
+ (D)
@@ -6618,7 +6613,18 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
+ >
+
+
+
+
@@ -6635,9 +6641,9 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
class="fragment-result__fragment-number"
>
- mi.10
+ lezajo.10
(Uruk4)
@@ -6647,7 +6653,7 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
Accession no.:
- kuvina.10
+ siti.10
Excavation no.:
@@ -6718,14 +6724,14 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
- Sanna & Vivoli, 2086: 6039983651553280-8222076427042816
+ Biliotti & van Rijn, 2036: 1960181967618048-447775313494016
[
l. 4'.2., 2.
]
- (C)
+ (P)
@@ -6733,14 +6739,14 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
- Waters & Faure, 2073: 3028366718402560-7932536841830400
+ Duval & Burrows, 2077: 6062190752694272-6966757507989504
[
l. 3'., 4'.2.
]
- (C)
+ (P)
@@ -12423,18 +12429,7 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
+ />
diff --git a/src/test-support/fragment-data-fixtures.tsx b/src/test-support/fragment-data-fixtures.tsx
index 3d916db80..08ccb9909 100644
--- a/src/test-support/fragment-data-fixtures.tsx
+++ b/src/test-support/fragment-data-fixtures.tsx
@@ -156,6 +156,7 @@ export const externalNumbersFactory = Factory.define(
return {
cdliNumber: associations.cdliNumber ?? chance.string(),
bmIdNumber: associations.bmIdNumber ?? chance.string(),
+ chicagoIsacNumber: associations.chicagoIsacNumber ?? chance.string(),
archibabNumber: associations.archibabNumber ?? chance.string(),
bdtnsNumber: associations.bdtnsNumber ?? chance.string(),
urOnlineNumber: associations.urOnlineNumber ?? chance.string(),
diff --git a/src/test-support/test-fragment.ts b/src/test-support/test-fragment.ts
index 78cd57bf6..8a7a61db6 100644
--- a/src/test-support/test-fragment.ts
+++ b/src/test-support/test-fragment.ts
@@ -16,6 +16,7 @@ const externalNumbers = {
bmIdNumber: 'W_1848-0720-117',
archibabNumber: '42',
bdtnsNumber: '99',
+ chicagoIsacNumber: 'd0be123f-2411-4dcd-b930-74d2eb9f19a4',
urOnlineNumber: '123',
hilprechtJenaNumber: '1235',
hilprechtHeidelbergNumber: '11',