Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
256 commits
Select commit Hold shift + click to select a range
7efa12d
fix: adjust object description
tuurma Sep 5, 2025
7943d33
fix: provenance
tuurma Sep 5, 2025
6e2b145
fix: get transmission out of provenance
tuurma Sep 5, 2025
89eee49
fix: text description
tuurma Sep 5, 2025
aaa0b2c
chore: formatting changes
tuurma Sep 5, 2025
64374f0
fix: bibliography bindings
tuurma Sep 5, 2025
a17387e
fix: remove verification from previous position
tuurma Sep 5, 2025
4e59153
fix: move transmission to new bibliography location
tuurma Sep 5, 2025
7334b41
chore: small label changes
tuurma Sep 5, 2025
849bd22
fix: big part of msPart removal
tuurma Sep 5, 2025
9218776
fix: `citedRange` must not be used inside `ref` in commentary
tuurma Sep 5, 2025
e19b9e5
feat: templates for editor, language, respStmt
tuurma Sep 5, 2025
db34eaf
feat: separately collapsible reference sections
tuurma Sep 5, 2025
b5bd1df
fix: remove add fragment button from the main form
tuurma Sep 5, 2025
9978668
fix: add navigation to language section
tuurma Sep 5, 2025
293c827
fix: verification
tuurma Sep 5, 2025
e163a79
fix: remove border from fx-groups
tuurma Sep 6, 2025
5eb0bb0
fix: cleanup templates
tuurma Sep 6, 2025
1c4e2d4
fix: simplify preprocessing
tuurma Sep 6, 2025
ffdd7fe
fix: edition text and commentary sections
tuurma Sep 6, 2025
5ed1d80
feat: adjust readme
tuurma Sep 6, 2025
99ae7e9
chore: run lint + format on all files
DrRataplan Sep 24, 2025
4e58529
fix(edit): add groups to avoid repeating paths and //
DrRataplan Sep 24, 2025
0a0c166
chore(deps): upgrade fore to fix whitespace issues
DrRataplan Sep 24, 2025
d045dc9
fix(edit): fix group nesting
DrRataplan Sep 24, 2025
0a0e116
fix(edit): add nested groups for physDesc subsections (part1)
tuurma Sep 24, 2025
70386d9
fix(edit): rationalize inscription field
tuurma Sep 24, 2025
3b55444
fix(edit): rationalize text description
tuurma Sep 24, 2025
c1352ea
fix(edit): rationalize chronological data bindings
tuurma Sep 24, 2025
fc6c6d2
fix(xml-editor): do not repeat the toolbar for every xml editor
DrRataplan Sep 24, 2025
5e5318b
fix(edit): rationalize history
tuurma Sep 24, 2025
2e5948b
fix(edit): rationalize orig Dates
tuurma Sep 24, 2025
50d36ff
fix(edit): avoid // in body ref
tuurma Sep 24, 2025
177f959
fix(edit): rationalize idno (avoid //)
tuurma Sep 24, 2025
807913d
fix(edit): labels for dropdowns MUST NOT have whitespace
tuurma Sep 26, 2025
59dbb7f
fix(edit): add prettier ignore comment and change printwidth
DrRataplan Sep 26, 2025
818a6f0
fix(edit): label for the identifier(s) section
tuurma Sep 26, 2025
844ec36
fix(edit): move material etc to the requested position
tuurma Sep 26, 2025
3f97857
fix(edit): take material out of details section; present the same as …
tuurma Sep 26, 2025
6706159
fix(edit): correct navigation links and anchors
tuurma Sep 26, 2025
98cede3
fix(edit): language section
tuurma Sep 26, 2025
effa4d4
fix(edit): dropdowns options part1
tuurma Sep 26, 2025
f35b58d
fix(edit): move fragments placeholder in the nav bar down
tuurma Sep 26, 2025
f72829a
chore(formatting): fix a load of self-closing and other linting errors
DrRataplan Sep 30, 2025
7762815
chore(formatting): fix more formatting issues
DrRataplan Sep 30, 2025
769a871
chore(formatting): add linting to CI
DrRataplan Sep 30, 2025
3cd5eba
fix(syntax): correct DOCTYPE
tuurma Oct 2, 2025
c6abce4
chore(ci): add Cypress E2E tests
DrRataplan Oct 1, 2025
1d2417c
fix(id): fix id in example place document
DrRataplan Oct 1, 2025
5250c37
chore: fix doctype declarations
DrRataplan Oct 1, 2025
387e14d
chore: linting
DrRataplan Oct 2, 2025
8691db6
basic page structure and layout
JoernT Oct 2, 2025
09946f2
group padding
JoernT Oct 2, 2025
84ddba9
restructured and modularized sections into separate files, basic styling
JoernT Oct 2, 2025
f222a3b
a draft API for Zotero catching the use cases from current form plus …
JoernT Oct 6, 2025
80995a4
fix: api endpoint
tuurma Oct 7, 2025
af72f03
fix(places): make place form part work with country.xml
DrRataplan Oct 7, 2025
297ee7a
chore(fore-next): make wait-for work by passing the correct selector
DrRataplan Oct 7, 2025
f205d19
fix(edit): adapt to using province.xml
DrRataplan Oct 7, 2025
9914a5d
chore(e2e): fix cypress screenshot folder location
DrRataplan Oct 7, 2025
1c6dd37
chore(test): handle uncaught bogus errors from jinn-codemirror
DrRataplan Oct 7, 2025
e7e65ff
bump version and switch to lib 6.0.1
tuurma Oct 7, 2025
dbda12a
chore(test): increase timeout for e2e tests
DrRataplan Oct 8, 2025
d55fdf2
chore(deps): remove unused npm start script and unused deps
DrRataplan Oct 8, 2025
a9ffbba
feat: repoint zotero reference to bibl/@corresp
tuurma Oct 8, 2025
0f29a71
feat: repoint zotero to bibl/@corresp for all subsections
tuurma Oct 8, 2025
ee9c548
a draft API for Zotero catching the use cases from current form plus …
JoernT Oct 8, 2025
78c8038
added zotero config parameters
JoernT Oct 9, 2025
36aa689
creating zotero cache collections in post-install (edep-data needs to…
JoernT Oct 9, 2025
de8cfb6
fixing permissions for meta.json file
JoernT Oct 9, 2025
e146845
fix the group number
JoernT Oct 9, 2025
deba36c
wip: but basic sync running, problems with updating meta.json
JoernT Oct 9, 2025
d49cdc5
added zotero api with endpoint in custom-api. Syncs items to edep-dat…
JoernT Oct 9, 2025
1bfe92b
cleanup
JoernT Oct 10, 2025
b375fa8
needs an re-index
JoernT Oct 10, 2025
b59f658
added config param for 'style' param, including bib in cached data
JoernT Oct 10, 2025
e5397db
return proper json (bit hacky to circumwent roaster here)
JoernT Oct 10, 2025
c3e7452
implemenation of new zotero search endpoint against locally stored items
JoernT Oct 10, 2025
8bffc43
refactored parameter name
JoernT Oct 11, 2025
2898ed6
implemented api/zotero/items/bib endpoint, simple test page zotero.ht…
JoernT Oct 11, 2025
1313780
autosuggest component, suggest endpoint
JoernT Oct 11, 2025
7117cf1
new matching rule in controller to make sure we get proper doctype ht…
JoernT Oct 13, 2025
560a580
new zotero-autocomplete component inkl. testpage with Fore binding
JoernT Oct 13, 2025
44a8d4f
syncing as xml also and searching on that.
JoernT Oct 13, 2025
c5388c4
cleanup
JoernT Oct 15, 2025
025cda6
sync both json + xml, cleaned up
JoernT Oct 15, 2025
6afcda8
works without bib endpoint
JoernT Oct 16, 2025
66b4594
works without bib endpoint
JoernT Oct 16, 2025
0849606
works without bib endpoint
JoernT Oct 16, 2025
6d198c4
works without bib endpoint
JoernT Oct 16, 2025
37d4d98
fixed component again to use tag instead of key
JoernT Oct 16, 2025
e03f8a5
fixes + integration in bibliography.html
JoernT Oct 16, 2025
972adeb
delete bib endpoint (not needed any more), moved sync to api.json as …
JoernT Oct 16, 2025
4666fe2
label
JoernT Oct 17, 2025
996f56c
bib endpoint handler deleted (not needed any more)
JoernT Oct 17, 2025
e36fc64
zotero sync page to trigger from client
JoernT Oct 17, 2025
706d7cf
moved sync endpoint back to custom-api.json
JoernT Oct 17, 2025
8f7418f
changed to use new component
JoernT Oct 17, 2025
0519f47
fix(jinn-xml): configuration for citedRange as seg in Apparatus
tuurma Oct 20, 2025
caef90c
fix: correct ligature in the template
tuurma Oct 20, 2025
98965c1
fix(languages): use language definitions from the data package
tuurma Oct 20, 2025
4f91391
feat(edit): editor as repeatable section; fix #31
tuurma Oct 20, 2025
f32a615
feat(edit): reorganize Editing section; fix i18n
tuurma Oct 20, 2025
a6083d0
added layout neutral group style
JoernT Nov 6, 2025
514c141
flattened section structure and adapted navigation accordingly
JoernT Nov 6, 2025
cfd277c
fixed missing jumpmarks and order; refined nav
JoernT Nov 6, 2025
661df2e
rather instant scrolling
JoernT Nov 6, 2025
c37b160
fixing imports
JoernT Nov 6, 2025
c6d709e
feat(taxonomy): adjust to changed taxonomy locations
tuurma Nov 6, 2025
a60f3ed
fixes id clash
JoernT Nov 6, 2025
e061f7f
fix(dropdowns): decor dropdown repointed to taxonomy
tuurma Nov 7, 2025
dc43b43
fix(edit): sort drop-down options by catDesc
tuurma Nov 7, 2025
2b5a4c4
fix(edit): add default tei namespace for dropdown options
tuurma Nov 7, 2025
4809f83
fix(edit): repoint objectdesc dropdowns and checkboxes
tuurma Nov 7, 2025
576d6c5
fix(edit): paleography
tuurma Nov 7, 2025
8fbc4cd
feat(edit): text-description
tuurma Nov 7, 2025
f33f254
feat(edit): language
tuurma Nov 9, 2025
e8fb674
feat(edit): verification taxonomy
tuurma Nov 9, 2025
5f5c61e
fix(edit): replace current language lookup with fx-var use
tuurma Nov 11, 2025
ae3390d
feat(edit): editor roles from taxonomy
tuurma Nov 11, 2025
a20b489
fix(edit): avoid duplicate ids
tuurma Nov 11, 2025
1a5d191
Merge branch 'altered-model' into taxonomies
tuurma Nov 11, 2025
8e9e4f6
Merge pull request #43 from eeditiones/taxonomies
tuurma Nov 11, 2025
cbbfd05
feat(edit): publication status from taxonomy
tuurma Nov 11, 2025
725bc78
feat(edit): state of preservation
tuurma Nov 11, 2025
5f9d3b6
fix(edit): religion
tuurma Nov 11, 2025
4882b7c
feat(edit): bibliography to use publication status taxonomy
tuurma Nov 11, 2025
1383941
fix(i18n): remove labels now handled via taxonomy
tuurma Nov 11, 2025
3109272
fix(edit): side navigation
tuurma Nov 11, 2025
cd2ea8f
fix(edit): reinstate expand button
tuurma Nov 11, 2025
5a8112f
feat(edit): add document type instance
tuurma Nov 11, 2025
8bf4d75
fix(edit): tidy up outdated stuff
tuurma Nov 11, 2025
a5cad39
feat(edit): add TEI/@corresp to the document template
tuurma Nov 11, 2025
ff24bae
fix(edit): adjust epidoc-template
tuurma Nov 12, 2025
e539b1f
feat(objectDesc): adjust and reorder
tuurma Nov 12, 2025
8ba0ddf
fix(edit): fix saving transcription
tuurma Nov 13, 2025
b9bc07c
fix(edit): avoid double wrapping with div[type=edition]
tuurma Nov 13, 2025
8961599
feat(edit): letter heights handling
tuurma Nov 13, 2025
1cd8961
feat(epidoc): adjust the template
tuurma Nov 13, 2025
f29f0e7
fix: update jinn-codemirror to 1.17.7
Nov 13, 2025
b3808e3
fix(edit): inventory number address #34
tuurma Nov 13, 2025
106bf94
enable lens for debugging
JoernT Nov 13, 2025
a4303d4
enable lens for debugging
JoernT Nov 13, 2025
7ca7b42
updated Fore bundle
JoernT Nov 13, 2025
81500be
fix(save): preserve notes with no content but non-empty `@corresp`
tuurma Nov 13, 2025
f2c376d
no message
JoernT Nov 13, 2025
3f82e25
some more ignores
JoernT Nov 13, 2025
7f6dd3a
#fixes #33 move picture section out of group and fix context ref
JoernT Nov 13, 2025
d1dec04
fix(save): adjust cleanup odd
tuurma Nov 13, 2025
332c85b
fix(output): adjust paleography lookups
tuurma Nov 13, 2025
31c86bf
fix(output): fix for previous commit
tuurma Nov 13, 2025
1a6660f
feat: update jinn-codemirror to include autocomplete for bibliographi…
Nov 16, 2025
7bf431d
ignore intellij
JoernT Nov 14, 2025
265f367
backoff + totalResults
JoernT Nov 14, 2025
02dfd41
paged loading
JoernT Nov 14, 2025
89de744
first page backoff
JoernT Nov 18, 2025
2334c9c
changed sync endpoint to properly use json output. Increasing backoff…
JoernT Nov 18, 2025
1fd46ab
fix: form order - verification
tuurma Nov 18, 2025
246bff9
fix: form - bibliographical references together and visually hghlighted
tuurma Nov 18, 2025
a035167
fix: move edition&commentary into previous position
tuurma Nov 18, 2025
d404619
fix(edep.odd): lb in line group, persName etc.
Nov 18, 2025
5260e7e
fix: funddatum
tuurma Nov 18, 2025
9c9874a
fix(i18n): labels
tuurma Nov 18, 2025
edb264c
fix: verification binding
tuurma Nov 18, 2025
6abea03
test page
JoernT Nov 18, 2025
af0c091
fix: order in objectdesc
tuurma Nov 18, 2025
c77751e
fix: free-form on decoration
tuurma Nov 18, 2025
999bc32
fix: free form on type of inscription
tuurma Nov 18, 2025
b2972bf
positioning of add buttons for repeats
JoernT Nov 19, 2025
0031791
fix: assure that resp/@when is created if necessary
tuurma Nov 19, 2025
86892fb
fix: on-demand attribute creation for finddate
tuurma Nov 19, 2025
e1e2573
visual grouping of references
JoernT Nov 19, 2025
b410d74
fix: tidyup template
tuurma Nov 19, 2025
c19dfe9
switch language to main
JoernT Nov 19, 2025
966607c
fix: use dropdown for language scope
tuurma Nov 20, 2025
0fb636e
feat: language labels adjusted
tuurma Nov 20, 2025
c9db424
feat: move languages section into text description
tuurma Nov 20, 2025
3a46027
fix: label for references
tuurma Nov 20, 2025
f510468
fix: language add/delete labels
tuurma Nov 20, 2025
cf4ddfc
feat: assure specific order of divs (edition/apparatus/translation/co…
tuurma Nov 20, 2025
4a1e24f
fix: hide nav to language sectoin
tuurma Nov 20, 2025
fc17a24
fix: create attributes on demand
tuurma Nov 20, 2025
147d7a8
feat: on demand creation of elements in location
tuurma Nov 20, 2025
ff50e4e
feat: on demand creation of attributes and simplified template
tuurma Nov 20, 2025
88fed95
feat: on demand creation of attribute nodes
tuurma Nov 20, 2025
e2c75c8
feat: on demand creation of attribute nodes
tuurma Nov 20, 2025
1ad95ed
fix: border on all "references" fields incl dig.images
tuurma Nov 20, 2025
a16a5e3
partial fix for #45
JoernT Nov 24, 2025
39c5115
fixes #45
JoernT Nov 24, 2025
5747370
fix(inscription-field): split up the repeat ref to prevent making mor…
DrRataplan Nov 25, 2025
903b963
fix(create-nodes): turn on create-nodes and use newest fore build
DrRataplan Nov 25, 2025
981a995
fixes #54 display geodata form
JoernT Nov 25, 2025
ac1f161
fix(init): use the epidoc-template.xml as a default instance
DrRataplan Nov 25, 2025
080faa2
fix(load): do not preprocess the document before serving it
DrRataplan Nov 25, 2025
4103cee
chore(dead-code): remove unused api:upload endpoint
DrRataplan Nov 25, 2025
912db23
fix(create-nodes): split up the path for the facsimile group
DrRataplan Nov 26, 2025
e1ccefe
fix: rely on create-nodes to create attributes for digital images on …
tuurma Nov 26, 2025
2c3dac5
chore(dead-code): remove unused var in references
tuurma Nov 26, 2025
979a39c
feat: tidy up templates
tuurma Nov 26, 2025
ab5f9f0
chore(dead-code): remove unused api endpoints for dropdown values
tuurma Nov 26, 2025
209be67
fix(zotero): store zotero entries as TEI; use lucene with no-diacriti…
Nov 26, 2025
1b3d1cc
feat(edit): objectType as repeated element, not space-separated attri…
tuurma Nov 26, 2025
07f9f61
feat(edit): material as repeated element, not space-separated attribu…
tuurma Nov 26, 2025
c9da795
feat(edit): compact findspot and -date together; fix #53
tuurma Nov 28, 2025
94e5096
docs: update readme
tuurma Nov 28, 2025
acc1dcc
fixes #remove popovers from edep-xml-editor elements and moved them t…
JoernT Nov 28, 2025
9fc8e36
proper header levels, added expand collapse for sections, prep for fr…
JoernT Nov 28, 2025
5315aff
get fragments endpoint to list out fragments,
JoernT Nov 28, 2025
5b88311
switch add fragment button readonly until all works
JoernT Nov 28, 2025
f1290ee
fix(edit): adjust language representation
tuurma Nov 28, 2025
86c4f68
fix(edit): correct grouping and scoping to avoid proliferation of phy…
tuurma Nov 28, 2025
869fc9a
fix(edit): prevent proliferation of textClass elements
tuurma Nov 28, 2025
ee00aa5
fix(edit): prevent proliferation of respStmt/resp
tuurma Nov 28, 2025
9240221
fix(edit): inscription field subsection
tuurma Nov 28, 2025
4966507
restyled incl. objectdesc
JoernT Nov 29, 2025
cfa0401
reworked form sections for consistency in layout, grouping some items…
JoernT Nov 29, 2025
8d4694b
Strip diacritics from query string; handle journal, book and series t…
Nov 30, 2025
7f89d8e
Search for tag should now query title[@type='short']. Closes #55
Nov 30, 2025
205f160
test: improve E2E test
DrRataplan Dec 2, 2025
dd8e93b
fixes #51
JoernT Dec 2, 2025
c34a980
fix(edit): correct broken bindings from previous commit; address #51
tuurma Dec 2, 2025
abdc968
fixes #52 - updated Fore to 2.7.0, added script to copy resources,
JoernT Dec 3, 2025
da58fc2
fixes #51 - removed duplicate fieldsets
JoernT Dec 3, 2025
ff9d09b
tiny spacing glitch
JoernT Dec 3, 2025
67ec615
deleted endpoint api/fragments and instead pass the relevant ids down…
JoernT Dec 3, 2025
73e5fb8
updated to patch release Fore 2.7.1
JoernT Dec 4, 2025
5ecc701
updated to patch release Fore 2.7.1
JoernT Dec 4, 2025
4a00811
#fixes #58 - xml:id is now always in sync with edepId
JoernT Dec 5, 2025
a54dfcf
fix(i18n): address 60
tuurma Dec 5, 2025
d398045
fix(i18n): address 60
tuurma Dec 5, 2025
ddb2cd3
Transfer to a forked @codemirror/view to fix a nasty Firefox bug
DrRataplan Dec 5, 2025
bec8a4e
fix(edit): fix units with letter dimensions
tuurma Dec 5, 2025
bd7155c
feat(edit): change inscription type multi-checkbox to tiled repeats
tuurma Dec 6, 2025
bb7b646
feat(edit): Apex button
tuurma Dec 7, 2025
fdc5c59
fix(places): load countries from correct TEI structure; address #59
tuurma Dec 7, 2025
a15a314
fix(places): set current lang in a variable
tuurma Dec 7, 2025
4f0532f
fix(edit): explicitly add attributes to the template, to prevent Fore…
tuurma Dec 8, 2025
a8d120c
chore: update generated
tuurma Dec 8, 2025
347e05b
fixes #63 by adding standalone page for syncing
JoernT Dec 8, 2025
6ea5156
feat(odd): rendering of `gap`s; address #64
tuurma Dec 8, 2025
ebef3e0
fix(odd): correct line breaks before line-width gaps
tuurma Dec 8, 2025
486cb11
fix: extend info text on Zotero sync page
tuurma Dec 8, 2025
ca530d7
fix: url for custom api
tuurma Dec 8, 2025
7807dbd
fix(output): fix some output elements
tuurma Dec 8, 2025
ffc24cf
deps: use [email protected] to fix firefox crash
DrRataplan Dec 9, 2025
7bb7bc2
fix(i18n): en label for ligature(s)
tuurma Dec 9, 2025
9d6e0cd
fix(odd): basic gap handling
tuurma Dec 11, 2025
e11d1da
feat(odd): merge brackets for neighbouring supplied and gaps
tuurma Dec 11, 2025
923d6f0
chore: bump jinn-codemirror to 1.18.2 for fixes re newlines
Dec 11, 2025
43fe658
fix(odd): display gap unit=line quantity as line placeholders with ne…
tuurma Dec 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .devcontainer/Dockerfile.dev
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM mcr.microsoft.com/devcontainers/java:8-bullseye
ARG GITLAB_TOKEN=""
ARG EXIST_VERSION=6.2.0
ARG TEMPLATING_VERSION=1.1.0
ARG PUBLISHER_LIB_VERSION=4.0.0
ARG PUBLISHER_LIB_VERSION=6.0.1
ARG ROUTER_VERSION=1.8.0
ARG EDITOR_VERSION=1.1.0

Expand Down
4 changes: 3 additions & 1 deletion .existdb.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@
"node_modules/**",
"bower_components/**",
"build/**",
"webtest/**"
"webtest/**",
".idea/**",
".DS_Store"
]
},
"package": {
Expand Down
124 changes: 124 additions & 0 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
# This workflow builds a xar archive, deploys it into exist and execute a simple smoke test.

name: Build and Test

on: [push]

jobs:
build:
runs-on: ubuntu-latest
continue-on-error: ${{ matrix.experimental }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

strategy:
fail-fast: false
matrix:
# 7.0.0-SNAPSHOT and 6.4.0 created
exist-version: [6.4.0, release]
java-version: [11]
experimental: [false]
include:
- exist-version: latest
java-version: 21
experimental: true

steps:
# Checkout code
- uses: actions/checkout@v5

# Speed up apt-get installs
- name: Disable man-db to make package install and removal faster
run: |
echo 'set man-db/auto-update false' | sudo debconf-communicate >/dev/null
sudo dpkg-reconfigure man-db

- name: Install Test Dependencies
run: |
sudo apt-get update
sudo apt-get install -y libxml2-utils bats
npm install --global @existdb/xst

# sanity check
- name: Ensure all XML files are well-formed
run: |
xmllint --noout \
$(find . -type f -name '*.xml')

# Build
- name: Install Java
uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: ${{ matrix.java-version }}
- run: ant

- name: Check Contents
working-directory: build/
run: ls

# Install
- name: Start exist-ci containers
run: |
docker run -dit -p 8080:8080 \
--name exist --rm --health-interval=1s --health-start-period=2s \
duncdrum/existdb:${{ matrix.exist-version }}-slim

- name: Wait for server to start
timeout-minutes: 1
run: |
echo "Waiting for server to start..."
until docker logs exist 2>&1 | grep -q "Server has started"; do
echo "Still waiting..."
sleep 4
done

- name: install edep and edep-data
env:
EXISTDB_USER: 'admin'
EXISTDB_PASS: ''
EXISTDB_SERVER: 'http://localhost:8080/'
run: |
xst package install ./dist/*.xar
xst package install github-release edep-data --owner eeditiones

# Test
- name: Run smoke test
run: bats --tap test/*.bats

- name: debug logs
if: failure()
run: docker logs exist | grep 'ERROR'

- name: Copy logs on failure
if: failure()
run: |
echo "Copying logs..."
docker cp exist:/exist/logs/exist.log ./exist.log

- name: Upload logs artifact
if: failure()
uses: actions/upload-artifact@v4
with:
name: edep-exist-${{ matrix.exist-version }}-log
path: exist.log

- name: Run Cypress e2e test
if: matrix.experimental != true
uses: cypress-io/github-action@v6
with:
browser: firefox

- name: Run Cypress e2e test (expect fail)
if: matrix.experimental == true
continue-on-error: true
uses: cypress-io/github-action@v6
with:
browser: firefox

- name: Upload cypress sceenshots
if: failure()
uses: actions/upload-artifact@v4
with:
name: CiM-exist-${{ matrix.exist-version }}-screenshots
path: cypress/screenshots/
11 changes: 11 additions & 0 deletions .github/workflows/linting.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: Linting
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install modules
run: npm i
- name: Run ESLint and Prettier
run: npm run lint
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.idea
.idea/**
build/
dist/
node_modules/
node_modules/
.DS_Store
12 changes: 12 additions & 0 deletions .prettierrc.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/**
* @type {import('prettier').Config}
*/
const config = {
singleQuote: true,
arrowParens: 'avoid',
tabWidth: 4,
printWidth: 120,
bracketSameLine: true,
};

export default config;
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ ENV PATH ${PATH}:${ANT_HOME}/bin
FROM builder as tei

ARG TEMPLATING_VERSION=1.1.0
ARG PUBLISHER_LIB_VERSION=4.0.0
ARG PUBLISHER_LIB_VERSION=6.0.1
ARG ROUTER_VERSION=1.8.1

# add key
Expand Down
52 changes: 33 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@ EDEp implements an editor and toolbox for epigraphic data adhering to the EpiDoc
* web components for transcribing inscriptions using Leiden markup
* components allowing controlled XML editing for specific micro-environments within the larger form
* ODDS based on the TEI Processing Model for output transformations: rather than using hand-written transformations we describe them in a declarative way in TEI itself
* a component for looking up bibliographic references in Zotero
* API for synchronizing Zotero library to the local instance
* a component for looking up bibliographic references in locally cached Zotero

The current state of the application itself should be considered an **early beta**, i.e. fully usable, but still under development.
The current state of the application itself should be considered an **early beta**, i.e. usable, but still under development.
Please report any hiccups via the issue tracker.

## Installation

Expand All @@ -19,7 +21,7 @@ You may either
1. install the application into an existing eXist instance or
2. use the docker image

Using option 1, the application requires at least Java version 8 and eXist version 6.2.0. Details of the installation process are described in the [TEI Publisher documentation](https://tei-publisher.com/exist/apps/tei-publisher/documentation/exist-installation). You may skip the last step: *Installing TEI Publisher*, which is not needed for EDEp, but open the dashboard as described. Next, download the EDEp application and data package from the [GitHub release page](https://github.com/eeditiones/edep/releases). Install those one after the other: either click on the *Upload* button and select the downloaded `edep-*.xar` or drag and drop it onto the button.
Using option 1, the application requires at least Java version 8 and eXist version 6.2.0. Details of the installation process are described in the [TEI Publisher documentation](https://tei-publisher.com/exist/apps/tei-publisher/documentation/exist-installation). You may skip the last step: *Installing TEI Publisher*, which is not needed for EDEp, but open the dashboard as described. Next, download the EDEp application and data package from the [GitHub release page](https://github.com/eeditiones/edep/releases). Install those one after the other: first the data package, then the application itself. Either click on the *Upload* button and select the downloaded `edep-*.xar` or drag and drop it onto the button.

Option 2 is **recommended** for new users and easier if you would like a working environment without having to install Java and eXist. You need docker installed though. Windows and Mac users may download the [docker desktop](https://www.docker.com/products/docker-desktop) application. After install, open a shell and run the following pull command:

Expand Down Expand Up @@ -49,6 +51,14 @@ Log in by clicking the *login* button in the top right corner of the page. The d

![demo collection](doc/edep-demo.png)

## Zotero synchronization

Use the `api.html` to manually trigger Zotero synchronization. It usually takes 2-3 minutes the first time, couple of seconds afterwards.

![zotero-sync](doc/zotero.png)

Read more on this subject in [Zotero cache documentation](doc/zotero-cache.md)

## Customization

**Important note**: just like TEI, EpiDoc is **not** a standard in the sense that there's only one way to encode things. It does not strictly standardize every little detail, but rather tries to provide a common base. Many aspects depend on the concrete research object and will necessarily differ. Therefore you cannot expect that the editor will consume every possible variation of EpiDoc out of the box. It should handle the common denominator, i.e. common parts like titles, transcriptions, translations or commentaries, but may fail to correctly interpret other details of your encoding, which require further customization.
Expand All @@ -60,37 +70,41 @@ Therefore the editor works entirely within the web browser: it only loads the Ep
For example, the form field for the state of preservation is defined in the HTML as follows:

```html
<fx-control ref="physDesc/objectDesc/supportDesc/condition" update-event="input">
<fx-control ref="objectDesc/supportDesc/condition" update-event="input">
<label>
<pb-i18n key="form.preservation">Erhaltung</pb-i18n>
<pb-i18n key="form.preservation"/>
</label>
<select class="widget">
<option value="" data-i18n="form.unknown">unbekannt</option>
<option value="complete" data-i18n="preservation.complete">vollständig</option>
<option value="fragmentary" data-i18n="preservation.fragmentary">fragmentarisch</option>
</select>
<select
ref="instance('preservation')//category"
class="widget">
<template>
<option value="{@xml:id}">{catDesc[@xml:lang = $lang]}</option>
</template>
</select>
</fx-control>
```

HTML elements starting with `fx-` belong to *Fore*, the forms framework. *Fore* was designed to preserve the good parts of the – now outdated – XForms standard and takes them to the next level. As with all powerful tools, it requires a bit of time to fully grasp the concepts and understand how they work together. We suggest to read the [article series](https://medium.com/@joern.turner/fore-elements-explained-part-1-89fc41ec6923), which explains the available elements.

The `@ref` attribute binds the form control to the element selected by the given XPath expression, in this case: `physDesc/objectDesc/supportDesc/condition` within the outer `msPart`. All labels are multi-lingual (German and English) by default, which is why we use the `<pb-i18n>` tag and `data-i18n` attributes to reference translation keys. Translations for all labels can be found in [src/resources/i18n/app](src/resources/i18n/app).
The `@ref` attribute binds the form control to the element selected by the given XPath expression, in this case: `objectDesc/supportDesc/condition`. All labels are multi-lingual (German and English) by default, which is why we use the `<pb-i18n>` tag and to reference translation keys. Translations for all labels can be found in [src/resources/i18n/app](src/resources/i18n/app).

Select options labels are also localized, but since these are read from TEI taxonomies, the lookups search for `catDesc` elements with an `xml:lang` attribute matching the current language (`$lang` in the example above).

The design decision to use `msPart` was made to support inscriptions consisting of multiple fragments on the same object. EDEp therefore distinguishes between properties which apply to the object as a whole and those specific to the inscription. Consequently every EpiDoc document in EDEp has at least one `msPart` for the main inscription. Note however, that support for multiple fragments is still a bit lacking and needs more work.
When creating a new document, the editor starts by loading an empty [EpiDoc template](src/templates/fore/epidoc-template.xml). This contains placeholders for all the elements covered by the form. Some elements, e.g. bibliographic entries, are repeatable, which means you can add more of the same type. Sub-templates for repeat elements and other fragments inserted on demand are located in [templates.xml](src/templates/fore/templates.xml).

When creating a new document, the editor starts by loading an empty [EpiDoc template](src/templates/fore/epidoc-template.xml). This contains placeholders for all the elements covered by the form. Some elements, e.g. bibliographic entries, are repeatable, which means you can add more of the same type. Sub-templates for those elements are mostly located in [templates.xml](src/templates/fore/templates.xml).
The entire pre-processing pipeline is started via `custom-api.xql/api:file-upload` which in turn call on other functions to convert the input.

The form also needs some auxiliary data lists, e.g. for object types, materials and much more, which are mostly loaded from the data package.
The form also needs some auxiliary data lists, e.g. for object types, materials and much more, which are loaded from `data/taxonomy` collection in the data package.

To extend the form to include an additional element or attribute, one would proceed as follows:

1. edit [epidoc-template.xml](src/templates/fore/epidoc-template.xml) and add the missing element or attribute. If it should be part of an `msPart` (i.e. target the inscription), make sure to also modify [mspart-tmpl.xml](src/templates/fore/mspart-tmpl.xml) in the same way. If the element or attribute belongs to a repeatable section, check [templates.xml](src/templates/fore/templates.xml).
2. add a form control to [edit.html](src/templates/edit.html) and bind it to the element/attribute.
1. edit [epidoc-template.xml](src/templates/fore/epidoc-template.xml) and add the missing element or attribute. If the element or attribute belongs to a repeatable section, adjust also [templates.xml](src/templates/fore/templates.xml).
2. add a form control to [edit.html](src/templates/edit.html) or its dynamically imported form fragments and bind it to the element/attribute.

Many fields in the form may contain inline TEI/XML. We have thus developed an XML editor component (based on the excellent codemirror library), which can be plugged into the form to replace any plain-text input field:
Many fields in the form may contain inline TEI/XML. We have therefore developed an XML editor component (based on the codemirror library), which can be plugged into the form to replace any plain-text input field:

```html
<fx-control class="commentary editor" ref="instance('default')//body/div[@type='commentary']" as="node" update-event="blur">
<fx-control class="commentary editor" ref="div[@type='commentary']" as="node" update-event="blur">
<jinn-xml-editor id="commentary" class="widget" unwrap="unwrap" placeholder="[Inline text/markup or sequence of paragraphs]" schema="resources/scripts/tei.json" schema-root="div" namespace="http://www.tei-c.org/ns/1.0">
<div slot="toolbar">
<pb-popover>
Expand Down Expand Up @@ -122,7 +136,7 @@ The editor features context-sensitive suggestions for elements and attributes wh

### Treatment of empty elements/attributes

As explained above, the form works directly on the EpiDoc TEI XML. However, note that missing elements or attributes will be regarded as irrelevant by the form and the corresponding controls will be hidden. This is by design and conceptually an important feature! It is thus required that you **provide an empty placeholder** in the XML templates for every element or attribute to be edited in the form. For example, the template for the `<provenance>` element specifies empty attributes for `when` and `when-custom` even though those are mutually exclusive:
As explained above, the form works directly on the EpiDoc TEI XML. However, real TEI documents will not necessarily contain all potentially possible elements and attributes. In such cases, note that "missing" elements or attributes will be regarded as irrelevant by the form and the corresponding controls will not be shown. This is an element of the Fore design and conceptually an important feature! It is therefore required that **a placeholder** is provided in the XML templates for every element or attribute to be edited in the form or to indicate in the form control that a given attribute should be created on demand. For example, the template for the `<provenance>` element specifies empty attributes for `when` and `when-custom` even though those are mutually exclusive:

```xml
<provenance type="found" when="" when-custom="" notBefore="" notAfter="">
Expand Down
10 changes: 10 additions & 0 deletions cypress.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
const { defineConfig } = require('cypress');

module.exports = defineConfig({
e2e: {
baseUrl: 'http://localhost:8080/exist/apps/edep',
setupNodeEvents(on, config) {
// implement node event listeners here
},
},
});
17 changes: 17 additions & 0 deletions cypress/e2e/smoketest.cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
describe('Smoketest', () => {
it('Can open the edit page', { defaultCommandTimeout: 10000 }, () => {
cy.visit('edit/demo/E0000028.xml');

cy.get('.edepid').should('have.value', 'E0000028');

// There are fragments here
cy.get('#r-fragments a').should('have.length', '2');

// We've seen this option list to break in some cases
cy.get('#findspot-ctrl option')
.should('have.length.of.at.least', 10)
.should('not.contain', '{.}')
.should('not.have.attr', 'value', '{@xml:id}')
.should('contain', 'A');
});
});
5 changes: 5 additions & 0 deletions cypress/fixtures/example.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"name": "Using fixtures to represent data",
"email": "[email protected]",
"body": "Fixtures are a great way to mock data for responses to routes"
}
25 changes: 25 additions & 0 deletions cypress/support/commands.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
// ***********************************************
// This example commands.js shows you how to
// create various custom commands and overwrite
// existing commands.
//
// For more comprehensive examples of custom
// commands please read more here:
// https://on.cypress.io/custom-commands
// ***********************************************
//
//
// -- This is a parent command --
// Cypress.Commands.add('login', (email, password) => { ... })
//
//
// -- This is a child command --
// Cypress.Commands.add('drag', { prevSubject: 'element'}, (subject, options) => { ... })
//
//
// -- This is a dual command --
// Cypress.Commands.add('dismiss', { prevSubject: 'optional'}, (subject, options) => { ... })
//
//
// -- This will overwrite an existing command --
// Cypress.Commands.overwrite('visit', (originalFn, url, options) => { ... })
24 changes: 24 additions & 0 deletions cypress/support/e2e.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
// ***********************************************************
// This example support/e2e.js is processed and
// loaded automatically before your test files.
//
// This is a great place to put global configuration and
// behavior that modifies Cypress.
//
// You can change the location of this file or turn off
// automatically serving support files with the
// 'supportFile' configuration option.
//
// You can read more here:
// https://on.cypress.io/configuration
// ***********************************************************

// Import commands.js using ES2015 syntax:
import './commands';

Cypress.on('uncaught:exception', (err, runnable) => {
if (err.stack.includes('jinn-codemirror-bundle.js')) {
return false;
}
return true;
});
Loading
Loading