annotate zpt/common_template.zpt @ 531:ac232c293ad9

new AnnotationManager URL
author casties
date Thu, 05 Jul 2012 12:08:58 +0200
parents f8a5f63eafc0
children 0b8bed1223ad
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
501
29c6d09a506c more cleanup.
casties
parents:
diff changeset
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
29c6d09a506c more cleanup.
casties
parents:
diff changeset
2 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
29c6d09a506c more cleanup.
casties
parents:
diff changeset
3 <html xmlns="http://www.w3.org/1999/xhtml">
29c6d09a506c more cleanup.
casties
parents:
diff changeset
4 <head>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
5 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
29c6d09a506c more cleanup.
casties
parents:
diff changeset
6 </head>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
7 <body>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
8 <!-- block used for page header content area -->
29c6d09a506c more cleanup.
casties
parents:
diff changeset
9 <metal:block metal:define-macro="head"
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
10 tal:define="viewMode pageinfo/viewMode;
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
11 docpath docinfo/textURLPath | nothing;
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
12 bib docinfo/bib | nothing; bibType docinfo/bibType | nothing;
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
13 formattedLabel python:here.metadataService.getBibFormattedLabel(bibdata=bib);">
505
29f2172db368 title also for non-bib-tag.
casties
parents: 502
diff changeset
14 <div tal:condition="not:formattedLabel">
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
15 <tal:block tal:condition="python:docinfo['creator'] or docinfo['title']">
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
16 <i tal:content="docinfo/creator" />,
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
17 <span tal:content="docinfo/title" />, <span tal:content="docinfo/date" />
505
29f2172db368 title also for non-bib-tag.
casties
parents: 502
diff changeset
18 </tal:block>
29f2172db368 title also for non-bib-tag.
casties
parents: 502
diff changeset
19 <span tal:condition="not:python:docinfo['creator'] or docinfo['title']"
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
20 tal:content="string:[no bibliographical information for this document (type ${bibType})]" />
505
29f2172db368 title also for non-bib-tag.
casties
parents: 502
diff changeset
21 </div>
501
29c6d09a506c more cleanup.
casties
parents:
diff changeset
22 <div tal:condition="formattedLabel" tal:content="structure formattedLabel" />
502
daf36d0fcfee more cleanup.
casties
parents: 501
diff changeset
23 <div class="doclinks">
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
24 <a tal:condition="python:viewMode!='index'" tal:attributes="href python:here.getLink('viewMode','index')">Bibliographical
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
25 information</a>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
26 <a tal:condition="python:viewMode!='text'" tal:attributes="href python:here.getLink('viewMode','text')">Page view</a>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
27 <a tal:condition="python:viewMode!='thumbs'" tal:attributes="href python:here.getLink('viewMode','thumbs')">Thumbnail overview</a>
502
daf36d0fcfee more cleanup.
casties
parents: 501
diff changeset
28 </div>
501
29c6d09a506c more cleanup.
casties
parents:
diff changeset
29 </metal:block>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
30 <!-- /head -->
29c6d09a506c more cleanup.
casties
parents:
diff changeset
31
29c6d09a506c more cleanup.
casties
parents:
diff changeset
32 <!-- page ruler with previous/next page buttons -->
29c6d09a506c more cleanup.
casties
parents:
diff changeset
33 <metal:block metal:define-macro="page_ruler"
29c6d09a506c more cleanup.
casties
parents:
diff changeset
34 tal:define="
29c6d09a506c more cleanup.
casties
parents:
diff changeset
35 prev python:test(pn>1,pn-1,None); next python:test(pn<numPages,pn+1,None);
29c6d09a506c more cleanup.
casties
parents:
diff changeset
36 first python:test(pn>1,1,None); last python:test(pn<numPages,numPages,None);
29c6d09a506c more cleanup.
casties
parents:
diff changeset
37 left python:test(flowLtr,prev,next); right python:test(flowLtr,next,prev);
29c6d09a506c more cleanup.
casties
parents:
diff changeset
38 leftest python:test(flowLtr,first,last); rightest python:test(flowLtr,last,first);">
29c6d09a506c more cleanup.
casties
parents:
diff changeset
39 <form class="autosubmit" tal:attributes="action viewerUrl">
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
40 <input type="hidden" tal:define="params python:here.getParams('pn', None)"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
41 tal:repeat="param params" tal:attributes="name param; value python:params[param]" />
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
42 page <a tal:condition="leftest"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
43 tal:attributes="href python:here.getLink('pn',leftest)">|&lt;</a> <span
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
44 tal:condition="not:leftest">|&lt;</span> <a tal:condition="left"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
45 tal:attributes="href python:here.getLink('pn',left)">&lt;</a> <span
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
46 tal:condition="not:left">&lt;</span> <input class="autosubmit" size="3"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
47 type="text" name="pn" tal:attributes="value pn" /> <span class="originalPage"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
48 title="Original page number"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
49 tal:define="originalPage pageinfo/pageNumberOrig | nothing"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
50 tal:condition="python:originalPage!=None"> (<span
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
51 tal:replace="originalPage" /><span
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
52 tal:define="originalPageNorm pageinfo/pageNumberOrigNorm | nothing"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
53 tal:condition="python:originalPageNorm!=None"> [<span
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
54 tal:replace="originalPageNorm" />]
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
55 </span>)
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
56 </span> <input type="submit" value="Go" /> of <span tal:replace="numPages" /> <a
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
57 tal:condition="right" tal:attributes="href python:here.getLink('pn',right)">&gt;</a>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
58 <span tal:condition="not:right">&gt;</span> <a tal:condition="rightest"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
59 tal:attributes="href python:here.getLink('pn',rightest)">&gt;|</a> <span
501
29c6d09a506c more cleanup.
casties
parents:
diff changeset
60 tal:condition="not:rightest">&gt;|</span>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
61 </form>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
62 </metal:block>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
63 <!-- /ruler -->
29c6d09a506c more cleanup.
casties
parents:
diff changeset
64
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
65 <!-- toc ruler (using getBatch) with previous/next toc page buttons -->
501
29c6d09a506c more cleanup.
casties
parents:
diff changeset
66 <metal:block metal:define-macro="toc_ruler">
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
67 <form class="autosubmit" tal:attributes="action viewerUrl"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
68 tal:define="startParam startParam | string:start">
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
69 <input type="hidden" tal:define="params python:here.getParams(startParam, None)"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
70 tal:repeat="param params" tal:attributes="name param; value python:params[param]" />
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
71 <a tal:condition="batch/prevStart"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
72 tal:attributes="href python:here.getLink(startParam,batch['prevStart'])">&lt;</a>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
73 <span tal:condition="not:batch/prevStart">&lt;</span>
511
551ca1641a5e more cleanup.
casties
parents: 505
diff changeset
74 <select class="autosubmit" tal:attributes="name startParam">
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
75 <option tal:repeat="grp batch/batches"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
76 tal:attributes="selected python:(start==grp['start']); value grp/start"
501
29c6d09a506c more cleanup.
casties
parents:
diff changeset
77 tal:content="string:${grp/start} - ${grp/end}" />
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
78 </select>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
79 <input type="submit" value="Go" /> <a tal:condition="batch/nextStart"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
80 tal:attributes="href python:here.getLink(startParam,batch['nextStart'])">&gt;</a>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
81 <span tal:condition="not:batch/nextStart">&gt;</span>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
82 </form>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
83 </metal:block>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
84
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
85 <!-- toc ruler for thumbs (using getPageBatch) with previous/next toc page buttons -->
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
86 <metal:block metal:define-macro="toc_ruler_thumbs">
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
87 <form class="autosubmit" tal:attributes="action viewerUrl">
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
88 <input type="hidden" tal:define="params python:here.getParams('start',None)"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
89 tal:repeat="param params" tal:attributes="name param; value python:params[param]" />
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
90 <a tal:condition="left" tal:attributes="href python:here.getLink('start',left)">&lt;</a>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
91 <span tal:condition="not:left">&lt;</span>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
92 <select class="autosubmit" name="start"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
93 tal:define="ofs python:test(pageinfo['pageZero'],0,1)">
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
94 <tal:block>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
95 <option tal:repeat="grp pageBatch/batches"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
96 tal:attributes="selected python:start==grp['start']; value grp/start;"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
97 tal:content="string:${grp/start} - ${grp/end}" />
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
98 </tal:block>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
99 </select>
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
100 <input type="submit" value="Go" /> <a tal:condition="right"
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
101 tal:attributes="href python:here.getLink('start',right)">&gt;</a> <span
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
102 tal:condition="not:right">&gt;</span>
501
29c6d09a506c more cleanup.
casties
parents:
diff changeset
103 </form>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
104 </metal:block>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
105
526
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
106 <!-- toc type switcher -->
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
107 <metal:block metal:define-macro="toc_switcher">
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
108 <ul class="switcher">
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
109 <li tal:attributes="class python:test(tocMode=='thumbs', 'sel', None)">
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
110 <a tal:attributes="href python:here.getLink('tocMode','thumbs')">Thumbnails</a>
526
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
111 </li>
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
112 <li tal:attributes="class python:test(tocMode=='text', 'sel', None)"
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
113 tal:condition="python:docpath and docinfo.get('numTocEntries', None)">
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
114 <a tal:attributes="href python:here.getLink('tocMode','text')">Content</a>
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
115 </li>
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
116 <li tal:attributes="class python:test(tocMode=='figures', 'sel', None)"
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
117 tal:condition="python:docpath and docinfo.get('numFigureEntries', None)">
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
118 <a tal:attributes="href python:here.getLink('tocMode','figures')">Figures</a>
526
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
119 </li>
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
120 <li tal:attributes="class python:test(tocMode=='concordance', 'sel', None)"
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
121 tal:condition="python:docpath and docinfo.get('pageNumbers', None)">
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
122 <a tal:attributes="href python:here.getLink('tocMode','concordance')">Concordance</a>
526
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
123 </li>
528
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
124 <li tal:attributes="class python:test(tocMode=='none', 'sel', None)">
f8a5f63eafc0 new viewMode=thumbs.
casties
parents: 527
diff changeset
125 <a tal:attributes="href python:here.getLink('tocMode','none')">None</a>
526
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
126 </li>
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
127 </ul>
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
128 </metal:block>
3f375a048402 moved search and dict into separate layers.
casties
parents: 511
diff changeset
129
501
29c6d09a506c more cleanup.
casties
parents:
diff changeset
130 </body>
29c6d09a506c more cleanup.
casties
parents:
diff changeset
131 </html>