Skip to content

[FEATURE] Add a standalone Basic Viewer#1978

Open
csidirop wants to merge 1 commit into
kitodo:mainfrom
csidirop:feat/default-viewer
Open

[FEATURE] Add a standalone Basic Viewer#1978
csidirop wants to merge 1 commit into
kitodo:mainfrom
csidirop:feat/default-viewer

Conversation

@csidirop

Copy link
Copy Markdown
Contributor

This PR adds a first iteration of a minimal standalone "Basic Viewer". Its design is based on the DFG-Viewer.

viewer

It adds the viewer-facing TypoScript, templates, styling, and documentation needed to render a minimal standalone viewer (and a temporary (?) landing page independently).

Changes

  • adds a dedicated BasicViewer TypoScript set
  • adds a (temporary?) landing page and viewer shell
    • The landing page is intentionally provisional and should be reviewed for direction. It found it helpful to have a landing page to test the viewer and to have a place to link to from the viewer when no manifest is loaded, but it may not be necessary or desirable in the long or even short term. Maybe thats more something for the DFG-Viewer as thats more of a use case for them? Open for discussion. Easy too remove if we decide we don't need it.
  • adds the dedicated default viewer styling
  • adds documentation for the manual viewer setup.

This installation already includes a working viewer page and a prepared configuration folder.
</p>

<form class="tx-dlf-default-viewer-input-form" action="{f:uri.page(pageUid: viewerPid)}" method="get" onsubmit="var input=this.querySelector('input[name='tx_dlf[id]']'); if(input){ input.value=input.value.trim(); }">

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure if the value of the onsubmit attribute is valid. The quoting seems a bit weird to me (nested single quotes). Can you verify this works?

@csidirop

csidirop commented May 15, 2026

Copy link
Copy Markdown
Contributor Author

Btw:
The steps to set up the viewer manually in the backend are as follows:

  1. Create a root page (Create a regular page > Edit page properties > Behavior > Use as root page).
  2. Create a TYPO3 site configuration for that root page in Site Management > Sites.
  3. Create these children below the root page:
    • Viewer -> Type: Standard
    • Kitodo Configuration -> Type: Folder
  4. Create a TypoScript template record (sys_template) on the root page:
    • Site Management > TypoScript > [select root page] > Create a root TypoScript record
  5. In that record Edit the whole TypoScript record and under the Tab General:
    • set the title
    • clear any prefilled content in the Setup field
    • set the Constants field to the required values:
      plugin.tx_dlf.persistence.storagePid = <uid of Kitodo Configuration>
      plugin.tx_dlf.basicViewer.rootPid = <uid of root page>
      plugin.tx_dlf.basicViewer.viewerPid = <uid of Viewer page>
      
    • Under the the tab Advanced Options:
      • enable Rootlevel
      • Include TypoScript sets:
        • Basic Configuration
  6. Apply tenant defaults to the configuration folder

@sebastian-meyer sebastian-meyer added the ↷ feature A new feature or enhancement. label Jun 5, 2026
@sebastian-meyer

Copy link
Copy Markdown
Member

Adding @thomaslow for a review, because he is tasked with #1176 and #1177 based on the current main branch. I don't want to interfere with his work by merging this without his approval.

@thomaslow

Copy link
Copy Markdown
Member

@sebastian-meyer Unfortunately, I won't be able to review this PR for some time. I am on vacation starting next week (for 2 weeks), and this week I am already pretty busy and probably won't be able to look into this PR. I haven't started with #1176 and #1177 either.

@sebastian-meyer

Copy link
Copy Markdown
Member

No worries, that's absolutely fine! Have a nice holiday!

Signed-off-by: Christos Sidiropoulos <dev@csidirop.de>
@csidirop csidirop force-pushed the feat/default-viewer branch from 8cdb871 to e2d7fb6 Compare June 25, 2026 16:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

↷ feature A new feature or enhancement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants