Skip to content

Commit

Permalink
Add Australian Institute of Archaeology to Links
Browse files Browse the repository at this point in the history
  • Loading branch information
ejimsan committed Jan 19, 2024
1 parent aedce3f commit 1e803d3
Show file tree
Hide file tree
Showing 10 changed files with 97 additions and 54 deletions.
1 change: 1 addition & 0 deletions src/fragmentarium/domain/Fragment.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ const config: Parameters<typeof Fragment['create']>[0] = {
nabuccoNumber: '123',
metropolitanNumber: '123',
louvreNumber: '123',
australianinstituteofarchaeologyNumber: '123',
philadelphiaNumber: '123',
},
projects: [],
Expand Down
1 change: 1 addition & 0 deletions src/fragmentarium/domain/FragmentDtos.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ export const ExternalNumberTypes = [
'nabuccoNumber',
'metropolitanNumber',
'louvreNumber',
'australianinstituteofarchaeologyNumber',
'philadelphiaNumber',
'yalePeabodyNumber',
] as const
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ exports[`Snapshot 1`] = `
</p>
<p>
Excavation no.:
radjo.1
noj.1
</p>
</small>
</div>
Expand Down Expand Up @@ -5834,22 +5834,22 @@ exports[`Snapshot 1`] = `
class="fragment-result__fragment-number"
>
<a
href="/fragmentarium/rikeluco.2"
href="/fragmentarium/cowjofke.2"
>
rikeluco.2
cowjofke.2
</a>
(Ur3)
(JN)
</h4>
<small>
<p
class="fragment-result__accession"
>
Accession no.:
jofkeku.2
ed.2
</p>
<p>
Excavation no.:
wu.2
pov.2
</p>
</small>
</div>
Expand Down Expand Up @@ -5906,14 +5906,14 @@ exports[`Snapshot 1`] = `
<span
class="reference-popover__citation"
>
White & Manca, 2071: 6525764484726784-1000123435843584
Checcucci & Tomlinson, 2026: 4727451873705984-8024100712742912
[
l. 3'., 2.
l. 3'., 1.
]
<span
class="type-abbreviation"
>
(T)
(C)
</span>
</span>
</li>
Expand All @@ -5925,14 +5925,14 @@ exports[`Snapshot 1`] = `
<span
class="reference-popover__citation"
>
Martinez & Robin, 2113: 5946678584541184-5595938733162496
Chirici & Borchi, 2109: 7541452181602304-6009873588289536
[
l. 3'., 4'.2.
]
<span
class="type-abbreviation"
>
(D)
(E)
</span>
</span>
</li>
Expand Down
13 changes: 13 additions & 0 deletions src/fragmentarium/ui/info/ExternalNumberLink.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,19 @@ export function LouvreLink({ number }: { number: string }): JSX.Element {
/>
)
}
export function australianinstituteofarchaeologyLink({
number,
}: {
number: string
}): JSX.Element {
return (
<ExternalNumberLink
number={number}
baseUrl={'https://aiarch.pedestal3d.com/r/'}
label={'Australian Institute of Archaeology'}
/>
)
}
export function PhiladelphiaLink({ number }: { number: string }): JSX.Element {
return (
<ExternalNumberLink
Expand Down
8 changes: 8 additions & 0 deletions src/fragmentarium/ui/info/ExternalResources.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ const achemenetNumber = 'H00744'
const nabuccoNumber = 'H00765'
const metropolitanNumber = 'M123'
const louvreNumber = 'L123'
const australianinstituteofarchaeologyNumber = 'L123'
const philadelphiaNumber = 'P123'
const yalePeabodyNumber = 'y123'
let fragment: Fragment
Expand All @@ -42,6 +43,7 @@ describe('external resources', () => {
nabuccoNumber,
metropolitanNumber,
louvreNumber,
australianinstituteofarchaeologyNumber,
philadelphiaNumber,
yalePeabodyNumber,
}),
Expand Down Expand Up @@ -87,6 +89,11 @@ describe('external resources', () => {
metropolitanNumber,
],
['Louvre', 'https://collections.louvre.fr/ark:/53355/', louvreNumber],
[
'Australian Institute of Archaeology',
'https://aiarch.pedestal3d.com/r/',
australianinstituteofarchaeologyNumber,
],
[
'Penn Museum',
'https://www.penn.museum/collections/object/',
Expand Down Expand Up @@ -131,6 +138,7 @@ describe('missing external resources', () => {
'NaBuCCo',
'The Metropolitan Museum of Art',
'Louvre',
'Australian Institute of Archaeology',
'Penn Museum',
'Yale Babylonian Collection',
])('Mising %s number is not shown', async (label) => {
Expand Down
5 changes: 5 additions & 0 deletions src/fragmentarium/ui/info/ExternalResources.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import {
NabuccoLink,
MetropolitanLink,
LouvreLink,
australianinstituteofarchaeologyLink,
PhiladelphiaLink,
BmIdLink,
YalePeabodyLink,
Expand Down Expand Up @@ -49,6 +50,10 @@ export default function ExternalResources({
[fragment.getExternalNumber('nabuccoNumber'), NabuccoLink],
[fragment.getExternalNumber('metropolitanNumber'), MetropolitanLink],
[fragment.getExternalNumber('louvreNumber'), LouvreLink],
[
fragment.getExternalNumber('australianinstituteofarchaeologyNumber'),
australianinstituteofarchaeologyLink,
],
[fragment.getExternalNumber('philadelphiaNumber'), PhiladelphiaLink],
[fragment.getExternalNumber('yalePeabodyNumber'), YalePeabodyLink],
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,18 @@ exports[`external resources Snapshot 1`] = `
</a>
)
</li>
<li>
Australian Institute of Archaeology (
<a
aria-label="Australian Institute of Archaeology text L123"
href="https://aiarch.pedestal3d.com/r/L123"
rel="noopener noreferrer"
target="_blank"
>
L123
</a>
)
</li>
<li>
Penn Museum (
<a
Expand Down
Loading

0 comments on commit 1e803d3

Please sign in to comment.