From b99e7db21f78e831da44aae54ee8f18d7f270f6b Mon Sep 17 00:00:00 2001 From: Lennard Golsch Date: Thu, 19 Feb 2026 15:49:02 +0100 Subject: [PATCH 1/2] Fix README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 40f901c..66a927c 100644 --- a/README.md +++ b/README.md @@ -55,8 +55,8 @@ For historical reasons, the link to the RSS feed is always displayed, but it can All in all, configure as follows: ```text -# Add 'series-banner' and 'series-layout'. -MIR.Layout.End=mir-edit,series-banner,series-layout,mir-citation,mir-thumbnail,mir-epusta,mir-access-rights,mir-export,mir-admindata,mir-historydata +# Add 'series-layout'. +MIR.Layout.End=mir-edit,series-layout,mir-citation,mir-thumbnail,mir-epusta,mir-access-rights,mir-export,mir-admindata,mir-historydata # Optional: disable RSS feed. MIR.Metadata.Navigation.SeriesPanel.RSS.Enabled=false From db342372667378866317b1c0acf8566cb8a9736b Mon Sep 17 00:00:00 2001 From: Lennard Golsch <36492865+golsch@users.noreply.github.com> Date: Wed, 13 May 2026 17:38:32 +0200 Subject: [PATCH 2/2] Improve MyCoreWebPage support (#20) * Decouple series panel rendering * Add MyCoReWebPage support * Add extended MyCoreWebPage support * Fix README.md --- README.md | 58 +++++++++ .../xsl/navigation-flatmir-layout.xsl | 22 ++-- .../resources/xsl/render-series-panel.xsl | 116 ++++++++++++++++++ .../resources/xsl/series-panel-adapter.xsl | 18 +++ .../resources/xsl/series-panel-enricher.xsl | 26 ++++ src/main/resources/xsl/series-panel.xsl | 116 ++---------------- 6 files changed, 236 insertions(+), 120 deletions(-) create mode 100644 src/main/resources/xsl/render-series-panel.xsl create mode 100644 src/main/resources/xsl/series-panel-adapter.xsl create mode 100644 src/main/resources/xsl/series-panel-enricher.xsl diff --git a/README.md b/README.md index 66a927c..4880edb 100644 --- a/README.md +++ b/README.md @@ -49,6 +49,8 @@ Build the JAR file with `mvn clean install` and copy it to `~/.mycore/(dev-)mir/ ### Configure `mycore.properties` +#### Enable navigation on object pages in frontend + To use the plugin, configuration in `~/.mycore/(dev-)mir/mycore.properties` is required. The RSS feed requires a `mycoreobject-rss` stylesheet, which is not included by default. For historical reasons, the link to the RSS feed is always displayed, but it can be disabled if needed. @@ -62,6 +64,62 @@ MIR.Layout.End=mir-edit,series-layout,mir-citation,mir-thumbnail,mir-epusta,mir- MIR.Metadata.Navigation.SeriesPanel.RSS.Enabled=false ``` +#### MyCoReWebPage support + +The panel can optionally be rendered within a +[MyCoReWebPage](https://www.mycore.de/documentation/frontend/frontend_static_content/). +To enable this, the stylesheet `series-panel-adapter.xsl` is provided. +The panel can be embedded using a `` element in your MyCoReWebPage. +When embedding, pay attention to the layout to ensure the panel is formatted correctly. + +> ⚠️ Note: The parameters `MCRObjectID` and `MCRDerivateID` must be present in the transformer session to resolve the +> navigation. + +To activate it, add the stylesheet as follows: + +```text +# Add 'series-panel-adapter.xsl' to enable series panel rendering in MyCoReWebPage. +MCR.URIResolver.xslIncludes.MyCoReWebPage=%MCR.URIResolver.xslIncludes.MyCoReWebPage%,series-panel-adapter.xsl +``` + +Example MyCoReWebPage with panel and layout: + +```xml + +
+
+
+

Hello world

+
+
+ +
+
+
+
+``` + +#### Extended MyCoReWebPage support + +MyCoReWebPage support can be extended with `series-panel-enricher.xsl`. By setting `render-series-panel="true"` in a +MyCoReWebPage, a series panel with layout is automatically generated, using the section’s content. +To activate it, add the stylesheet alongside `series-panel-adapter.xsl` as follows: + +```text +# Add 'series-panel-enricher.xsl' to enable extended series panel rendering in MyCoReWebPage. +MCR.URIResolver.xslIncludes.MyCoReWebPage=%MCR.URIResolver.xslIncludes.MyCoReWebPage%,series-panel-enricher.xsl,series-panel-adapter.xsl +``` + +Example MyCoReWebPage with automatic panel and layout using `render-series-panel`: + +```xml + +
+

Hello world

+
+
+``` + ### Reload and rebuild Solr The plugin leverages enhanced Solr handling for parent documents. diff --git a/src/main/resources/xsl/navigation-flatmir-layout.xsl b/src/main/resources/xsl/navigation-flatmir-layout.xsl index 759e8e3..1f1e639 100644 --- a/src/main/resources/xsl/navigation-flatmir-layout.xsl +++ b/src/main/resources/xsl/navigation-flatmir-layout.xsl @@ -1,12 +1,7 @@ - - - - + - + @@ -15,24 +10,21 @@ -
-
- - - + + + +
-
-
\ No newline at end of file +
diff --git a/src/main/resources/xsl/render-series-panel.xsl b/src/main/resources/xsl/render-series-panel.xsl new file mode 100644 index 0000000..f45b08b --- /dev/null +++ b/src/main/resources/xsl/render-series-panel.xsl @@ -0,0 +1,116 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + +
+
+

+ +

+
+
+
    + + + + + + + + + + +
+
+ +
+
+
+ + + +
  • + + + + + + + + + + + + +
  • +
    + + + + + + + +
  • + + + RSS 2.0 Feed + +
  • +
    +
    diff --git a/src/main/resources/xsl/series-panel-adapter.xsl b/src/main/resources/xsl/series-panel-adapter.xsl new file mode 100644 index 0000000..85c3836 --- /dev/null +++ b/src/main/resources/xsl/series-panel-adapter.xsl @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/src/main/resources/xsl/series-panel-enricher.xsl b/src/main/resources/xsl/series-panel-enricher.xsl new file mode 100644 index 0000000..38143a9 --- /dev/null +++ b/src/main/resources/xsl/series-panel-enricher.xsl @@ -0,0 +1,26 @@ + + + + + +
    +
    + +
    +
    + +
    +
    +
    + +
    + + + +
    +
    + +
    diff --git a/src/main/resources/xsl/series-panel.xsl b/src/main/resources/xsl/series-panel.xsl index 42aa5c3..6fe1c08 100644 --- a/src/main/resources/xsl/series-panel.xsl +++ b/src/main/resources/xsl/series-panel.xsl @@ -1,119 +1,25 @@ - - - - - - - + exclude-result-prefixes="xlink"> + + + - + - - - - - - - - -
    - - - - - -
    -
    -

    - -

    -
    - -
    -
      - - - - - - -
    -
    - - - -
    -
    -
    - - - - -
  • - - - -
  • -
    - -
  • - - - -
  • -
    -
    -
    - - - - - - - - -
  • - - - RSS 2.0 Feed - -
  • -
    -