diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 00000000..43f480c7 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,18 @@ +# http://editorconfig.org +root = true + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = space +insert_final_newline = true +max_line_length = 120 +trim_trailing_whitespace = true + +[*.md] +max_line_length = 0 +trim_trailing_whitespace = false + +[COMMIT_EDITMSG] +max_line_length = 0 diff --git a/.github/main.workflow b/.github/main.workflow new file mode 100644 index 00000000..e6781473 --- /dev/null +++ b/.github/main.workflow @@ -0,0 +1,15 @@ +workflow "Hyperion" { + on = "push" + resolves = ["Yarn tests"] +} + +action "Yarn install" { + uses = "docker://node:8" + args = "yarn install" +} + +action "Yarn tests" { + uses = "docker://node:8" + args = "yarn test" + needs = ["Yarn install"] +} diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 00000000..14b8177a --- /dev/null +++ b/.prettierrc @@ -0,0 +1,3 @@ +singleQuote: true +trailingComma: es5 +printWidth: 120 diff --git a/__tests__/process/fixtures/0001.json b/__tests__/process/fixtures/0001.json index 665340a2..60d90b94 100644 --- a/__tests__/process/fixtures/0001.json +++ b/__tests__/process/fixtures/0001.json @@ -5,7 +5,11 @@ ], "id": "https://example.org/iiif/book1/manifest", "type": "Manifest", - "label": { "en": [ "Image 1" ] }, + "label": { + "en": [ + "Image 1" + ] + }, "items": [ { "id": "https://example.org/iiif/book1/canvas/p1", diff --git a/__tests__/process/fixtures/0001.ts b/__tests__/process/fixtures/0001.ts new file mode 100644 index 00000000..e7015a2a --- /dev/null +++ b/__tests__/process/fixtures/0001.ts @@ -0,0 +1,10 @@ +import { Manifest } from '../../../src'; +import json from './0001.json'; + +describe('process/fixtures/0001', () => { + test('fixture is correctly typed', () => { + const manifest: Manifest = json as Manifest; + + expect(manifest).toBeDefined(); + }); +}); diff --git a/__tests__/types/resources/annotation.ts b/__tests__/types/resources/annotation.ts index bc79ca11..30812d9a 100644 --- a/__tests__/types/resources/annotation.ts +++ b/__tests__/types/resources/annotation.ts @@ -1,576 +1,566 @@ -import {Annotation} from '../../../src/types/resources/annotation'; +import { Annotation } from '../../../src/types/resources/annotation'; describe('types/resources/annotations', () => { + test('it passes fixtures from W3C', () => { + const fixtures: Annotation[] = [ + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno1', + type: 'Annotation', + body: 'http://example.org/post1', + target: 'http://example.com/page1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno2', + type: 'Annotation', + body: { + id: 'http://example.org/analysis1.mp3', + format: 'audio/mpeg', + language: 'fr', + }, + target: { + id: 'http://example.gov/patent1.pdf', + format: 'application/pdf', + language: ['en', 'ar'], + textDirection: 'ltr', + processingLanguage: 'en', + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno3', + type: 'Annotation', + body: { + id: 'http://example.org/video1', + type: 'Video', + }, + target: { + id: 'http://example.org/website1', + type: 'Text', + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno4', + type: 'Annotation', + body: 'http://example.org/description1', + target: { + id: 'http://example.com/image1#xywh=100,100,300,300', + type: 'Image', + format: 'image/jpeg', + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno5', + type: 'Annotation', + body: { + type: 'TextualBody', + value: "
j'adore !
", + format: 'text/html', + language: 'fr', + }, + target: 'http://example.org/photo1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno6', + type: 'Annotation', + bodyValue: 'Comment text', + target: 'http://example.org/target1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno7', + type: 'Annotation', + body: { + type: 'TextualBody', + value: 'Comment text', + format: 'text/plain', + }, + target: 'http://example.org/target1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno8', + type: 'Annotation', + target: 'http://example.org/ebook1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno9', + type: 'Annotation', + body: [ + 'http://example.org/description1', + { + type: 'TextualBody', + value: 'tag1', + }, + ], + target: ['http://example.org/image1', 'http://example.org/image2'], + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno10', + type: 'Annotation', + body: { + type: 'Choice', + items: [ + { + id: 'http://example.org/note1', + language: 'en', + }, + { + id: 'http://example.org/note2', + language: 'fr', + }, + ], + }, + target: 'http://example.org/website1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno11', + type: 'Annotation', + motivation: 'commenting', + body: { + type: 'TextualBody', + value: 'These pages together provide evidence of the conspiracy', + }, + target: { + type: 'Composite', + items: ['http://example.com/page1', 'http://example.org/page6', 'http://example.net/page4'], + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno12', + type: 'Annotation', + motivation: 'tagging', + body: { + type: 'TextualBody', + value: 'important', + }, + target: { + type: 'List', + items: [ + 'http://example.com/book/page1', + 'http://example.com/book/page2', + 'http://example.com/book/page3', + 'http://example.com/book/page4', + ], + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno13', + type: 'Annotation', + motivation: 'classifying', + body: 'http://example.org/vocab/art/portrait', + target: { + type: 'Independents', + items: [ + 'http://example.com/image1', + 'http://example.net/image2', + 'http://example.com/image4', + 'http://example.org/image9', + ], + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno14', + type: 'Annotation', + creator: 'http://example.org/user1', + created: '2015-01-28T12:00:00Z', + modified: '2015-01-29T09:00:00Z', + generator: 'http://example.org/client1', + generated: '2015-02-04T12:00:00Z', + body: { + id: 'http://example.net/review1', + creator: 'http://example.net/user2', + created: '2014-06-02T17:00:00Z', + }, + target: 'http://example.com/restaurant1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno15', + type: 'Annotation', + creator: { + id: 'http://example.org/user1', + type: 'Person', + name: 'My Pseudonym', + nickname: 'pseudo', + email_sha1: '58bad08927902ff9307b621c54716dcc5083e339', + }, + generator: { + id: 'http://example.org/client1', + type: 'Software', + name: 'Code v2.1', + homepage: 'http://example.org/client1/homepage1', + }, + body: 'http://example.net/review1', + target: 'http://example.com/restaurant1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno16', + type: 'Annotation', + audience: { + id: 'http://example.edu/roles/teacher', + type: 'schema:EducationalAudience', + 'schema:educationalRole': 'teacher', + }, + body: 'http://example.net/classnotes1', + target: 'http://example.com/textbook1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno17', + type: 'Annotation', + motivation: 'commenting', + body: 'http://example.net/comment1', + target: { + id: 'http://example.com/video1', + type: 'Video', + accessibility: 'captions', + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno18', + type: 'Annotation', + motivation: 'bookmarking', + body: [ + { + type: 'TextualBody', + value: 'readme', + purpose: 'tagging', + }, + { + type: 'TextualBody', + value: 'A good description of the topic that bears further investigation', + purpose: 'describing', + }, + ], + target: 'http://example.com/page1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno19', + type: 'Annotation', + rights: 'https://creativecommons.org/publicdomain/zero/1.0/', + body: { + id: 'http://example.net/review1', + rights: 'http://creativecommons.org/licenses/by-nc/4.0/', + }, + target: 'http://example.com/product1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno20', + type: 'Annotation', + canonical: 'urn:uuid:dbfb1861-0ecf-41ad-be94-a584e5c4f1df', + via: 'http://other.example.org/anno1', + body: { + id: 'http://example.net/review1', + rights: 'http://creativecommons.org/licenses/by/4.0/', + }, + target: 'http://example.com/product1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno21', + type: 'Annotation', + body: { + type: 'SpecificResource', + purpose: 'tagging', + source: 'http://example.org/city1', + }, + target: { + id: 'http://example.org/photo1', + type: 'Image', + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno22', + type: 'Annotation', + body: { + source: 'http://example.org/page1', + selector: 'http://example.org/paraselector1', + }, + target: { + source: 'http://example.com/dataset1', + selector: 'http://example.org/dataselector1', + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno23', + type: 'Annotation', + body: { + source: 'http://example.org/video1', + purpose: 'describing', + selector: { + type: 'FragmentSelector', + conformsTo: 'http://www.w3.org/TR/media-frags/', + value: 't=30,60', + }, + }, + target: 'http://example.org/image1', + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno24', + type: 'Annotation', + body: 'http://example.org/note1', + target: { + source: 'http://example.org/page1.html', + selector: { + type: 'CssSelector', + value: '#elemid > .elemclass + p', + }, + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno25', + type: 'Annotation', + body: 'http://example.org/note1', + target: { + source: 'http://example.org/page1.html', + selector: { + type: 'XPathSelector', + value: '/html/body/p[2]/table/tr[2]/td[3]/span', + }, + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno26', + type: 'Annotation', + body: 'http://example.org/comment1', + target: { + source: 'http://example.org/page1', + selector: { + type: 'TextQuoteSelector', + exact: 'anotation', + prefix: 'this is an ', + suffix: ' that has some', + }, + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno27', + type: 'Annotation', + body: 'http://example.org/review1', + target: { + source: 'http://example.org/ebook1', + selector: { + type: 'TextPositionSelector', + start: 412, + end: 795, + }, + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno28', + type: 'Annotation', + body: 'http://example.org/note1', + target: { + source: 'http://example.org/diskimg1', + selector: { + type: 'DataPositionSelector', + start: 4096, + end: 4104, + }, + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno29', + type: 'Annotation', + body: 'http://example.org/road1', + target: { + source: 'http://example.org/map1', + selector: { + id: 'http://example.org/svg1', + type: 'SvgSelector', + }, + }, + }, + { + '@context': 'http://www.w3.org/ns/anno.jsonld', + id: 'http://example.org/anno30', + type: 'Annotation', + body: 'http://example.org/road1', + target: { + source: 'http://example.org/map1', + selector: { + type: 'SvgSelector', + value: 'j\'adore !
', - format : 'text/html', - language : 'fr', - }, - 'target': 'http://example.org/photo1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno6', - 'type': 'Annotation', - 'bodyValue': 'Comment text', - 'target': 'http://example.org/target1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno7', - 'type': 'Annotation', - 'body': { - type: 'TextualBody', - value: 'Comment text', - format: 'text/plain', - }, - 'target': 'http://example.org/target1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno8', - 'type': 'Annotation', - 'target': 'http://example.org/ebook1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno9', - 'type': 'Annotation', - 'body': [ - 'http://example.org/description1', - { - type: 'TextualBody', - value: 'tag1', - }, - ], - 'target': [ - 'http://example.org/image1', - 'http://example.org/image2', - ], - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno10', - 'type': 'Annotation', - 'body': { - type: 'Choice', - items: [ - { - id: 'http://example.org/note1', - language: 'en', - }, - { - id: 'http://example.org/note2', - language: 'fr', - }, - ], - }, - 'target': 'http://example.org/website1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno11', - 'type': 'Annotation', - 'motivation': 'commenting', - 'body': { - type: 'TextualBody', - value: 'These pages together provide evidence of the conspiracy', - }, - 'target': { - type: 'Composite', - items: [ - 'http://example.com/page1', - 'http://example.org/page6', - 'http://example.net/page4', - ], - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno12', - 'type': 'Annotation', - 'motivation': 'tagging', - 'body': { - type: 'TextualBody', - value: 'important', - }, - 'target': { - type: 'List', - items: [ - 'http://example.com/book/page1', - 'http://example.com/book/page2', - 'http://example.com/book/page3', - 'http://example.com/book/page4', - ], - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno13', - 'type': 'Annotation', - 'motivation': 'classifying', - 'body': 'http://example.org/vocab/art/portrait', - 'target': { - type: 'Independents', - items: [ - 'http://example.com/image1', - 'http://example.net/image2', - 'http://example.com/image4', - 'http://example.org/image9', - ], - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno14', - 'type': 'Annotation', - 'creator': 'http://example.org/user1', - 'created': '2015-01-28T12:00:00Z', - 'modified': '2015-01-29T09:00:00Z', - 'generator': 'http://example.org/client1', - 'generated': '2015-02-04T12:00:00Z', - 'body': { - id: 'http://example.net/review1', - creator: 'http://example.net/user2', - created: '2014-06-02T17:00:00Z', - }, - 'target': 'http://example.com/restaurant1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno15', - 'type': 'Annotation', - 'creator': { - id: 'http://example.org/user1', - type: 'Person', - name: 'My Pseudonym', - nickname: 'pseudo', - email_sha1: '58bad08927902ff9307b621c54716dcc5083e339', - }, - 'generator': { - id: 'http://example.org/client1', - type: 'Software', - name: 'Code v2.1', - homepage: 'http://example.org/client1/homepage1', - }, - 'body': 'http://example.net/review1', - 'target': 'http://example.com/restaurant1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno16', - 'type': 'Annotation', - 'audience': { - 'id': 'http://example.edu/roles/teacher', - 'type': 'schema:EducationalAudience', - 'schema:educationalRole': 'teacher', - }, - 'body': 'http://example.net/classnotes1', - 'target': 'http://example.com/textbook1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno17', - 'type': 'Annotation', - 'motivation': 'commenting', - 'body': 'http://example.net/comment1', - 'target': { - id: 'http://example.com/video1', - type: 'Video', - accessibility: 'captions', - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno18', - 'type': 'Annotation', - 'motivation': 'bookmarking', - 'body': [ - { - type: 'TextualBody', - value: 'readme', - purpose: 'tagging', - }, - { - type: 'TextualBody', - value: 'A good description of the topic that bears further investigation', - purpose: 'describing', - }, - ], - 'target': 'http://example.com/page1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno19', - 'type': 'Annotation', - 'rights': 'https://creativecommons.org/publicdomain/zero/1.0/', - 'body': { - id: 'http://example.net/review1', - rights: 'http://creativecommons.org/licenses/by-nc/4.0/', - }, - 'target': 'http://example.com/product1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno20', - 'type': 'Annotation', - 'canonical': 'urn:uuid:dbfb1861-0ecf-41ad-be94-a584e5c4f1df', - 'via': 'http://other.example.org/anno1', - 'body': { - id: 'http://example.net/review1', - rights: 'http://creativecommons.org/licenses/by/4.0/', - }, - 'target': 'http://example.com/product1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno21', - 'type': 'Annotation', - 'body': { - type: 'SpecificResource', - purpose: 'tagging', - source: 'http://example.org/city1', - }, - 'target': { - id: 'http://example.org/photo1', - type: 'Image', - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno22', - 'type': 'Annotation', - 'body': { - source: 'http://example.org/page1', - selector: 'http://example.org/paraselector1', - }, - 'target': { - source: 'http://example.com/dataset1', - selector: 'http://example.org/dataselector1', - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno23', - 'type': 'Annotation', - 'body': { - source: 'http://example.org/video1', - purpose: 'describing', - selector: { - type: 'FragmentSelector', - conformsTo: 'http://www.w3.org/TR/media-frags/', - value: 't=30,60', - }, - }, - 'target': 'http://example.org/image1', - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno24', - 'type': 'Annotation', - 'body': 'http://example.org/note1', - 'target': { - source: 'http://example.org/page1.html', - selector: { - type: 'CssSelector', - value: '#elemid > .elemclass + p', - }, - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno25', - 'type': 'Annotation', - 'body': 'http://example.org/note1', - 'target': { - source: 'http://example.org/page1.html', - selector: { - type: 'XPathSelector', - value: '/html/body/p[2]/table/tr[2]/td[3]/span', - }, - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno26', - 'type': 'Annotation', - 'body': 'http://example.org/comment1', - 'target': { - source: 'http://example.org/page1', - selector: { - type: 'TextQuoteSelector', - exact: 'anotation', - prefix: 'this is an ', - suffix: ' that has some', - }, - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno27', - 'type': 'Annotation', - 'body': 'http://example.org/review1', - 'target': { - source: 'http://example.org/ebook1', - selector: { - type: 'TextPositionSelector', - start: 412, - end: 795, - }, - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno28', - 'type': 'Annotation', - 'body': 'http://example.org/note1', - 'target': { - source: 'http://example.org/diskimg1', - selector: { - type: 'DataPositionSelector', - start: 4096, - end: 4104, - }, - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno29', - 'type': 'Annotation', - 'body': 'http://example.org/road1', - 'target': { - source: 'http://example.org/map1', - selector: { - id: 'http://example.org/svg1', - type: 'SvgSelector', - }, - }, - }, - { - '@context': 'http://www.w3.org/ns/anno.jsonld', - 'id': 'http://example.org/anno30', - 'type': 'Annotation', - 'body': 'http://example.org/road1', - 'target': { - source: 'http://example.org/map1', - selector: { - type: 'SvgSelector', - value: 'From:
Rights: Photo: © Bodleian Libraries, University of Oxford
Terms of Access: http://digital.bodleian.ox.ac.uk/terms.html
First-class public rooms were located in the centre of the ship – the most stable and comfortable areas on board. The Aquitania's opulent interiors were inspired by classical architecture – spot the Ionic columns in the lounge. Architect Arthur Davis recommended the use of plaster and papier-mâché for ceilings, domes, and other decorative moulding, but advised against using marble and brickwork, as these would make the ship top-heavy.
Photograph from The New Art of Going Abroad, 1929, US. National Art Library: 38041986015030. © Victoria and Albert Museum, London
“As cool, as restful, as any terrace overlooking a rose-garden.” (The New Art of Going Abroad, 1929). Overlooking the sea and decorated with palms, the garden lounge was a fashionable place to have tea and was sometimes used for dancing.
Photograph from The New Art of Going Abroad, 1929, US. National Art Library: 38041986015030. © Victoria and Albert Museum, London
Dining on ocean liners was a radically different experience depending on the class of travel. In first class, the Aquitania’s Louis XVI-style dining room offered seating in small isolated groups, echoing elegant restaurants on land. The ship’s architect, Arthur Davis, explained that a “cheerful room with comfortable surroundings” was a necessary distraction from “the often very unpleasant conditions” at sea.
Photograph from The New Art of Going Abroad, 1929, US. National Art Library: 38041986015030. © Victoria and Albert Museum, London
The Aquitania’s first-class cabins were designed by architect Arthur Davis, whose firm, Mewès and Davis Architects, had decorated the famously opulent Ritz hotels in Paris and London. The cabins were “as spacious as a bedroom at the Ritz or the Barclay. The walls are panelled in grey silk. The carpets are vibrant blue and yellow, as are also the striped silk chair coverings. Note the bath – just off-stage, and the electric heater”. (The New Art of Going Abroad, 1929).
Photograph from The New Art of Going Abroad, 1929, US. National Art Library: 38041986015030. © Victoria and Albert Museum, London
While extravagant dishes and refined delicacies were served in first class, third-class meals were less sophisticated. A third-class lunch on a Cunard ship in the 1920s could include rice soup, boiled haddock or braised beef with cabbage, boiled potatoes, bread and ‘cabin biscuits’, followed by bread and butter pudding. To save space, passengers sat at long communal tables on chairs bolted to the floor, in case of bad weather.
Liners were strictly organised spaces which reflected social hierarchies. Although people travelling in third class could account for 60% of the total number of passengers, they were segregated into a relatively small space in the lower decks of the ship, close to the noisy engine room. These four-berth rooms had none of the luxurious furnishings or fabrics found in first class, but they were an improvement on the communal sleeping quarters provided for steerage-class passengers on earlier liners.
In 1919 the Aquitania was refitted and converted from coal-burning to oil-burning engines, which meant fewer crew were required to labour in the engine room.
Ocean liners required huge quantities of food, enough for all crew and passengers – the equivalent to feeding a floating city. Cunard catered for varied tastes. Provisions for one trip included 500 sheep kidneys, 400 ox tails, 800 tongues and large quantities of frogs’ legs, as well as geese, turkey, duck, game and “75 heads of cattle and calfs”.
Passengers travelling for weeks or months would bring a huge number of trunks, most of which were kept in the baggage store deep in the hull of the ship. Cabins could only accommodate smaller trunks. Louis Vuitton designed the ‘steamer trunk’ specifically to fit under a first-class cabin bed. The baggage store was opened daily so that maids or stewards could collect personal items that were needed during the voyage.
The second-class spaces, like first class, were decorated in a neo-classical style. “The second-class accommodation on the vessel, though not so sumptuous as the first-class, is still very elaborate and comfortable”, explained the architect. “The dining-room, no less than 104 ft in length and extending across the whole width of the ship, is decorated with paintings adapted from panels by Pergolesi”– the 18th-century decorative artist. (Arthur Davis, The Architectural Review, April 1914)
, P> = {
diff --git a/src/types/iiif/technical.ts b/src/types/iiif/technical.ts
index 31902cf7..1fcc65b9 100644
--- a/src/types/iiif/technical.ts
+++ b/src/types/iiif/technical.ts
@@ -1,56 +1,46 @@
-type ResourceType =
- 'Collection' |
- 'Manifest' |
- 'Canvas' |
- 'Annotation' |
- 'AnnotationPage' |
- 'AnnotationCollection' |
- 'Range' |
- 'ContentResource' |
- 'Choice' |
- 'CanvasReference' |
- 'Service';
+export type ResourceType =
+ | 'Collection'
+ | 'Manifest'
+ | 'Canvas'
+ | 'Annotation'
+ | 'AnnotationPage'
+ | 'AnnotationCollection'
+ | 'Range'
+ | 'ContentResource'
+ | 'Choice'
+ | 'CanvasReference'
+ | 'Service';
-export enum ViewingDirection {
- LeftToRight = 'left-to-right',
- RightToLeft = 'right-to-left',
- TopToBottom = 'top-to-bottom',
- BottomToTop = 'bottom-to-top',
-}
+export type ViewingDirection = 'left-to-right' | 'right-to-left' | 'top-to-bottom' | 'bottom-to-top';
-export enum SpecificationBehaviours {
- AutoAdvance = 'auto-advance',
- Continuous = 'continuous',
- FacingPages = 'facing-pages',
- Individuals = 'individuals',
- MultiPart = 'multi-part',
- NoNav = 'no-nav',
- NonPaged = 'non-paged',
- Hidden = 'hidden',
- Paged = 'paged',
- Repeat = 'repeat',
- Sequence = 'sequence',
- ThumbnailNav = 'thumbnail-nav',
- Together = 'together',
- Unordered = 'unordered',
-}
+export type SpecificationBehaviours =
+ | 'auto-advance'
+ | 'continuous'
+ | 'facing-pages'
+ | 'individuals'
+ | 'multi-part'
+ | 'no-nav'
+ | 'non-paged'
+ | 'hidden'
+ | 'paged'
+ | 'repeat'
+ | 'sequence'
+ | 'thumbnail-nav'
+ | 'together'
+ | 'unordered';
-export enum SpecificationTimeMode {
- Trim = 'trim',
- Scale = 'scale',
- Loop = 'loop',
-}
+export type SpecificationTimeMode = 'trim' | 'scale' | 'loop';
export type TechnicalProperties = {
- id: string;
- type: ResourceType;
- format: string;
- profile: string;
- height: number;
- width: number;
- duration: number;
- viewingDirection: ViewingDirection;
- behaviour: SpecificationBehaviours[] | string[];
- timeMode: SpecificationTimeMode | string;
- motivation: string;
+ id: string;
+ type: ResourceType;
+ format: string;
+ profile: string;
+ height: number;
+ width: number;
+ duration: number;
+ viewingDirection: ViewingDirection;
+ behaviour: SpecificationBehaviours[] | string[];
+ timeMode: SpecificationTimeMode | string;
+ motivation: string;
};
diff --git a/src/types/reference.ts b/src/types/reference.ts
index 3938a918..f7e0463b 100644
--- a/src/types/reference.ts
+++ b/src/types/reference.ts
@@ -1,6 +1,6 @@
export type Reference