Mercurial > p > roundup > code
diff website/issues/html/issue.item.html @ 6307:6ad3b2d46852
more lighthouse fixes
Add id's to html input elements and wrap some additional labels with
label tag with for attribute.
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Thu, 24 Dec 2020 00:10:53 -0500 |
| parents | 871dc7904d7a |
| children | 83b67f65b8ff |
line wrap: on
line diff
--- a/website/issues/html/issue.item.html Wed Dec 23 21:39:26 2020 -0500 +++ b/website/issues/html/issue.item.html Thu Dec 24 00:10:53 2020 -0500 @@ -43,7 +43,7 @@ <tr> <th class="required"><label for="title" i18n:translate="">Title:</label></th> <td colspan="3" tal:condition="context/title/is_edit_ok" - tal:content="structure python:context.title.field(size=60)">title</td> + tal:content="structure python:context.title.field(id='title', size=60)">title</td> <td colspan="3" tal:condition="not:context/title/is_edit_ok"> <span tal:content="structure context/title/plain"/> <input type="hidden" name="title" tal:attributes="value context/title"> @@ -82,7 +82,7 @@ </th> <td tal:content="structure context/status/menu">status</td> <th><label for="resolution" i18n:translate="">Resolution:</label></th> - <td tal:content="structure context/resolution/menu">resolution</td> + <td tal:content="structure python:context.resolution.menu(html_kwargs={'id':'resolution'})">resolution</td> </tr> <tr tal:condition="context/id"> @@ -91,7 +91,7 @@ tal:replace="structure python:db.issue.classhelp('id,title', filter='status=0,1', property='dependencies')" /> </th> <td> - <span tal:replace="structure python:context.dependencies.field(showid=1,size=20)" /> + <span tal:replace="structure python:context.dependencies.field(id='dependencies',showid=1,size=20)" /> <span tal:condition="context/dependencies" tal:repeat="d python:context.dependencies.sorted('creation')"> <br/>View: <a tal:attributes="href string:issue${d/id}" tal:content="d/id"></a> </span> @@ -102,7 +102,7 @@ tal:replace="structure python:db.issue.classhelp('id,title', filter='status=0,1', property='superseder')" /> </th> <td> - <span tal:replace="structure python:context.superseder.field(showid=1, size=20)" /> + <span tal:replace="structure python:context.superseder.field(id='superseder', showid=1, size=20)" /> <span tal:condition="context/superseder"> <!-- <br><span i18n:translate="">View</span>: <a tal:repeat="sup context/superseder" @@ -117,7 +117,7 @@ <tr> <th><label for="assignee" i18n:translate="">Assigned To</label>:</th> <td tal:condition="context/status/is_edit_ok"> - <select name="assignee"> + <select id="assignee" name="assignee"> <option value="-1">nobody</option> <tal:block tal:repeat="userdata python:db._db.user.filter_sql('select id,_username from _user where _roles like \'%Developer%\' order by _username')"> <option tal:attributes="value python:userdata[0]; @@ -134,7 +134,7 @@ tal:replace="structure python:db.user.classhelp('username,realname,address', property='nosy')" /> </th> <td> - <span tal:replace="structure context/nosy/field" /> + <span tal:replace="structure python:context.nosy.field(id='nosy')" /> </td> </tr> <tr> @@ -142,8 +142,8 @@ <span tal:replace="structure python:db.priority.classhelp('id,name,description',label='Priority')" />: </th> <td tal:content="structure context/priority/menu">priority</td> - <th i18n:translate="">Keywords:</th> - <td tal:content="structure python:context['keywords'].menu(height=5)">keywords</td> + <th><label for="keywords" i18n:translate="">Keywords</label>:</th> + <td tal:content="structure python:context['keywords'].menu(height=5,html_kwargs={'id': 'keywords'})">keywords</td> </tr> @@ -151,7 +151,7 @@ <th><label for="@note" i18n:translate="">Comment</label>:</th> <td colspan="3"> <textarea tal:content="request/form/@note/value | default" - name="@note" wrap="hard" rows="10" cols="72"></textarea> + id="@note" name="@note" wrap="hard" rows="10" cols="72"></textarea> </td> </tr> @@ -159,12 +159,12 @@ <th><label for="file-1@content" i18n:translate="">File</label>:</th> <td colspan=3> <input type="hidden" name="@link@files" value="file-1"> - <input type="file" name="file-1@content" size="40"> + <input type="file" id="file-1@content" name="file-1@content" size="40"> </td> </tr> <tr tal:condition="context/is_edit_ok"> <th><label for="file-1@description" i18n:translate="">File Description</label>:</th> - <td colspan=3><input type="edit" name="file-1@description" size="40"></td> + <td colspan=3><input type="edit" id="file-1@description" name="file-1@description" size="40"></td> </tr> </table> </fieldset>
