Skip to content

Commit ed0572a

Browse files
author
Alexander Smishlajev
committed
i18n markup
1 parent 1d4c353 commit ed0572a

File tree

1 file changed

+20
-15
lines changed

1 file changed

+20
-15
lines changed

templates/minimal/html/_generic.help.html

Lines changed: 20 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
11
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2-
<html>
2+
<html tal:define="property request/form/property/value">
33
<head>
44
<link rel="stylesheet" type="text/css" href="@@file/style.css" />
55
<meta http-equiv="Content-Type"
66
tal:attributes="content string:text/html;; charset=${request/client/charset}" />
77
<tal:block tal:condition="python:request.form.has_key('property')">
8-
<title tal:content="string:${request/form/property/value} help">Property</title>
9-
<script language="Javascript" type="text/javascript"
8+
<title i18n:translate=""><span i18n:name="property"
9+
tal:replace="property" /> help</title>
10+
<script language="Javascript" type="text/javascript"
1011
tal:content="structure string:
1112
// this is the name of the field in the original form that we're working on
12-
field = '${request/form/property/value}';" >
13+
field = '${property}';" >
1314
</script>
14-
<script src="@@file/help_controls.js" type="text/javascript"><!--
15+
<script src="@@file/help_controls.js" type="text/javascript"><!--
1516
//--></script>
1617
</tal:block>
1718
</head>
@@ -20,16 +21,16 @@
2021
tal:define="start python:int(request.form['@startwith'].value);
2122
batch python:utils.Batch(context.list(), 500, start);
2223
props python:request.form['properties'].value.split(',')">
23-
24+
2425
<div id="classhelp-controls" tal:condition="python:start==0">
25-
<!--input type="button" name="btn_clear"
26+
<!--input type="button" name="btn_clear"
2627
value="Clear" onClick="clearList()"/ -->
2728
<input type="text" name="text_preview" size="24" class="preview"
2829
onchange="reviseList(this.value);"/>
29-
<input type="button" name="btn_reset"
30+
<input type="button" name="btn_reset"
3031
value=" Cancel " onclick="resetList(); window.close();"/>
3132
<input type="button" name="btn_apply" class="apply"
32-
value=" Apply " onclick="updateList(); window.close();"/>
33+
value=" Apply " onclick="updateList(); window.close();"/>
3334
</div>
3435

3536
<table class="classhelp">
@@ -39,15 +40,15 @@
3940
</tr>
4041
<tr tal:repeat="item batch">
4142
<td>
42-
<input type="checkbox" name="check"
43+
<input type="checkbox" name="check"
4344
onclick="updatePreview();"
4445
tal:condition="python:start==0"
4546
tal:define="attr python:item[props[0]]"
4647
tal:attributes="value attr; id attr" />
4748
</td>
4849
<td tal:repeat="prop props">
4950
<label class="classhelp-label"
50-
tal:attributes="for python:item[props[0]]"
51+
tal:attributes="for python:item[props[0]]"
5152
tal:content="structure python:item[prop]"></label>
5253
</td>
5354
</tr>
@@ -60,14 +61,18 @@
6061
<tr class="navigation">
6162
<th>
6263
<a tal:define="prev batch/previous" tal:condition="prev"
63-
tal:attributes="href string:${request/classname}?@template=help&@startwith=${prev/first}&properties=${request/form/properties/value}">&lt;&lt; previous</a>
64+
tal:attributes="href string:${request/classname}?@template=help&@startwith=${prev/first}&properties=${request/form/properties/value}"
65+
i18n:translate="">&lt;&lt; previous</a>
6466
&nbsp;
6567
</th>
66-
<th tal:content="python: '%d...%d out of %d'%(batch.start,
67-
batch.start+batch.length-1, batch.sequence_length)">current</th>
68+
<th i18n:translate=""><span tal:replace="batch/start" i18n:name="start"
69+
/>..<span tal:replace="python: batch.start + batch.length -1" i18n:name="end"
70+
/> out of <span tal:replace="batch/sequence_length" i18n:name="total"
71+
/></th>
6872
<th>
6973
<a tal:define="next batch/next" tal:condition="next"
70-
tal:attributes="href string:${request/classname}?@template=help&@startwith=${next/first}&properties=${request/form/properties/value}">next &gt;&gt;</a>
74+
tal:attributes="href string:${request/classname}?@template=help&@startwith=${next/first}&properties=${request/form/properties/value}"
75+
i18n:translate="">next &gt;&gt;</a>
7176
&nbsp;
7277
</th>
7378
</tr>

0 commit comments

Comments
 (0)