From 4612dc00cc6ded3f43149f73d8eadfaee39dc197 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Wed, 3 Jan 2024 14:02:06 +0000
Subject: [PATCH 01/24] Add findMany method
---
src/bibliography/application/BibliographyService.ts | 4 ++++
.../infrastructure/BibliographyRepository.test.ts | 9 +++++++++
.../infrastructure/BibliographyRepository.ts | 7 +++++++
.../ui/__snapshots__/ManuscriptPopover.test.tsx.snap | 2 +-
.../LatestTransliterations.test.tsx.snap | 12 ++++++------
.../__snapshots__/FragmentariumSearch.test.tsx.snap | 8 ++++----
.../ui/__snapshots__/markup.test.tsx.snap | 2 +-
7 files changed, 32 insertions(+), 12 deletions(-)
diff --git a/src/bibliography/application/BibliographyService.ts b/src/bibliography/application/BibliographyService.ts
index ab4fb5438..176f5e171 100644
--- a/src/bibliography/application/BibliographyService.ts
+++ b/src/bibliography/application/BibliographyService.ts
@@ -21,6 +21,10 @@ export default class BibliographyService implements BibliographySearch {
return this.bibliographyRepository.find(id)
}
+ findMany(ids: readonly string[]): Promise {
+ return this.bibliographyRepository.findMany(ids)
+ }
+
update(entry: BibliographyEntry): Promise {
return this.bibliographyRepository.update(entry)
}
diff --git a/src/bibliography/infrastructure/BibliographyRepository.test.ts b/src/bibliography/infrastructure/BibliographyRepository.test.ts
index 3e937eeb1..6c2c9de24 100644
--- a/src/bibliography/infrastructure/BibliographyRepository.test.ts
+++ b/src/bibliography/infrastructure/BibliographyRepository.test.ts
@@ -3,6 +3,7 @@ import { testDelegation, TestData } from 'test-support/utils'
import BibliographyRepository from './BibliographyRepository'
import BibliographyEntry from 'bibliography/domain/BibliographyEntry'
import ApiClient from 'http/ApiClient'
+import { stringify } from 'query-string'
jest.mock('http/ApiClient')
@@ -25,6 +26,14 @@ const testData: TestData[] = [
[`/bibliography/${encodeURIComponent(id)}`, false],
Promise.resolve(resultStub)
),
+ new TestData(
+ 'findMany',
+ [[id]],
+ apiClient.fetchJson,
+ [entry],
+ [`/bibliography/list?${stringify([id])}`, false],
+ Promise.resolve([resultStub])
+ ),
new TestData(
'search',
[query],
diff --git a/src/bibliography/infrastructure/BibliographyRepository.ts b/src/bibliography/infrastructure/BibliographyRepository.ts
index 39ff474b7..f6bf1e06c 100644
--- a/src/bibliography/infrastructure/BibliographyRepository.ts
+++ b/src/bibliography/infrastructure/BibliographyRepository.ts
@@ -1,6 +1,7 @@
import BibliographyEntry from 'bibliography/domain/BibliographyEntry'
import Promise from 'bluebird'
import ApiClient from 'http/ApiClient'
+import { stringify } from 'query-string'
function createEntry(cslData) {
return new BibliographyEntry(cslData)
@@ -19,6 +20,12 @@ export default class BibliographyRepository {
.then(createEntry)
}
+ findMany(ids: readonly string[]): Promise {
+ return this.apiClient
+ .fetchJson(`/bibliography/list?${stringify(ids)}`, false)
+ .then((result) => result.map(createEntry))
+ }
+
search(query: string): Promise {
return this.apiClient
.fetchJson(`/bibliography?query=${encodeURIComponent(query)}`, false)
diff --git a/src/corpus/ui/__snapshots__/ManuscriptPopover.test.tsx.snap b/src/corpus/ui/__snapshots__/ManuscriptPopover.test.tsx.snap
index 2274020e1..b9e17f48c 100644
--- a/src/corpus/ui/__snapshots__/ManuscriptPopover.test.tsx.snap
+++ b/src/corpus/ui/__snapshots__/ManuscriptPopover.test.tsx.snap
@@ -14,7 +14,7 @@ exports[`Show manuscript line details 1`] = `
- Estrada & Wolfe, 2068: 7477711662481408-4847418310918144
+ Estrada & Wolfe, 2069: 7477711662481408-4847418310918144
[
l. 4'.2., 3'.
]
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 d14edfa3a..cf2f15e6d 100644
--- a/src/fragmentarium/ui/front-page/__snapshots__/LatestTransliterations.test.tsx.snap
+++ b/src/fragmentarium/ui/front-page/__snapshots__/LatestTransliterations.test.tsx.snap
@@ -71,9 +71,9 @@ exports[`Snapshot 1`] = `
,
- 4/10/2096
+ 4/10/2097
)
@@ -108,7 +108,7 @@ exports[`Snapshot 1`] = `
- Fanti & Carr, 2036: 8970824935538688-3796097900216320
+ Fanti & Carr, 2037: 8970824935538688-3796097900216320
[
l. 4'.2., 2.
]
@@ -123,7 +123,7 @@ exports[`Snapshot 1`] = `
- Hall & Reid, 2089: 7020923936833536-4895425479835648
+ Hall & Reid, 2090: 7020923936833536-4895425479835648
[
l. 4'.2., 3'.
]
@@ -5906,7 +5906,7 @@ exports[`Snapshot 1`] = `
- White & Manca, 2070: 6525764484726784-1000123435843584
+ White & Manca, 2071: 6525764484726784-1000123435843584
[
l. 3'., 2.
]
@@ -5925,7 +5925,7 @@ exports[`Snapshot 1`] = `
- Martinez & Robin, 2112: 5946678584541184-5595938733162496
+ Martinez & Robin, 2113: 5946678584541184-5595938733162496
[
l. 3'., 4'.2.
]
diff --git a/src/fragmentarium/ui/search/__snapshots__/FragmentariumSearch.test.tsx.snap b/src/fragmentarium/ui/search/__snapshots__/FragmentariumSearch.test.tsx.snap
index 48d4a8c96..53ed16af9 100644
--- a/src/fragmentarium/ui/search/__snapshots__/FragmentariumSearch.test.tsx.snap
+++ b/src/fragmentarium/ui/search/__snapshots__/FragmentariumSearch.test.tsx.snap
@@ -773,7 +773,7 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
- Giles & Alvarez, 2086: 5582194326110208-1406653725409280
+ Giles & Alvarez, 2087: 5582194326110208-1406653725409280
[
l. 1., 3'.
]
@@ -792,7 +792,7 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
- Shaw & Robert, 2045: 6150545542742016-5917511180615680
+ Shaw & Robert, 2046: 6150545542742016-5917511180615680
[
l. 2., 1.
]
@@ -6565,7 +6565,7 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
- Harrison & Palmieri, 2028: 5188341634957312-4059361584349184
+ Harrison & Palmieri, 2029: 5188341634957312-4059361584349184
[
l. 1., 2.
]
@@ -6584,7 +6584,7 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
- Wise & Hudson, 2039: 1529496131862528-4383736143544320
+ Wise & Hudson, 2040: 1529496131862528-4383736143544320
[
l. 4'.2., 2.
]
diff --git a/src/transliteration/ui/__snapshots__/markup.test.tsx.snap b/src/transliteration/ui/__snapshots__/markup.test.tsx.snap
index b3a8aa722..df48a0dc2 100644
--- a/src/transliteration/ui/__snapshots__/markup.test.tsx.snap
+++ b/src/transliteration/ui/__snapshots__/markup.test.tsx.snap
@@ -40,7 +40,7 @@ exports[`Markup 1`] = `
- Dickinson & Falciani, 2062: 6831522153758720-8434983175716864
+ Dickinson & Falciani, 2063: 6831522153758720-8434983175716864
[
l. 4'.2., 1.
]
From c2e9e4914826a25e7e63d8193c4958149639d8e6 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Wed, 3 Jan 2024 14:20:32 +0000
Subject: [PATCH 02/24] update url format
---
.../infrastructure/BibliographyRepository.test.ts | 8 +++++++-
src/bibliography/infrastructure/BibliographyRepository.ts | 5 ++++-
2 files changed, 11 insertions(+), 2 deletions(-)
diff --git a/src/bibliography/infrastructure/BibliographyRepository.test.ts b/src/bibliography/infrastructure/BibliographyRepository.test.ts
index 6c2c9de24..3659c874b 100644
--- a/src/bibliography/infrastructure/BibliographyRepository.test.ts
+++ b/src/bibliography/infrastructure/BibliographyRepository.test.ts
@@ -31,7 +31,13 @@ const testData: TestData[] = [
[[id]],
apiClient.fetchJson,
[entry],
- [`/bibliography/list?${stringify([id])}`, false],
+ [
+ `/bibliography/list?${stringify(
+ { ids: [id] },
+ { arrayFormat: 'comma' }
+ )}`,
+ false,
+ ],
Promise.resolve([resultStub])
),
new TestData(
diff --git a/src/bibliography/infrastructure/BibliographyRepository.ts b/src/bibliography/infrastructure/BibliographyRepository.ts
index f6bf1e06c..84942da67 100644
--- a/src/bibliography/infrastructure/BibliographyRepository.ts
+++ b/src/bibliography/infrastructure/BibliographyRepository.ts
@@ -22,7 +22,10 @@ export default class BibliographyRepository {
findMany(ids: readonly string[]): Promise {
return this.apiClient
- .fetchJson(`/bibliography/list?${stringify(ids)}`, false)
+ .fetchJson(
+ `/bibliography/list?${stringify({ ids }, { arrayFormat: 'comma' })}`,
+ false
+ )
.then((result) => result.map(createEntry))
}
From 9b5a38a1b85fc1e3a636ba432b4851a8116e0e28 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Thu, 4 Jan 2024 09:59:18 +0000
Subject: [PATCH 03/24] add createReferences method
---
.../application/ReferenceInjector.ts | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
diff --git a/src/transliteration/application/ReferenceInjector.ts b/src/transliteration/application/ReferenceInjector.ts
index 4bb4e8233..ec64b2879 100644
--- a/src/transliteration/application/ReferenceInjector.ts
+++ b/src/transliteration/application/ReferenceInjector.ts
@@ -107,4 +107,23 @@ export default class ReferenceInjector {
)
)
}
+
+ private createReferences(
+ data: readonly ReferenceDto[]
+ ): Promise {
+ return this.bibliographyService
+ .findMany(data.map((item) => item.id))
+ .then((entries) =>
+ entries.map((entry, index) => {
+ const dataItem = data[index]
+ return new Reference(
+ dataItem.type,
+ dataItem.pages,
+ dataItem.notes,
+ dataItem.linesCited,
+ entry
+ )
+ })
+ )
+ }
}
From 6760055bf520a14fbf5546791ef8950a1ac0b30e Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Thu, 4 Jan 2024 10:32:42 +0000
Subject: [PATCH 04/24] add test for findMany
---
src/bibliography/application/BibliographyService.test.ts | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/bibliography/application/BibliographyService.test.ts b/src/bibliography/application/BibliographyService.test.ts
index 0d1f9a988..1808677f3 100644
--- a/src/bibliography/application/BibliographyService.test.ts
+++ b/src/bibliography/application/BibliographyService.test.ts
@@ -6,6 +6,7 @@ jest.mock('bibliography/infrastructure/BibliographyRepository', () => {
return function () {
return {
find: jest.fn(),
+ findMany: jest.fn(),
search: jest.fn(),
update: jest.fn(),
create: jest.fn(),
@@ -20,6 +21,9 @@ const bibliographyService = new BibliographyService(bibliographyRepository)
const testData: TestData[] = [
new TestData('find', ['RN2020'], bibliographyRepository.find, [resultStub]),
+ new TestData('findMany', [['RN2020']], bibliographyRepository.findMany, [
+ [resultStub],
+ ]),
new TestData('update', [resultStub], bibliographyRepository.update, [
resultStub,
]),
From 852f27184b6b846dc657eea51e47d7977355ea00 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Thu, 4 Jan 2024 14:14:09 +0000
Subject: [PATCH 05/24] refactor injectReferencesToMarkup
---
.../application/ReferenceInjector.ts | 65 ++++++++-----------
1 file changed, 27 insertions(+), 38 deletions(-)
diff --git a/src/transliteration/application/ReferenceInjector.ts b/src/transliteration/application/ReferenceInjector.ts
index ec64b2879..6d9a3b678 100644
--- a/src/transliteration/application/ReferenceInjector.ts
+++ b/src/transliteration/application/ReferenceInjector.ts
@@ -3,7 +3,7 @@ import Promise from 'bluebird'
import Reference from 'bibliography/domain/Reference'
import BibliographyService from 'bibliography/application/BibliographyService'
import { NoteLine } from 'transliteration/domain/note-line'
-import { BibliographyPart, MarkupPart } from 'transliteration/domain/markup'
+import { MarkupPart } from 'transliteration/domain/markup'
import { AbstractLine } from 'transliteration/domain/abstract-line'
import { ReferenceDto } from 'bibliography/domain/referenceDto'
import TranslationLine from 'transliteration/domain/translation-line'
@@ -12,6 +12,7 @@ import { isBibliographyPart } from 'transliteration/domain/type-guards'
import { OldLineNumber } from 'transliteration/domain/line-number'
import { OldLineNumberDto } from 'corpus/application/dtos'
import { Introduction, Notes } from 'fragmentarium/domain/fragment'
+import _ from 'lodash'
function isMarkupLine(
line: Draft
@@ -47,24 +48,31 @@ export default class ReferenceInjector {
injectReferencesToMarkup(
parts: readonly MarkupPart[]
): Promise {
- return Promise.all(
- parts.map(
- (part): Promise =>
- isBibliographyPart(part)
- ? this.createReference(part.reference as ReferenceDto)
- .then(
- (reference): BibliographyPart => ({
- ...part,
- reference,
- })
- )
- .catch((error) => {
- console.error(error)
- return part
- })
- : Promise.resolve(part)
- )
- )
+ const ids = parts
+ .filter(isBibliographyPart)
+ .map((part) => part.reference.id)
+
+ return _.isEmpty(ids)
+ ? Promise.resolve(parts as MarkupPart[])
+ : this.bibliographyService.findMany(ids).then((entries) => {
+ const entryMap = _.keyBy(entries, 'id')
+
+ return parts.map((part) => {
+ if (isBibliographyPart(part)) {
+ const dto = part.reference
+ const reference = new Reference(
+ dto.type,
+ dto.pages,
+ dto.notes,
+ dto.linesCited,
+ entryMap[dto.id]
+ )
+ return { ...part, reference }
+ }
+
+ return part
+ })
+ })
}
injectReferencesToIntroduction(
@@ -107,23 +115,4 @@ export default class ReferenceInjector {
)
)
}
-
- private createReferences(
- data: readonly ReferenceDto[]
- ): Promise {
- return this.bibliographyService
- .findMany(data.map((item) => item.id))
- .then((entries) =>
- entries.map((entry, index) => {
- const dataItem = data[index]
- return new Reference(
- dataItem.type,
- dataItem.pages,
- dataItem.notes,
- dataItem.linesCited,
- entry
- )
- })
- )
- }
}
From feec724fe5f14a732900300069ae785f8414c72f Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Thu, 4 Jan 2024 14:15:00 +0000
Subject: [PATCH 06/24] update tests
---
.../application/ReferenceInjector.test.ts | 27 +++++++++++++++----
1 file changed, 22 insertions(+), 5 deletions(-)
diff --git a/src/transliteration/application/ReferenceInjector.test.ts b/src/transliteration/application/ReferenceInjector.test.ts
index 935ca3ce1..1f1a9cb60 100644
--- a/src/transliteration/application/ReferenceInjector.test.ts
+++ b/src/transliteration/application/ReferenceInjector.test.ts
@@ -4,7 +4,7 @@ import { Text } from 'transliteration/domain/text'
import Promise from 'bluebird'
import { bibliographyEntryFactory } from 'test-support/bibliography-fixtures'
import Reference from 'bibliography/domain/Reference'
-import { MarkupPart } from 'transliteration/domain/markup'
+import { MarkupPart, TextPart } from 'transliteration/domain/markup'
import { NoteLine } from 'transliteration/domain/note-line'
import { ReferenceDto } from 'bibliography/domain/referenceDto'
@@ -16,11 +16,15 @@ const MockBibliographyService = BibliographyService as jest.Mock<
const bibliographyServiceMock = new MockBibliographyService()
const referenceInjector = new ReferenceInjector(bibliographyServiceMock)
+const referenceId = 'RN1'
describe('ReferenceInjector', () => {
- const entry = bibliographyEntryFactory.build()
+ const entry = bibliographyEntryFactory.build(
+ {},
+ { associations: { id: referenceId } }
+ )
const referenceDto: ReferenceDto = {
- id: 'RN1',
+ id: referenceId,
type: 'DISCUSSION',
pages: '5',
notes: '',
@@ -30,6 +34,14 @@ describe('ReferenceInjector', () => {
reference: referenceDto,
type: 'BibliographyPart',
}
+ const stringPart: TextPart = {
+ text: 'Lorem ipsum',
+ type: 'StringPart',
+ }
+ const emphasisPart: TextPart = {
+ text: 'Lorem ipsum',
+ type: 'EmphasisPart',
+ }
const reference = new Reference('DISCUSSION', '5', '', [], entry)
const injectedParts = [
{
@@ -44,6 +56,9 @@ describe('ReferenceInjector', () => {
beforeEach(() => {
bibliographyServiceMock.find.mockReturnValueOnce(Promise.resolve(entry))
+ bibliographyServiceMock.findMany.mockReturnValueOnce(
+ Promise.resolve([entry])
+ )
})
it('injects references to text', async () => {
@@ -58,8 +73,10 @@ describe('ReferenceInjector', () => {
it('injects references to MarkupParts', async () => {
return referenceInjector
- .injectReferencesToMarkup([bibliographyPart])
- .then((parts) => expect(parts).toEqual(injectedParts))
+ .injectReferencesToMarkup([emphasisPart, bibliographyPart, stringPart])
+ .then((parts) =>
+ expect(parts).toEqual([emphasisPart, ...injectedParts, stringPart])
+ )
})
it('injects references to OldLineNumbers', async () => {
From 6675ed5a6e078d73d660470178fd3b7cf8910953 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Thu, 4 Jan 2024 14:20:55 +0000
Subject: [PATCH 07/24] update tests
---
src/corpus/application/TextService.test.ts | 45 ++++++++++++++++------
1 file changed, 33 insertions(+), 12 deletions(-)
diff --git a/src/corpus/application/TextService.test.ts b/src/corpus/application/TextService.test.ts
index e9c174ff2..f1c00a78f 100644
--- a/src/corpus/application/TextService.test.ts
+++ b/src/corpus/application/TextService.test.ts
@@ -23,6 +23,7 @@ import { ChapterDisplay } from 'corpus/domain/chapter'
import textLineFixture, { textLineDto } from 'test-support/lines/text-line'
import { chapterDisplayDtoFactory } from 'test-support/chapter-fixtures'
import {
+ bibliographyEntryFactory,
cslDataFactory,
referenceDtoFactory,
referenceFactory,
@@ -582,8 +583,28 @@ test('inject ChapterDisplay', async () => {
}
}
- const translationReference = referenceFactory.build()
- const intertextReference = referenceFactory.build()
+ const translationReference = referenceFactory.build(
+ {},
+ {
+ associations: {
+ document: bibliographyEntryFactory.build(
+ {},
+ { associations: { id: 'XY1' } }
+ ),
+ },
+ }
+ )
+ const intertextReference = referenceFactory.build(
+ {},
+ {
+ associations: {
+ document: bibliographyEntryFactory.build(
+ {},
+ { associations: { id: 'XY2' } }
+ ),
+ },
+ }
+ )
const chapterWithReferences = produce(chapterDisplay, (draft) => {
draft.lines[0].translation[0].parts = [
createInjectedPart(translationReference),
@@ -607,11 +628,11 @@ test('inject ChapterDisplay', async () => {
]
})
apiClient.fetchJson.mockReturnValue(Bluebird.resolve(chapterWithReferences))
- bibliographyServiceMock.find.mockReturnValueOnce(
- Bluebird.resolve(translationReference.document)
+ bibliographyServiceMock.findMany.mockReturnValueOnce(
+ Bluebird.resolve([translationReference.document])
)
- bibliographyServiceMock.find.mockReturnValueOnce(
- Bluebird.resolve(intertextReference.document)
+ bibliographyServiceMock.findMany.mockReturnValueOnce(
+ Bluebird.resolve([intertextReference.document])
)
await expect(testService.findChapterDisplay(chapterId)).resolves.toEqual(
injectedChapter
@@ -620,12 +641,12 @@ test('inject ChapterDisplay', async () => {
`${chapterUrl}/display`,
false
)
- expect(bibliographyServiceMock.find).toHaveBeenCalledWith(
- translationReference.id
- )
- expect(bibliographyServiceMock.find).toHaveBeenCalledWith(
- intertextReference.id
- )
+ expect(bibliographyServiceMock.findMany).toHaveBeenCalledWith([
+ translationReference.id,
+ ])
+ expect(bibliographyServiceMock.findMany).toHaveBeenCalledWith([
+ intertextReference.id,
+ ])
})
test('listAllTexts', async () => {
From c3eb13d4643a90cb940e875befb478516f2e1983 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Thu, 4 Jan 2024 14:21:38 +0000
Subject: [PATCH 08/24] add id parameter
---
src/test-support/bibliography-fixtures.ts | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/src/test-support/bibliography-fixtures.ts b/src/test-support/bibliography-fixtures.ts
index b948f442f..5998c715a 100644
--- a/src/test-support/bibliography-fixtures.ts
+++ b/src/test-support/bibliography-fixtures.ts
@@ -37,11 +37,11 @@ const authorFactory = Factory.define<
export const cslDataFactory = Factory.define<
CslData,
{ chance: Chance.Chance }
->(({ transientParams }) => {
+>(({ transientParams, associations }) => {
const chance = transientParams.chance ?? defaultChance
const issuedDate = chance.date()
return {
- id: chance.guid(),
+ id: associations.id ?? chance.guid(),
title: chance.sentence(),
type: chance.pickone(['article-journal', 'paper-conference']),
issued: {
@@ -65,10 +65,13 @@ export const cslDataWithContainerTitleShortFactory = cslDataFactory.params({
export const bibliographyEntryFactory = Factory.define<
BibliographyEntry,
CslData & { chance: Chance.Chance }
->(({ transientParams }) => {
+>(({ transientParams, associations }) => {
const chance = transientParams.chance ?? defaultChance
return new BibliographyEntry(
- cslDataFactory.build(transientParams, { transient: { chance } })
+ cslDataFactory.build(transientParams, {
+ transient: { chance },
+ associations,
+ })
)
})
From e2a5cb2b54e7a3e494e8d93504133e0dfde1b415 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Thu, 4 Jan 2024 15:44:14 +0000
Subject: [PATCH 09/24] update tests
---
.../application/FragmentService.test.ts | 5 ++-
.../application/ReferenceInjector.ts | 38 +++++++++++--------
2 files changed, 26 insertions(+), 17 deletions(-)
diff --git a/src/fragmentarium/application/FragmentService.test.ts b/src/fragmentarium/application/FragmentService.test.ts
index 7c4ccc04f..6a474dbf4 100644
--- a/src/fragmentarium/application/FragmentService.test.ts
+++ b/src/fragmentarium/application/FragmentService.test.ts
@@ -40,7 +40,7 @@ jest.mock('./LemmatizationFactory')
jest.mock('bibliography/application/BibliographyService', () => {
return function () {
- return { find: jest.fn(), search: jest.fn() }
+ return { find: jest.fn(), findMany: jest.fn(), search: jest.fn() }
}
})
@@ -229,6 +229,9 @@ describe('methods returning fragment', () => {
bibliographyService.find.mockImplementation((id: string) =>
Promise.reject(new Error(`${id} not found.`))
)
+ bibliographyService.findMany.mockImplementation((ids: string[]) =>
+ Promise.reject(new Error(`${ids} not found.`))
+ )
silenceConsoleErrors()
})
diff --git a/src/transliteration/application/ReferenceInjector.ts b/src/transliteration/application/ReferenceInjector.ts
index 6d9a3b678..187fc6573 100644
--- a/src/transliteration/application/ReferenceInjector.ts
+++ b/src/transliteration/application/ReferenceInjector.ts
@@ -54,25 +54,31 @@ export default class ReferenceInjector {
return _.isEmpty(ids)
? Promise.resolve(parts as MarkupPart[])
- : this.bibliographyService.findMany(ids).then((entries) => {
- const entryMap = _.keyBy(entries, 'id')
+ : this.bibliographyService
+ .findMany(ids)
+ .then((entries) => {
+ const entryMap = _.keyBy(entries, 'id')
- return parts.map((part) => {
- if (isBibliographyPart(part)) {
- const dto = part.reference
- const reference = new Reference(
- dto.type,
- dto.pages,
- dto.notes,
- dto.linesCited,
- entryMap[dto.id]
- )
- return { ...part, reference }
- }
+ return parts.map((part) => {
+ if (isBibliographyPart(part)) {
+ const dto = part.reference
+ const reference = new Reference(
+ dto.type,
+ dto.pages,
+ dto.notes,
+ dto.linesCited,
+ entryMap[dto.id]
+ )
+ return { ...part, reference }
+ }
- return part
+ return part
+ })
+ })
+ .catch((error) => {
+ console.error(error)
+ return parts as MarkupPart[]
})
- })
}
injectReferencesToIntroduction(
From c9d2900533d1042b3358e6195be45a834c4ab048 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Thu, 4 Jan 2024 16:32:38 +0000
Subject: [PATCH 10/24] refactor about/bibliography section
---
src/about/ui/bibliography.tsx | 181 +++++++++++++++++++++++++++++-----
src/common/Markdown.tsx | 6 ++
2 files changed, 160 insertions(+), 27 deletions(-)
diff --git a/src/about/ui/bibliography.tsx b/src/about/ui/bibliography.tsx
index a0be09685..64e664a5e 100644
--- a/src/about/ui/bibliography.tsx
+++ b/src/about/ui/bibliography.tsx
@@ -1,5 +1,5 @@
import React from 'react'
-import { Markdown } from 'common/Markdown'
+import { MarkdownParagraph } from 'common/Markdown'
import Markup from 'markup/ui/markup'
import MarkupService from 'markup/application/MarkupService'
@@ -11,22 +11,21 @@ export default function AboutProject(
return (
<>
I. Bibliography
-
-
-
II. AfO-Register
-
-
-
-
-
C
D
E
F
G
H
J
K
L
M
N
P
R
S
T
@@ -177,12 +298,18 @@ export default function AboutProject(
V
W
Z
)
}
+
+export function MarkdownParagraph(
+ props: Omit
+): JSX.Element {
+ return
+}
From 7e93b4072b66ed4ca3e182164bb525b7e83835ec Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Thu, 4 Jan 2024 16:44:48 +0000
Subject: [PATCH 11/24] refactoring
---
src/about/ui/fragmentarium.tsx | 135 +++++++++++++++++++++++++++------
1 file changed, 111 insertions(+), 24 deletions(-)
diff --git a/src/about/ui/fragmentarium.tsx b/src/about/ui/fragmentarium.tsx
index de1acea22..7b80f4671 100644
--- a/src/about/ui/fragmentarium.tsx
+++ b/src/about/ui/fragmentarium.tsx
@@ -1,5 +1,5 @@
import React from 'react'
-import { Markdown } from 'common/Markdown'
+import { Markdown, MarkdownParagraph } from 'common/Markdown'
import Markup from 'markup/ui/markup'
import MarkupService from 'markup/application/MarkupService'
@@ -26,34 +26,60 @@ export default function AboutProject(
): JSX.Element {
return (
<>
-
-
{' '}
-
+
+
+
+
+
+
I. How to Cite
-
-
-
-
+
+
{' '}
{new Date().toLocaleDateString() + ''}{' '}
-
-
+
V.1. George Smith (26 March 1840 – 19 August 1876)
V.2. Johann Strassmaier, S.J. (15 May 1846 – 11 January 1920)
@@ -206,7 +262,17 @@ export default function AboutProject(
V.3. Carl Bezold (18 May 1859 – 21 November 1922)
@@ -236,12 +309,26 @@ export default function AboutProject(
V.4. Friedrich W. Geers (24 January 1885 – 29 January 1955)
From 15c599fc56417b28fca78fdf60d62ee299e3fef0 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Fri, 5 Jan 2024 10:33:56 +0000
Subject: [PATCH 12/24] wrap lines
---
src/about/ui/fragmentarium.tsx | 321 +++++++++++++++++++++++++++------
1 file changed, 269 insertions(+), 52 deletions(-)
diff --git a/src/about/ui/fragmentarium.tsx b/src/about/ui/fragmentarium.tsx
index 7b80f4671..0ef900c78 100644
--- a/src/about/ui/fragmentarium.tsx
+++ b/src/about/ui/fragmentarium.tsx
@@ -65,10 +65,10 @@ export default function AboutProject(
I. How to Cite
@@ -81,10 +81,10 @@ export default function AboutProject(
V.2. Johann Strassmaier, S.J. (15 May 1846 – 11 January 1920)
@@ -343,12 +343,28 @@ displayed in the Fragmentarium, e.g. @url{/fragmentarium/DT.1}{DT.1}."
V.5. Erica Reiner (4 August 1924 – 31 December 2005)
@@ -363,17 +379,43 @@ displayed in the Fragmentarium, e.g. @url{/fragmentarium/DT.1}{DT.1}."
V.6. W. G. Lambert (26 February 1926 – 9 November 2011)
V.7. Riekele Borger (24 May 1929 – 27 December 2010)
@@ -406,9 +465,27 @@ displayed in the Fragmentarium, e.g. @url{/fragmentarium/DT.1}{DT.1}."
+
-
V.8. Aaron Shaffer (2 January 1933 – 5 April 2004)
V.9. Erle Leichty (7 August 1933 – 19 September 2016)
{' '}
V.10. Stephen J. Lieberman (1943 – 1992)
-
+
-
+
V.11. A. Kirk Grayson
V.12. Werner R. Mayer, S.J.
@@ -478,11 +622,35 @@ displayed in the Fragmentarium, e.g. @url{/fragmentarium/DT.1}{DT.1}."
Transliteration by W. R. Mayer
-
+
V.13. Markham J. Geller
V.14. Simo Parpola
@@ -498,16 +666,17 @@ displayed in the Fragmentarium, e.g. @url{/fragmentarium/DT.1}{DT.1}."
V.15. Irving L. Finkel
@@ -522,7 +691,16 @@ displayed in the Fragmentarium, e.g. @url{/fragmentarium/DT.1}{DT.1}."
V.16. Andrew R. George
@@ -537,22 +715,61 @@ displayed in the Fragmentarium, e.g. @url{/fragmentarium/DT.1}{DT.1}."
V.17. Ulla Koch
V.18. Jeremiah L. Peterson
V.19. Uri Gabbay
>
)
From ccbbb63c03c2a938ea18aa711704a41ef9fb7c29 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Fri, 5 Jan 2024 11:20:15 +0000
Subject: [PATCH 13/24] refactoring
---
src/about/ui/fragmentarium.tsx | 529 ++++++++++++++++-----------------
1 file changed, 255 insertions(+), 274 deletions(-)
diff --git a/src/about/ui/fragmentarium.tsx b/src/about/ui/fragmentarium.tsx
index 0ef900c78..8499ad649 100644
--- a/src/about/ui/fragmentarium.tsx
+++ b/src/about/ui/fragmentarium.tsx
@@ -24,12 +24,18 @@ import strassmaiercopies from 'about/ui/static/strassmaiercopies.jpg'
export default function AboutProject(
markupService: MarkupService
): JSX.Element {
+ function MarkupParagraph({ text }: { text: string }): JSX.Element {
+ return (
+
+
+
+ )
+ }
+
return (
<>
-
-
-
-
-
-
+ />
I. How to Cite
-
-
-
-
+
+ The list of joins has been compiled on the basis of the catalogue of the
+ British Museum, kindly made available by J. Taylor. This catalogue has
+ been supplemented by several join books of the British Museum (currently
+ the join books covering September 1983 to August 1987 and April 1999 to
+ March 2019 have been integrated into the database). In addition, a list
+ of joins of tablets in the Penn Museum as been compiled by J. Peterson
+ on behalf of the eBL project.
+
+
+
III. Photographs
- The photographs of tablets from The British Museum’s Kuyunjik collection
- were produced in 2009-2013, as part of the on-going “Ashurbanipal Library
- Project” (2002–present), thanks to funding provided by The Townley Group
- and The Andrew Mellon Foundation. The photographs were produced by Marieka
- Arksey, Kristin A. Phelps, Sarah Readings, and Ana Tam; with the
- assistance of Alberto Giannese, Gina Konstantopoulos, Chiara Salvador, and
- Mathilde Touillon-Ricci. They are displayed on the eBL website courtesy of
- Dr. Jon Taylor, director of the “Ashurbanipal Library Project.”
-
-
-
-
- I. Kerslake photographs tablets in the British Museum, 2019
-
-
- The photographs of the The British Museum’s Babylon collection are taken
- by Alberto Giannese and Ivor Kerslake (2019–present) in the framework of
- the “electronic Babylonian Literature” project, funded by a Sofia
- Kovalevskaja Award (Alexander von Humboldt Stiftung).
-
- The photographs of the tablets in the Iraq Museum have been produced by
- Anmar A. Fadhil (University of Baghdad – eBL Project), and displayed by
- permission of the State Board of Antiquities and Heritage and The Iraq
- Museum.
-
- The photographs of the tablets in the Yale Babylonian Collection are being
- produced by Klaus Wagensonner (Yale University), and used with the kind
- permission of the Agnete W. Lassen (Associate Curator of the Yale
- Babylonian Collection, Yale Peabody Museum).
-
- The images cannot be reproduced without the explicit consent of the
- funding projects and institutions, as well as the institutions in which
- the cuneiform tablets are kept. Users are referred to the conditions for
- reproducing the images in the links shown in the captions under the
- images.
-
+
+ The photographs of tablets from The British Museum’s Kuyunjik collection
+ were produced in 2009-2013, as part of the on-going “Ashurbanipal
+ Library Project” (2002–present), thanks to funding provided by The
+ Townley Group and The Andrew Mellon Foundation. The photographs were
+ produced by Marieka Arksey, Kristin A. Phelps, Sarah Readings, and Ana
+ Tam; with the assistance of Alberto Giannese, Gina Konstantopoulos,
+ Chiara Salvador, and Mathilde Touillon-Ricci. They are displayed on the
+ eBL website courtesy of Dr. Jon Taylor, director of the “Ashurbanipal
+ Library Project.”
+
+
+
+
+
+ I. Kerslake photographs tablets in the British Museum, 2019
+
+
+ The photographs of the The British Museum’s Babylon collection are taken
+ by Alberto Giannese and Ivor Kerslake (2019–present) in the framework of
+ the “electronic Babylonian Literature” project, funded by a Sofia
+ Kovalevskaja Award (Alexander von Humboldt Stiftung).
+
+
+ The photographs of the tablets in the Iraq Museum have been produced by
+ Anmar A. Fadhil (University of Baghdad – eBL Project), and displayed by
+ permission of the State Board of Antiquities and Heritage and The Iraq
+ Museum.
+
+
+ The photographs of the tablets in the Yale Babylonian Collection are
+ being produced by Klaus Wagensonner (Yale University), and used with the
+ kind permission of the Agnete W. Lassen (Associate Curator of the Yale
+ Babylonian Collection, Yale Peabody Museum).
+
+
+ The images cannot be reproduced without the explicit consent of the
+ funding projects and institutions, as well as the institutions in which
+ the cuneiform tablets are kept. Users are referred to the conditions for
+ reproducing the images in the links shown in the captions under the
+ images.
+
IV. Editions in the Fragmentarium
-
-
-
- List of texts to revise, eBL team
-
-
- The editions in the Fragmentarium have been produced by the entire eBL
- Team, starting in 2018. Thousands of them were produced on the basis of
- photographs and have not been collated in the museum. Although the speed
- at which fragments have been transliterated has been necessarily fast, the
- quality control measurements adopted, and in particular the policy to have
- each edition revised by a scholar different from the original editor,
- means that they are normally reliable. Each member of the team has
- produced some 40 editions and revised some 60 editions a month on average.
-
- In addition, the{' '}
-
- BabMed team
- {' '}
- has kindly made acessible its large collections of transliterations of
- Mesopotamian medicine for their use on the Fragmentarium. They have been
- imported by the eBL team using the importer developed by T. Englmeier (see{' '}
-
- here
- {' '}
- and{' '}
-
- here
-
- ), and thoroughly revised and lemmatized chiefly by H. Stadhouders. The
- transliterations of the BabMed team were originally produced by Markham J.
- Geller, J. Cale Johnson, Ulrike Steinert, Stravil V. Panayotov, Eric
- Schmidtchen, Krisztián Simkó, Marius Hoppe, Marie Lorenz, John
- Schlesinger, Till Kappus, and Agnes Kloocke (at FU Berlin), as well as
- Annie Attia, Sona Eypper, and Henry Stadhouders (as external
- collaborators).
-
+
+
+
+
+ List of texts to revise, eBL team
+
+
+ The editions in the Fragmentarium have been produced by the entire eBL
+ Team, starting in 2018. Thousands of them were produced on the basis of
+ photographs and have not been collated in the museum. Although the speed
+ at which fragments have been transliterated has been necessarily fast,
+ the quality control measurements adopted, and in particular the policy
+ to have each edition revised by a scholar different from the original
+ editor, means that they are normally reliable. Each member of the team
+ has produced some 40 editions and revised some 60 editions a month on
+ average.
+
+
+ In addition, the{' '}
+
+ BabMed team
+ {' '}
+ has kindly made acessible its large collections of transliterations of
+ Mesopotamian medicine for their use on the Fragmentarium. They have been
+ imported by the eBL team using the importer developed by T. Englmeier
+ (see{' '}
+
+ here
+ {' '}
+ and{' '}
+
+ here
+
+ ), and thoroughly revised and lemmatized chiefly by H. Stadhouders. The
+ transliterations of the BabMed team were originally produced by Markham
+ J. Geller, J. Cale Johnson, Ulrike Steinert, Stravil V. Panayotov, Eric
+ Schmidtchen, Krisztián Simkó, Marius Hoppe, Marie Lorenz, John
+ Schlesinger, Till Kappus, and Agnes Kloocke (at FU Berlin), as well as
+ Annie Attia, Sona Eypper, and Henry Stadhouders (as external
+ collaborators).
+
V. Folios
- The electronic Babylonian Literature (eBL) project, and in particular its
- Fragmentarium, continues the efforts of generations of Assyriologists to
- rescue the literature of Ancient Mesopotamia from the hands of oblivion.
- The Fragmentarium stands on the shoulders of previous scholars, and has
- used extensively their unpublished, unfinished work, for compiling its
- database of transliterations. It is a pleasure to acknowledge our
- gratitude to the following scholars:
+
+ The electronic Babylonian Literature (eBL) project, and in particular
+ its Fragmentarium, continues the efforts of generations of
+ Assyriologists to rescue the literature of Ancient Mesopotamia from the
+ hands of oblivion. The Fragmentarium stands on the shoulders of previous
+ scholars, and has used extensively their unpublished, unfinished work,
+ for compiling its database of transliterations. It is a pleasure to
+ acknowledge our gratitude to the following scholars:
+
V.1. George Smith (26 March 1840 – 19 August 1876)
-
@@ -236,19 +244,19 @@ export default function AboutProject(
G. Smith’s draft copy of DT.1
-
+
+ In one of his last diaries, dated August 1876, George Smith states: “I
+ intended to work it out but desire now that my antiquities and notes may
+ be thrown open to all students[.] I have done my duty thoroughly” (Add
+ MS 30425 f. 28a). Smith’s notebooks are kept at the British Library; a
+ provisional catalogue of them was prepared by E. Jiménez. All notebooks
+ containing copies of cuneiform tablets (VII, XI, XII, XIV, and XVII)
+ have been digitized with funds provided by a Sofia Kovalevskaja Award
+ (Alexander von Humboldt Stiftung). The tablets were copied by Smith
+ before they were given museum numbers, so their identification is often
+ challenging. Those that could be identified are displayed in the
+ Fragmentarium, e.g. DT.1 .
+
V.2. Johann Strassmaier, S.J. (15 May 1846 – 11 January 1920)
-
@@ -285,17 +292,17 @@ export default function AboutProject(
Institute
-
+
+ The two collections of Strassmaier’s copies (I and II) were reunited in
+ the Pontifical Biblical Institute by W. R. Mayer in the early 1980s,
+ combining what J. Schaumberger had left to the Biblicum after his death
+ in 1955 with portions of the collections kept in Gars am Inn and in The
+ British Museum. Two different catalogues of the copies were prepared by
+ Mayer, who also collated a large number of the tablets in the British
+ Museum. The collections were digitized in the Pontifical Biblical
+ Institute in 2019, courtesy of W. R. Mayer and of its Rector M. F.
+ Kolarcik.
+
V.3. Carl Bezold (18 May 1859 – 21 November 1922)
-
-
-
V.4. Friedrich W. Geers (24 January 1885 – 29 January 1955)
@@ -341,31 +346,29 @@ export default function AboutProject(
Collection of Geers’s copies once at the Oriental Institute
-
-
-
+
+ Geers’ copies have been digitized from the copy once in the Oriental
+ Institute of The University of Chicago, kindly donated by Prof. Martha
+ T. Roth to the Institut für Assyriologie und Hethitologie of Munich
+ University.
+
V.5. Erica Reiner (4 August 1924 – 31 December 2005)
-
-
-
+
V.6. W. G. Lambert (26 February 1926 – 9 November 2011)
-
-
-
-
-
V.9. Erle Leichty (7 August 1933 – 19 September 2016)
-
-
-
-
{' '}
-
V.10. Stephen J. Lieberman (1943 – 1992)
-
-
-
V.11. A. Kirk Grayson
-
V.13. Markham J. Geller
- Rm.468
-
-
V.17. Ulla Koch
-
V.18. Jeremiah L. Peterson
-
V.19. Uri Gabbay
-
I. How to Cite
-
-
+
+ These initial sources have been thoroughly corrected and supplemented by
+ the eBL project’s staff.
+
III. Photographs
The photographs of tablets from The British Museum’s Kuyunjik collection
@@ -508,11 +510,11 @@ export default function AboutProject(
texts from Ur, resulted in the posthumous publication of @i{Ur Excavations
Texts VI: Literary and Religious Texts, Third Part} in 2006 (@bib{UET_6_3})."
/>
-
+
+ Shaffer’s large collection of photographs, many of them of Ur tablets,
+ are in the possession of Nathan Wasserman, who has catalogued and
+ digitized them and generously shared them with the eBL.
+
V.9. Erle Leichty (7 August 1933 – 19 September 2016)
-
-
+
+ Leichty must have imagined that his notebooks would one day be used for
+ the digital reconstruction of cuneiform literature, since in one of his
+ notebooks he writes: “many r[igh]t sides of omens too fragmentary to
+ identify but might be good for computer search” (EL NB 911, see the
+ adjoining image).
+
+
+ The transliterations of Erle Leichty are used here with the generous
+ permission of Steve Tinney, Associate Curator of the Babylonian Section
+ (Penn Museum of Archaeology and Anthropology). Thanks are expressed to
+ Phil Jones and his team, who were responsible for the scanning of part
+ of them.
+
V.10. Stephen J. Lieberman (1943 – 1992)
+
+ Irving L. Finkel is a leading authority in the field of Mesopotamian
+ scholarship, whose areas of expertise encompass a wide range of
+ subjects, from astronomical diaries to ancient board games. Finkel has
+ served as an Assistant Keeper at the British Museum’s Department of the
+ Middle East for many years. Finkel’s many significant contributions to
+ Assyriology stem from his discoveries of valuable tablets and fragments
+ in the museum’s collection, with which he is uniquely acquainted. The
+ decades of meticulous work Finkel has devoted to Assyriology are evident
+ in his notebooks, which include lists of “joins” discovered by him, as
+ well as careful, accurate transliterations of hundreds of medical and
+ magical texts.
+
V.16. Andrew R. George
Date: Fri, 5 Jan 2024 11:37:14 +0000
Subject: [PATCH 15/24] refactor injectReferencesToMarkup
---
.../application/ReferenceInjector.ts | 44 +++++++++++--------
1 file changed, 25 insertions(+), 19 deletions(-)
diff --git a/src/transliteration/application/ReferenceInjector.ts b/src/transliteration/application/ReferenceInjector.ts
index 187fc6573..44fbcaa21 100644
--- a/src/transliteration/application/ReferenceInjector.ts
+++ b/src/transliteration/application/ReferenceInjector.ts
@@ -13,6 +13,7 @@ import { OldLineNumber } from 'transliteration/domain/line-number'
import { OldLineNumberDto } from 'corpus/application/dtos'
import { Introduction, Notes } from 'fragmentarium/domain/fragment'
import _ from 'lodash'
+import BibliographyEntry from 'bibliography/domain/BibliographyEntry'
function isMarkupLine(
line: Draft
@@ -45,6 +46,29 @@ export default class ReferenceInjector {
})
}
+ private mergeEntries(
+ parts: readonly MarkupPart[],
+ entries: readonly BibliographyEntry[]
+ ): MarkupPart[] {
+ const entryMap = _.keyBy(entries, 'id')
+
+ return parts.map((part) => {
+ if (isBibliographyPart(part)) {
+ const dto = part.reference
+ const reference = new Reference(
+ dto.type,
+ dto.pages,
+ dto.notes,
+ dto.linesCited,
+ entryMap[dto.id]
+ )
+ return { ...part, reference }
+ }
+
+ return part
+ })
+ }
+
injectReferencesToMarkup(
parts: readonly MarkupPart[]
): Promise {
@@ -56,25 +80,7 @@ export default class ReferenceInjector {
? Promise.resolve(parts as MarkupPart[])
: this.bibliographyService
.findMany(ids)
- .then((entries) => {
- const entryMap = _.keyBy(entries, 'id')
-
- return parts.map((part) => {
- if (isBibliographyPart(part)) {
- const dto = part.reference
- const reference = new Reference(
- dto.type,
- dto.pages,
- dto.notes,
- dto.linesCited,
- entryMap[dto.id]
- )
- return { ...part, reference }
- }
-
- return part
- })
- })
+ .then((entries) => this.mergeEntries(parts, entries))
.catch((error) => {
console.error(error)
return parts as MarkupPart[]
From 0c8e5762abc31342f060f883194a0c45f1b01b56 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Fri, 5 Jan 2024 13:58:16 +0000
Subject: [PATCH 16/24] add CachedMarkupService
---
src/index.tsx | 9 ++++++++-
src/markup/application/MarkupService.ts | 21 +++++++++++++++++++--
src/router/aboutRoutes.tsx | 8 ++++----
src/router/router.tsx | 5 ++++-
src/test-support/AppDriver.tsx | 6 +++++-
5 files changed, 40 insertions(+), 9 deletions(-)
diff --git a/src/index.tsx b/src/index.tsx
index c1f8aab07..8998d7064 100644
--- a/src/index.tsx
+++ b/src/index.tsx
@@ -24,7 +24,9 @@ import { scopeString, useAuthentication } from 'auth/Auth'
import SignService from 'signs/application/SignService'
import SignRepository from 'signs/infrastructure/SignRepository'
import AfoRegisterRepository from 'afo-register/infrastructure/AfoRegisterRepository'
-import MarkupService from 'markup/application/MarkupService'
+import MarkupService, {
+ CachedMarkupService,
+} from 'markup/application/MarkupService'
import AfoRegisterService from 'afo-register/application/AfoRegisterService'
import './index.sass'
import { FindspotService } from 'fragmentarium/application/FindspotService'
@@ -80,6 +82,10 @@ function InjectedApp(): JSX.Element {
)
const signService = new SignService(signsRepository)
const markupService = new MarkupService(apiClient, bibliographyService)
+ const cachedMarkupService = new CachedMarkupService(
+ apiClient,
+ bibliographyService
+ )
const afoRegisterService = new AfoRegisterService(afoRegisterRepository)
const findspotService = new FindspotService(findspotRepository)
return (
@@ -91,6 +97,7 @@ function InjectedApp(): JSX.Element {
bibliographyService={bibliographyService}
textService={textService}
markupService={markupService}
+ cachedMarkupService={cachedMarkupService}
afoRegisterService={afoRegisterService}
findspotService={findspotService}
/>
diff --git a/src/markup/application/MarkupService.ts b/src/markup/application/MarkupService.ts
index 0d5520b23..d044813f0 100644
--- a/src/markup/application/MarkupService.ts
+++ b/src/markup/application/MarkupService.ts
@@ -6,9 +6,9 @@ import { MarkupPart } from 'transliteration/domain/markup'
import { stringify } from 'query-string'
export default class MarkupService {
- private readonly referenceInjector: ReferenceInjector
+ protected readonly referenceInjector: ReferenceInjector
constructor(
- private readonly apiClient: ApiClient,
+ protected readonly apiClient: ApiClient,
bibliographyService: BibliographyService
) {
this.referenceInjector = new ReferenceInjector(bibliographyService)
@@ -42,3 +42,20 @@ export default class MarkupService {
return this.referenceInjector.injectReferencesToMarkup(parts)
}
}
+
+export class CachedMarkupService extends MarkupService {
+ fromString(text: string): Bluebird {
+ return this.apiClient
+ .fetchJson(
+ `/cached-markup?${stringify({
+ text: text,
+ })}`,
+ false
+ )
+ .then((parts) => {
+ return Bluebird.all(
+ parts && Bluebird.all(this.injectReferencesToMarkup(parts))
+ )
+ })
+ }
+}
diff --git a/src/router/aboutRoutes.tsx b/src/router/aboutRoutes.tsx
index 5de6741fa..2479796ef 100644
--- a/src/router/aboutRoutes.tsx
+++ b/src/router/aboutRoutes.tsx
@@ -1,16 +1,16 @@
import React, { ReactNode } from 'react'
import { Redirect, Route, RouteComponentProps } from 'react-router-dom'
import About, { TabId, tabIds } from 'about/ui/about'
-import MarkupService from 'markup/application/MarkupService'
+import { CachedMarkupService } from 'markup/application/MarkupService'
import { sitemapDefaults } from 'router/sitemap'
import { HeadTagsService } from 'router/head'
export default function AboutRoutes({
sitemap,
- markupService,
+ cachedMarkupService,
}: {
sitemap: boolean
- markupService: MarkupService
+ cachedMarkupService: CachedMarkupService
}): JSX.Element[] {
return [
diff --git a/src/router/router.tsx b/src/router/router.tsx
index b4694ac8d..d90d3e3b0 100644
--- a/src/router/router.tsx
+++ b/src/router/router.tsx
@@ -8,7 +8,9 @@ import FragmentService from 'fragmentarium/application/FragmentService'
import FragmentSearchService from 'fragmentarium/application/FragmentSearchService'
import BibliographyService from 'bibliography/application/BibliographyService'
import TextService from 'corpus/application/TextService'
-import MarkupService from 'markup/application/MarkupService'
+import MarkupService, {
+ CachedMarkupService,
+} from 'markup/application/MarkupService'
import SignService from 'signs/application/SignService'
import AfoRegisterService from 'afo-register/application/AfoRegisterService'
@@ -33,6 +35,7 @@ export interface Services {
textService: TextService
signService: SignService
markupService: MarkupService
+ cachedMarkupService: CachedMarkupService
afoRegisterService: AfoRegisterService
findspotService: FindspotService
}
diff --git a/src/test-support/AppDriver.tsx b/src/test-support/AppDriver.tsx
index a58ff68ed..30d04625a 100644
--- a/src/test-support/AppDriver.tsx
+++ b/src/test-support/AppDriver.tsx
@@ -27,7 +27,9 @@ import { Promise } from 'bluebird'
import { eblNameProperty, AuthenticationContext } from 'auth/Auth'
import SignRepository from 'signs/infrastructure/SignRepository'
import SignService from 'signs/application/SignService'
-import MarkupService from 'markup/application/MarkupService'
+import MarkupService, {
+ CachedMarkupService,
+} from 'markup/application/MarkupService'
import AfoRegisterRepository from 'afo-register/infrastructure/AfoRegisterRepository'
import AfoRegisterService from 'afo-register/application/AfoRegisterService'
import { FindspotService } from 'fragmentarium/application/FindspotService'
@@ -59,6 +61,7 @@ function createApp(api): JSX.Element {
const afoRegisterRepository = new AfoRegisterRepository(api)
const signService = new SignService(signsRepository)
const markupService = new MarkupService(api, bibliographyService)
+ const cachedMarkupService = new CachedMarkupService(api, bibliographyService)
const afoRegisterService = new AfoRegisterService(afoRegisterRepository)
const findspotService = new FindspotService(findspotRepository)
return (
@@ -70,6 +73,7 @@ function createApp(api): JSX.Element {
bibliographyService={bibliographyService}
textService={textService}
markupService={markupService}
+ cachedMarkupService={cachedMarkupService}
afoRegisterService={afoRegisterService}
findspotService={findspotService}
/>
From 73b6d01c561beef0c3633bc10ee87868f9a499c3 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Fri, 5 Jan 2024 14:30:00 +0000
Subject: [PATCH 17/24] refactoring
---
src/about/ui/bibliography.tsx | 2 +-
src/about/ui/chronology.tsx | 18 +++++++++---------
src/about/ui/corpus.tsx | 4 +---
src/about/ui/fragmentarium.tsx | 2 +-
src/markup/application/MarkupService.ts | 18 +++---------------
5 files changed, 15 insertions(+), 29 deletions(-)
diff --git a/src/about/ui/bibliography.tsx b/src/about/ui/bibliography.tsx
index 64e664a5e..5897dd668 100644
--- a/src/about/ui/bibliography.tsx
+++ b/src/about/ui/bibliography.tsx
@@ -5,7 +5,7 @@ import MarkupService from 'markup/application/MarkupService'
import afoRegisterCover from 'about/ui/static/afoRegister.png'
-export default function AboutProject(
+export default function AboutBibliography(
markupService: MarkupService
): JSX.Element {
return (
diff --git a/src/about/ui/chronology.tsx b/src/about/ui/chronology.tsx
index 973bd13c8..05a5e7057 100644
--- a/src/about/ui/chronology.tsx
+++ b/src/about/ui/chronology.tsx
@@ -7,15 +7,15 @@ export default function AboutChronology(): JSX.Element {
<>
>
diff --git a/src/about/ui/corpus.tsx b/src/about/ui/corpus.tsx
index 036aba856..1d0f70f0d 100644
--- a/src/about/ui/corpus.tsx
+++ b/src/about/ui/corpus.tsx
@@ -9,9 +9,7 @@ import geneva from 'about/ui/static/geneva.jpg'
import muses from 'about/ui/static/muses.jpg'
import snf from 'about/ui/static/snf.jpg'
-export default function AboutProject(
- markupService: MarkupService
-): JSX.Element {
+export default function AboutCorpus(markupService: MarkupService): JSX.Element {
return (
<>
diff --git a/src/about/ui/fragmentarium.tsx b/src/about/ui/fragmentarium.tsx
index 9aa90b2d3..35564ad31 100644
--- a/src/about/ui/fragmentarium.tsx
+++ b/src/about/ui/fragmentarium.tsx
@@ -21,7 +21,7 @@ import smithdt1 from 'about/ui/static/smithdt1.jpg'
import strassmaier from 'about/ui/static/strassmaier.jpg'
import strassmaiercopies from 'about/ui/static/strassmaiercopies.jpg'
-export default function AboutProject(
+export default function AboutFragmentarium(
markupService: MarkupService
): JSX.Element {
function MarkupParagraph({ text }: { text: string }): JSX.Element {
diff --git a/src/markup/application/MarkupService.ts b/src/markup/application/MarkupService.ts
index d044813f0..b181264e6 100644
--- a/src/markup/application/MarkupService.ts
+++ b/src/markup/application/MarkupService.ts
@@ -13,11 +13,12 @@ export default class MarkupService {
) {
this.referenceInjector = new ReferenceInjector(bibliographyService)
}
+ protected urlPath = 'markup'
fromString(text: string): Bluebird {
return this.apiClient
.fetchJson(
- `/markup?${stringify({
+ `/${this.urlPath}?${stringify({
text: text,
})}`,
false
@@ -44,18 +45,5 @@ export default class MarkupService {
}
export class CachedMarkupService extends MarkupService {
- fromString(text: string): Bluebird {
- return this.apiClient
- .fetchJson(
- `/cached-markup?${stringify({
- text: text,
- })}`,
- false
- )
- .then((parts) => {
- return Bluebird.all(
- parts && Bluebird.all(this.injectReferencesToMarkup(parts))
- )
- })
- }
+ protected urlPath = 'cached-markup'
}
From ad430f7b7cd7a0821de1df56d6db5cc2efc4c998 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Fri, 5 Jan 2024 16:04:11 +0000
Subject: [PATCH 18/24] fix typeerror
---
src/router/sitemap.test.tsx | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/src/router/sitemap.test.tsx b/src/router/sitemap.test.tsx
index 289a6ce6c..46126fa15 100644
--- a/src/router/sitemap.test.tsx
+++ b/src/router/sitemap.test.tsx
@@ -6,7 +6,9 @@ import WordService from 'dictionary/application/WordService'
import FragmentService from 'fragmentarium/application/FragmentService'
import FragmentSearchService from 'fragmentarium/application/FragmentSearchService'
import TextService from 'corpus/application/TextService'
-import MarkupService from 'markup/application/MarkupService'
+import MarkupService, {
+ CachedMarkupService,
+} from 'markup/application/MarkupService'
import AfoRegisterService from 'afo-register/application/AfoRegisterService'
import Bluebird from 'bluebird'
import { Services } from './router'
@@ -47,6 +49,9 @@ beforeEach(() => {
const markupService = new (MarkupService as jest.Mock<
jest.Mocked
>)()
+ const cachedMarkupService = new (CachedMarkupService as jest.Mock<
+ jest.Mocked
+ >)()
const afoRegisterService = new (AfoRegisterService as jest.Mock<
jest.Mocked
@@ -76,6 +81,7 @@ beforeEach(() => {
fragmentSearchService: fragmentSearchService,
textService: textService,
markupService: markupService,
+ cachedMarkupService: cachedMarkupService,
afoRegisterService: afoRegisterService,
}
})
From 0523a295567e362110e7d09ce380df328a8daf5c Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Fri, 5 Jan 2024 16:54:59 +0000
Subject: [PATCH 19/24] ensure headings align left after floating figures
---
src/about/ui/about.sass | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/about/ui/about.sass b/src/about/ui/about.sass
index d0eaa30a1..aba58d594 100644
--- a/src/about/ui/about.sass
+++ b/src/about/ui/about.sass
@@ -10,13 +10,14 @@
[id^="about-tabpane-"] h3
padding-top: 10px
+ clear: left
[id^="about-tabpane-"] h4
padding-top: 10px
[id^="about-tabpane-"] blockquote
padding-left: 40%
-
+
[id^="about-tabpane-"] .Introduction
&__200px
@@ -30,15 +31,15 @@
&__300px
width: 300px
height: auto
-
+
&__350px
width: 350px
height: auto
-
+
&__400px
width: 400px
height: auto
-
+
&__450px
width: 450px
height: auto
@@ -64,7 +65,7 @@
&__creativeCommonsLicense
text-align: center
-
+
&__fossey
float: right
width: 300px
@@ -93,4 +94,3 @@
&__secondLineOfParallelism
padding-left: 1em
-
From 1c2a1101a5ad8bb6fe22901f5d26464a590b0b9b Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Fri, 5 Jan 2024 16:55:10 +0000
Subject: [PATCH 20/24] refactoring
---
src/about/ui/corpus.tsx | 155 +++++++++++++++++++++++++++++++--------
src/about/ui/project.tsx | 24 +++++-
2 files changed, 148 insertions(+), 31 deletions(-)
diff --git a/src/about/ui/corpus.tsx b/src/about/ui/corpus.tsx
index 1d0f70f0d..711caf8a8 100644
--- a/src/about/ui/corpus.tsx
+++ b/src/about/ui/corpus.tsx
@@ -1,5 +1,5 @@
import React from 'react'
-import { Markdown } from 'common/Markdown'
+import { MarkdownParagraph } from 'common/Markdown'
import Markup from 'markup/ui/markup'
import MarkupService from 'markup/application/MarkupService'
@@ -13,20 +13,39 @@ export default function AboutCorpus(markupService: MarkupService): JSX.Element {
return (
<>
-
- Ohne feste kritische Grundlage wird das philologische Gebäude auf Sand
- aufgeführt und die philologische Wissenschaft gestaltet sich zum
- bloßen Dilettantismus.
-
-
-
+
+
+ Ohne feste kritische Grundlage wird das philologische Gebäude auf
+ Sand aufgeführt und die philologische Wissenschaft gestaltet sich
+ zum bloßen Dilettantismus.
+
+
+
+
-
- {' '}
+
I. Corpus
II. Translations
@@ -43,13 +62,36 @@ export default function AboutCorpus(markupService: MarkupService): JSX.Element {
+
+
+
-
-
-
III. Ideal Text
-
+
I 49
-
-
-
-
+
+
IV. Score Edition
134
-
-
-
+
+
V. Paratextual information
-
-
-
-
-
+
+
+
VI. Šumma ālu
-
+
diff --git a/src/about/ui/project.tsx b/src/about/ui/project.tsx
index fefd0bfcf..565b920e3 100644
--- a/src/about/ui/project.tsx
+++ b/src/about/ui/project.tsx
@@ -39,11 +39,31 @@ export default function AboutProject(
List of Participants
From 41c90e1be67e9c9b31e39959186d6d04324f9bbc Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Fri, 5 Jan 2024 17:07:49 +0000
Subject: [PATCH 21/24] refactor about signs
---
src/about/ui/about.tsx | 2 +-
src/about/ui/signs.tsx | 166 ++++++++++++++++++++---------------------
2 files changed, 83 insertions(+), 85 deletions(-)
diff --git a/src/about/ui/about.tsx b/src/about/ui/about.tsx
index 49b4577f6..041e62290 100644
--- a/src/about/ui/about.tsx
+++ b/src/about/ui/about.tsx
@@ -64,7 +64,7 @@ export default function About({
{AboutCorpus(markupService)}
- {AboutSigns(markupService)}
+ {AboutSigns()}
{AboutDictionary(markupService)}
diff --git a/src/about/ui/signs.tsx b/src/about/ui/signs.tsx
index 8ecd5e25f..b41d44ebe 100644
--- a/src/about/ui/signs.tsx
+++ b/src/about/ui/signs.tsx
@@ -1,15 +1,13 @@
import React from 'react'
-import { Markdown } from 'common/Markdown'
-import Markup from 'markup/ui/markup'
-import MarkupService from 'markup/application/MarkupService'
+import { Markdown, MarkdownParagraph } from 'common/Markdown'
import fossey from 'about/ui/static/fossey.jpg'
import meszl from 'about/ui/static/meszl.jpg'
-export default function AbouSigns(markupService: MarkupService): JSX.Element {
+export default function AboutSigns(): JSX.Element {
return (
<>
-
-
I. Sign information
-
-
-
-
-
II. Mesopotamisches Zeichenlexikon
@@ -46,46 +46,48 @@ export default function AbouSigns(markupService: MarkupService): JSX.Element {
Borger, Mesopotamisches Zeichenlexikon
-
-
- {' '}
- different color
-
-
-
+ {' '}
+
+ different color
+
+
+
+
+
-
-
III. Fossey, Manuel d’assyriologie II
@@ -98,41 +100,37 @@ export default function AbouSigns(markupService: MarkupService): JSX.Element {
Fossey, Manuel d’assyriologie II
-
-
-
IV. Palaeography
-
-
-
+
+ The tool for tagging images of cuneiform tablets that is at the core of
+ the palaeography section was implemented by J. Laasonen and Y. Cobanoglu
+ in the framework of the project “Searching through Ancient Libraries:
+ New Statistical Indexing Methods for 2D Images of Cuneiform Documents”
+ (Y. Cohen, E. Jiménez, Sh. Gordin), financed by a Call for Joint
+ Research Project on Data Science between Ludwig-Maximilians-Universität
+ München (LMU) and Tel Aviv University (TAU).
+
+
+ The entire eBL team has contributed to the tagging of tablets, but the
+ labor of N. Wenner, L. Sáenz, M. Fadhil, and S. Cohen should be singled
+ out. More tablets are being tagged daily. Furthermore, a system for
+ automatically labeling photographs has been implemented and is
+ undergoing refinement.
+
>
)
}
From 76d16949bccfcb6f31426d71c2758195606238ac Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Mon, 8 Jan 2024 11:12:54 +0000
Subject: [PATCH 22/24] refactoring
---
src/about/ui/dictionary.tsx | 73 +++++++++++++++++++++++++++++++------
1 file changed, 62 insertions(+), 11 deletions(-)
diff --git a/src/about/ui/dictionary.tsx b/src/about/ui/dictionary.tsx
index 5afaeb692..781afcea0 100644
--- a/src/about/ui/dictionary.tsx
+++ b/src/about/ui/dictionary.tsx
@@ -30,29 +30,80 @@ export default function AboutDictionary(
Black, George, Postgate, A Concise Dictionary of Akkadian
-
+
-
+
II. Akkadian-Arabic Reference Dictionary
III. Akkadische Logogramme
-
+
IV. Akkadische Glossare und Indizes (AfO-Register)
-
+
-
+
V. Supplement to the Akkadian Dictionaries
-
+
>
)
}
From 4f48b17dacbf42024cdf38fdd948dc14346ca084 Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Mon, 8 Jan 2024 11:13:13 +0000
Subject: [PATCH 23/24] update snapshot
---
.../ui/__snapshots__/about.test.tsx.snap | 131 +++++++++---------
1 file changed, 62 insertions(+), 69 deletions(-)
diff --git a/src/about/ui/__snapshots__/about.test.tsx.snap b/src/about/ui/__snapshots__/about.test.tsx.snap
index 608f40eb3..2321b0e82 100644
--- a/src/about/ui/__snapshots__/about.test.tsx.snap
+++ b/src/about/ui/__snapshots__/about.test.tsx.snap
@@ -144,11 +144,12 @@ exports[`Snapshot 1`] = `
role="tabpanel"
>
-
- Ohne feste kritische Grundlage wird das philologische Gebäude auf Sand aufgeführt und die philologische Wissenschaft gestaltet sich zum bloßen Dilettantismus.
-
-
-
+
+
+ Ohne feste kritische Grundlage wird das philologische Gebäude auf Sand aufgeführt und die philologische Wissenschaft gestaltet sich zum bloßen Dilettantismus.
+
+
+
W. Freund,
. Leipzig, 1874.
-
+
-
-
- The eBL editions aim to present the best text that can be reconstructed at present. The editions prepared in the course of the project include all previous scholarship on the texts, and in particular all new manuscripts identified after the last printed editions. The eBL edition of the
+
+ The eBL editions aim to present the best text that can be reconstructed at present. The editions prepared in the course of the project include all previous scholarship on the texts, and in particular all new manuscripts identified after the last printed editions. The eBL edition of the
- Cuthaean Legend of Narām-Sîn
+ Cuthaean Legend of Narām-Sîn
- , for instance, almost doubles the manuscript basis of the text available to its last editor; that of the
+ , for instance, almost doubles the manuscript basis of the text available to its last editor; that of the
@@ -178,17 +178,16 @@ exports[`Snapshot 1`] = `
Counsels of Wisdom
- includes over twenty new manuscripts that were absent from the most recent printed edition. Most of the new manuscripts used have been identified by the eBL team, and are currently being published in the series of articles
+ includes over twenty new manuscripts that were absent from the most recent printed edition. Most of the new manuscripts used have been identified by the eBL team, and are currently being published in the series of articles
From the Electronic Babylonian Literature Lab
- that appear in the journal
+ that appear in the journal
Kaskal
- . Moreover, the eBL editions are constantly updated, and the editors will incorporate new discoveries as they appear.
-
-
+ . Moreover, the eBL editions are constantly updated, and the editors will incorporate new discoveries as they appear.
+
I. Corpus
@@ -264,12 +263,12 @@ exports[`Snapshot 1`] = `
1, 20 n. 2), that seems to resume the content of the preceding chapter. About one half or even two thirds of the composition is missing. This is underlined by the colophon, that takes almost all of the space on the reverse but in many other cases covers only about a third and occasionally half of a tablet. The tablet stems from the 27. campaign in Uruk 1969 of the residential area U XVIII and was published first by Hunger 1976 in SpTU 1, 2.
-
+
Additional translations have been produced by A. R. George (
Gilgameš
- ), W. G. Lambert (
+ ), W. G. Lambert (
@@ -279,13 +278,13 @@ exports[`Snapshot 1`] = `
- Marduk’s Address to the Demons
+ Marduk’s Address to the Demons
), T. Mitto (
- Catalogue of Texts and Authors
+ Catalogue of Texts and Authors
and
Hymn to Ninurta as Savior
- ) and E. Jiménez.
-
-
-
- In addition, a series of translations into Arabic are in preparation by A. A. Fadhil, W. Khatabe, and W. Zerkly (see for now A. A. Fadhil’s Arabic translation of
+ ) and E. Jiménez.
+
+
+ In addition, a series of translations into Arabic are in preparation by A. A. Fadhil, W. Khatabe, and W. Zerkly (see for now A. A. Fadhil’s Arabic translation of
@@ -307,13 +305,13 @@ exports[`Snapshot 1`] = `
I
)
-
+
III. Ideal Text
-
- The main version displayed on the eBL Corpus is a phonetic transcription of the text, which has been adjusted according to the rules of Standard Babylonian grammar. This practice somewhat departs from the Assyriological tradition of editing “eclectic” texts, i.e. transliterations that combine the readings of various manuscripts. It has been adopted, however, in the conviction that Mesopotamian texts are also objects of art, and not just objects of scientific study, and as such convey their message only through the interplay of form and content.
-
+
+ The main version displayed on the eBL Corpus is a phonetic transcription of the text, which has been adjusted according to the rules of Standard Babylonian grammar. This practice somewhat departs from the Assyriological tradition of editing “eclectic” texts, i.e. transliterations that combine the readings of various manuscripts. It has been adopted, however, in the conviction that Mesopotamian texts are also objects of art, and not just objects of scientific study, and as such convey their message only through the interplay of form and content.
+
@@ -337,9 +335,8 @@ exports[`Snapshot 1`] = `
-
-
- The practice of using a phonetic transcription as the main text no doubt has disadvantages: for instance, it obscures the way in which the text is written in cuneiform, and it affords a sense of grammatical certainty that is absent from a regular transliteration. However, it also offers considerable advantages: in particular, it does not require the editor to adopt any particular spelling when no good criteria exist for preferring one over the other. In
+
+ The practice of using a phonetic transcription as the main text no doubt has disadvantages: for instance, it obscures the way in which the text is written in cuneiform, and it affords a sense of grammatical certainty that is absent from a regular transliteration. However, it also offers considerable advantages: in particular, it does not require the editor to adopt any particular spelling when no good criteria exist for preferring one over the other. In
Enūma eliš
@@ -349,19 +346,18 @@ exports[`Snapshot 1`] = `
>
I 49
- (see the adjoining image), for instance, the editor would have to choose between the accusative
+ (see the adjoining image), for instance, the editor would have to choose between the accusative
al-ka-ta
- , attested only in Assyrian manuscripts, or the normal Babylonian spelling
+ , attested only in Assyrian manuscripts, or the normal Babylonian spelling
al-ka-tu
- ₄. In a transcription the editor can convey his interpretation of the text in a much more satisfactory manner than in a traditional transliteration.
-
-
-
- The transcription respects the ways in which the manuscripts are written as much as possible. For instance,
+ ₄. In a transcription the editor can convey his interpretation of the text in a much more satisfactory manner than in a traditional transliteration.
+
+
+ The transcription respects the ways in which the manuscripts are written as much as possible. For instance,
Enūma eliš
@@ -371,11 +367,11 @@ exports[`Snapshot 1`] = `
>
VI 124
- is transcribed as
+ is transcribed as
muṭaḫḫidu urîšun
- , “who enriches their stables,” and thus assumes a hymno-epic ending -
+ , “who enriches their stables,” and thus assumes a hymno-epic ending -
u
@@ -383,7 +379,7 @@ exports[`Snapshot 1`] = `
nomen regens
- , instead of the normal bound form
+ , instead of the normal bound form
muṭaḫḫid
@@ -392,7 +388,7 @@ exports[`Snapshot 1`] = `
mu-ṭaḫ-ḫi-du
is the spelling of all manuscripts.
-
+
IV. Score Edition
@@ -419,65 +415,62 @@ exports[`Snapshot 1`] = `
-
- Since the number of manuscripts of each text is constantly growing, cuneiform studies is reaching the point where it is no longer possible to print text editions in the score format. Just the eBL edition score of
+
+ Since the number of manuscripts of each text is constantly growing, cuneiform studies is reaching the point where it is no longer possible to print text editions in the score format. Just the eBL edition score of
Enūma eliš
- , for example, would require some 300 pages in font size 10. Despite this technical limitation, scores are the fastest, most straightforward way of checking exactly how manuscripts write their texts. The eBL scores are, moreover, aligned with the ideal line, so that the reader can check the manuscript basis of the editor’s decisions at any time.
-
-
-
- All transliterations have been checked twice against the published copies and against photographs and in some cases the originals of the cuneiform tablets.
-
+ , for example, would require some 300 pages in font size 10. Despite this technical limitation, scores are the fastest, most straightforward way of checking exactly how manuscripts write their texts. The eBL scores are, moreover, aligned with the ideal line, so that the reader can check the manuscript basis of the editor’s decisions at any time.
+
+
+ All transliterations have been checked twice against the published copies and against photographs and in some cases the originals of the cuneiform tablets.
+
V. Paratextual information
-
- Each text is furnished with an introduction, which discusses the content and structure of the text, its origins and transmission, its Sitz im Leben and the history of research concerning the text.
-
-
-
- The editions are fully lemmatized and annotated. The annotation includes indications of all parallel lines, so that the text can be studied as part of the intertextual network in which it belongs. In addition, the notes on individual lines endeavor to provide the reader with references to all previous bibliography, with particular emphasis on studies which have appeared in the last few years. The notes on the score edition discuss mostly philological issues pertaining to an individual manuscript.
-
-
-
- The colophons of the individual manuscripts are transliterated independently, and can be accessed on the homepage of any text (e.g.
+
+ Each text is furnished with an introduction, which discusses the content and structure of the text, its origins and transmission, its Sitz im Leben and the history of research concerning the text.
+
+
+ The editions are fully lemmatized and annotated. The annotation includes indications of all parallel lines, so that the text can be studied as part of the intertextual network in which it belongs. In addition, the notes on individual lines endeavor to provide the reader with references to all previous bibliography, with particular emphasis on studies which have appeared in the last few years. The notes on the score edition discuss mostly philological issues pertaining to an individual manuscript.
+
+
+ The colophons of the individual manuscripts are transliterated independently, and can be accessed on the homepage of any text (e.g.
here
- ). In some cases, manuscripts include lines that, though clearly part of the composition in question, cannot yet be placed in it, and thus are transliterated independently, as Unplaced lines.
-
+ ). In some cases, manuscripts include lines that, though clearly part of the composition in question, cannot yet be placed in it, and thus are transliterated independently, as Unplaced lines.
+
VI. Šumma ālu
-
+
The editions of
Šumma ālu
- presented here were prepared in the context of the projects “Edition of the Omen Series Šumma Alu” (2017–2021;
+ presented here were prepared in the context of the projects “Edition of the Omen Series Šumma Alu” (2017–2021;
http://p3.snf.ch/project-175970
- ) and “Typology and potential of the excerpt tablets of Šumma alu” (2022–2023;
+ ) and “Typology and potential of the excerpt tablets of Šumma alu” (2022–2023;
http://p3.snf.ch/project-205122
- ), both directed by Prof. Catherine Mittermayer at the University of Geneva and funded by the Swiss National Science Foundation. The complete score editions can be downloaded (PDF) at the “Archive ouverte” of the University of Geneva (
+ ), both directed by Prof. Catherine Mittermayer at the University of Geneva and funded by the Swiss National Science Foundation. The complete score editions can be downloaded (PDF) at the “Archive ouverte” of the University of Geneva (
https://archive-ouverte.unige.ch/
- ; search for “Shumma alu”).
-
+ ; search for “Shumma alu”).
+
From 89b68408fda41d7979bd3b04e60a44d30343afcb Mon Sep 17 00:00:00 2001
From: fsimonjetz
Date: Mon, 8 Jan 2024 13:11:24 +0000
Subject: [PATCH 24/24] change property order
---
src/markup/application/MarkupService.ts | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/markup/application/MarkupService.ts b/src/markup/application/MarkupService.ts
index b181264e6..7cc9fb1d5 100644
--- a/src/markup/application/MarkupService.ts
+++ b/src/markup/application/MarkupService.ts
@@ -7,13 +7,14 @@ import { stringify } from 'query-string'
export default class MarkupService {
protected readonly referenceInjector: ReferenceInjector
+ protected urlPath = 'markup'
+
constructor(
protected readonly apiClient: ApiClient,
bibliographyService: BibliographyService
) {
this.referenceInjector = new ReferenceInjector(bibliographyService)
}
- protected urlPath = 'markup'
fromString(text: string): Bluebird {
return this.apiClient