Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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 forms/includes/source_list.xbl
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@
<xf:var name="target" select="substring-after(m:relationList/m:relation[@rel='isEmbodimentOf']/@target,'#')"/>
<xf:repeat nodeset="$data-instance//m:workList/m:work/m:expressionList/m:expression[@xml:id!=$target or not($target)]">
<xf:var name="exp" select="@xml:id"/>
<xf:var name="title" select="if (m:titleStmt/m:title/text()) then m:titleStmt/m:title[text()][1] else concat('[',$exp,']')"/>
<xf:var name="title" select="if (m:title/text()) then m:title[text()][1] else concat('[',$exp,']')"/>
<h:div>
<xf:trigger>
<xf:label><xf:output value="$title"/></xf:label>
Expand Down
56 changes: 53 additions & 3 deletions forms/main_form_work.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@
class="input_group">
<h:div>
<xi:include href="includes/input_with_xmllang.xml" parse="xml"/>&#160;
<dcm:element-buttons-typed triggers="all"
nodeset="m:title[@type='main' or not(@type) or @type='']" index="main_titles"
<dcm:element-buttons-typed triggers="up down move copy"
nodeset="m:title[not(@type) or @type='main' or @type='']" index="main_titles"
origin="instance('empty-instance')/m:meiHead/m:workList/m:work/m:title[not(@type)]"/>
<dcm:attribute-editor ref="."/>
</h:div>
Expand Down Expand Up @@ -94,6 +94,25 @@
</h:div>
</xf:repeat>

<xf:group ref=".[m:title[@type='varying_title']]">
<h:div class="blocklabel">Varying title <h:a class="help">&#160;?<h:span
class="comment">A varying title is a title associated with a resource
that is different from the title recorded as the main title, a parallel
title, title supplements, parallel title supplements, earlier main titles,
later main titles, key titles, or short titles.</h:span></h:a>
</h:div>
</xf:group>
<xf:repeat nodeset="m:title[@type='varying_title']" id="varying_title"
class="input_group">
<h:div>
<xi:include href="includes/input_with_xmllang.xml" parse="xml"/>&#160;
<dcm:element-buttons-typed triggers="up down move copy add remove"
nodeset="m:title[@type='varying_title']" index="varying_title"
origin="instance('empty-instance')/m:meiHead/m:workList/m:work/m:title[@type='varying_title']"/>
<dcm:attribute-editor ref="."/>
</h:div>
</xf:repeat>

<xf:group ref=".[m:title[@type='text_source']]">
<h:div class="blocklabel">Text source <h:a class="help">&#160;?<h:span
class="comment">The title of a textual source for a sung or
Expand All @@ -112,12 +131,31 @@
</xf:repeat>


<xf:group ref=".[m:title[@type='other']]">
<h:div class="blocklabel">Other <h:a class="help">&#160;?<h:span
class="comment">A title that cannot be described by the usual type attributes.</h:span></h:a>
</h:div>
</xf:group>
<xf:repeat nodeset="m:title[@type='other']" id="other"
class="input_group">
<h:div>
<xi:include href="includes/input_with_xmllang.xml" parse="xml"/>&#160;
<dcm:element-buttons-typed triggers="up down move copy add remove"
nodeset="m:title[@type='other']" index="other"
origin="instance('empty-instance')/m:meiHead/m:workList/m:work/m:title[@type='other']"/>
<dcm:attribute-editor ref="."/>
</h:div>
</xf:repeat>


<xf:group
ref=".[not(m:title[@type='alternative']
and m:title[@type='subordinate']
and m:title[@type='uniform']
and m:title[@type='original']
and m:title[@type='text_source'])]">
and m:title[@type='varying_title']
and m:title[@type='text_source']
and m:title[@type='other'])]">
<h:div class="vertical_spacer"/>
<h:a class="popup"><h:img
src="{instance('parameters')/dcm:server_name}editor/images/add.gif"
Expand Down Expand Up @@ -147,12 +185,24 @@
origin="instance('empty-instance')/m:meiHead/m:workList/m:work/m:title[@type='original']"
/>
</h:div>
<h:div>
<dcm:create nodeset="m:title[@type='varying_title']"
label="Add varying title"
origin="instance('empty-instance')/m:meiHead/m:workList/m:work/m:title[@type='varying_title']"
/>
</h:div>
<h:div>
<dcm:create nodeset="m:title[@type='text_source']"
label="Add title of text source"
origin="instance('empty-instance')/m:meiHead/m:workList/m:work/m:title[@type='text_source']"
/>
</h:div>
<h:div>
<dcm:create nodeset="m:title[@type='other']"
label="Add other title"
origin="instance('empty-instance')/m:meiHead/m:workList/m:work/m:title[@type='other']"
/>
</h:div>
</h:div>
</h:span></h:a>
</xf:group>
Expand Down
2 changes: 2 additions & 0 deletions forms/model/empty_doc.xml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@
<title type="uniform" xml:lang="en"/>
<title type="original" xml:lang="en"/>
<title type="subordinate" xml:lang="en"/>
<title type="varying_title" xml:lang="en"/>
<title type="text_source" xml:lang="en"/>
<title type="other" xml:lang="en"/>
<contributor>
<persName role="composer"/>
<corpName/>
Expand Down