Skip to content

Commit

Permalink
update sources preview: creation
Browse files Browse the repository at this point in the history
  • Loading branch information
peterstadler committed Nov 23, 2024
1 parent 0c34406 commit a42b5e4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
4 changes: 2 additions & 2 deletions modules/app.xqm
Original file line number Diff line number Diff line change
Expand Up @@ -1921,8 +1921,8 @@ declare
%templates:wrap
%templates:default("lang", "en")
function app:preview-creation($node as node(), $model as map(*), $lang as xs:string) as xs:string? {
if($model('doc')/mei:manifestation/mei:pubStmt) then string-join($model('doc')/mei:manifestation/mei:pubStmt/*, ', ')
else if($model('doc')//tei:sourceDesc/tei:biblStruct) then bibl:printCitation($model?doc//tei:sourceDesc/tei:biblStruct, <xhtml:span/>, $lang)
if($model('doc')/mei:manifestation/mei:pubStmt) then ( string-join($model('doc')/mei:manifestation/mei:pubStmt/mei:pubPlace, ' &amp; ') || ' ' || $model('doc')/mei:manifestation/mei:pubStmt/mei:date )
else if($model('doc')//tei:sourceDesc/tei:biblStruct) then ( string-join($model('doc')//tei:sourceDesc/tei:biblStruct/tei:monogr/tei:imprint/tei:pubPlace, ' &amp; ') || ' ' || $model('doc')//tei:sourceDesc/tei:biblStruct/tei:monogr/tei:imprint/tei:date )
else if($model('doc')/mei:manifestation/mei:creation) then str:normalize-space($model('doc')/mei:manifestation/mei:creation)
else ()
};
Expand Down
7 changes: 5 additions & 2 deletions templates/includes/preview-sources.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,11 @@
<h3 class="media-heading">
<span data-template="app:preview-title">Source Title</span>
</h3>
<p data-template="app:preview-creation">Augsburg: Benno Filser, 1928</p>
<p data-template="app:preview-teaser">Abschrift im vierstimmigen Satz von Friederike Koch im fragm. Autograph …</p>
<!--<p data-template="app:preview-teaser">Abschrift im vierstimmigen Satz von Friederike Koch im fragm. Autograph …</p>-->
<p>
<strong><span data-template="lang:translate">creation</span>:</strong>
<span data-template="app:preview-creation">Augsburg: Benno Filser, 1928</span>
</p>
<p>
<strong><span data-template="lang:translate">identifier</span>:</strong>
<span data-template="app-shared:print" data-template-key="docID">A030043</span>
Expand Down

0 comments on commit a42b5e4

Please sign in to comment.