diff options
Diffstat (limited to 'template/en')
18 files changed, 201 insertions, 39 deletions
diff --git a/template/en/default/admin/classifications/add.html.tmpl b/template/en/default/admin/classifications/add.html.tmpl index d6a7c3880..d11a8d36c 100644 --- a/template/en/default/admin/classifications/add.html.tmpl +++ b/template/en/default/admin/classifications/add.html.tmpl @@ -31,7 +31,14 @@ </tr> <tr> <th align="right">Description:</th> - <td><textarea rows=4 cols=64 wrap=virtual name="description"></textarea></td> + <td> + [% INCLUDE global/textarea.html.tmpl + name = 'description' + minrows = 4 + cols = 64 + wrap = 'virtual' + %] + </td> </tr> </table> <hr> diff --git a/template/en/default/admin/classifications/edit.html.tmpl b/template/en/default/admin/classifications/edit.html.tmpl index 24ec9dacf..b00ea6853 100644 --- a/template/en/default/admin/classifications/edit.html.tmpl +++ b/template/en/default/admin/classifications/edit.html.tmpl @@ -32,8 +32,13 @@ </tr> <tr> <th align="right">Description:</th> - <td><textarea rows=4 cols=64 name="description"> - [% classification.description FILTER none %]</textarea> + <td> + [% INCLUDE global/textarea.html.tmpl + name = 'description' + minrows = 4 + cols = 64 + defaultcontent = classification.description + %] </td> </tr> <tr valign=top> diff --git a/template/en/default/admin/components/create.html.tmpl b/template/en/default/admin/components/create.html.tmpl index fcb57bb03..ea4380d50 100644 --- a/template/en/default/admin/components/create.html.tmpl +++ b/template/en/default/admin/components/create.html.tmpl @@ -40,8 +40,12 @@ <tr> <th align="right">Description:</th> <td> - <textarea rows="4" cols="64" wrap="virtual" - name="description"></textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'description' + minrows = 4 + cols = 64 + wrap = 'virtual' + %] </td> </tr> <tr> diff --git a/template/en/default/admin/components/edit.html.tmpl b/template/en/default/admin/components/edit.html.tmpl index 8b350d9e8..920ad1ff6 100644 --- a/template/en/default/admin/components/edit.html.tmpl +++ b/template/en/default/admin/components/edit.html.tmpl @@ -43,8 +43,14 @@ </tr> <tr> <td valign="top">Component Description:</td> - <td><textarea rows="4" cols="64" wrap="virtual" - name="description">[% comp.description FILTER html %]</textarea> + <td> + [% INCLUDE global/textarea.html.tmpl + name = 'description' + minrows = 4 + cols = 64 + wrap = 'virtual' + defaultcontent = comp.description + %] </td> </tr> <tr> diff --git a/template/en/default/admin/flag-type/edit.html.tmpl b/template/en/default/admin/flag-type/edit.html.tmpl index ad41576cb..dc49890b7 100644 --- a/template/en/default/admin/flag-type/edit.html.tmpl +++ b/template/en/default/admin/flag-type/edit.html.tmpl @@ -85,7 +85,12 @@ <th>Description:</th> <td> a comprehensive description of this type<br> - <textarea name="description" rows="4" cols="80">[% type.description FILTER html %]</textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'description' + minrows = 4 + cols = 80 + defaultcontent = type.description + %] </td> </tr> diff --git a/template/en/default/admin/keywords/create.html.tmpl b/template/en/default/admin/keywords/create.html.tmpl index 006b4b344..3f9f5aecf 100755 --- a/template/en/default/admin/keywords/create.html.tmpl +++ b/template/en/default/admin/keywords/create.html.tmpl @@ -38,8 +38,12 @@ <tr> <th align="right">Description:</th> <td> - <textarea rows="4" cols="64" wrap="virtual" - name="description"></textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'description' + minrows = 4 + cols = 64 + wrap = 'virtual' + %] </td> </tr> </table> diff --git a/template/en/default/admin/keywords/edit.html.tmpl b/template/en/default/admin/keywords/edit.html.tmpl index 3809563c2..74cef3d55 100755 --- a/template/en/default/admin/keywords/edit.html.tmpl +++ b/template/en/default/admin/keywords/edit.html.tmpl @@ -42,8 +42,13 @@ <tr> <th align="right">Description:</th> <td> - <textarea rows="4" cols="64" wrap="virtual" - name="description">[% description FILTER html %]</textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'description' + minrows = 4 + cols = 64 + wrap = 'virtual' + defaultcontent = description + %] </td> </tr> <tr> diff --git a/template/en/default/admin/users/userdata.html.tmpl b/template/en/default/admin/users/userdata.html.tmpl index 672e180bf..afb402554 100644 --- a/template/en/default/admin/users/userdata.html.tmpl +++ b/template/en/default/admin/users/userdata.html.tmpl @@ -72,9 +72,15 @@ <tr> <th><label for="disabledtext">Disable text:</label></th> <td> - <textarea name="disabledtext" rows="10" - id="disabledtext" - cols="60">[% otheruser.disabledtext FILTER html %]</textarea><br /> + [% INCLUDE global/textarea.html.tmpl + name = 'disabledtext' + id = 'disabledtext' + minrows = 2 + maxrows = 10 + defaultrows = 10 + cols = 60 + defaultcontent = otheruser.disabledtext + %]<br> (If non-empty, then the account will be disabled, and this text should explain why.) [% IF editform %] diff --git a/template/en/default/attachment/create.html.tmpl b/template/en/default/attachment/create.html.tmpl index c3ef855d4..4de1e5a08 100644 --- a/template/en/default/attachment/create.html.tmpl +++ b/template/en/default/attachment/create.html.tmpl @@ -237,7 +237,14 @@ <th><label for="comment">Comment:</label></th> <td> <em>(optional) Add a comment about this attachment to the [% terms.bug %].</em><br> - <textarea wrap="soft" id="commment" name="comment" rows="6" cols="80"></textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'comment' + id = 'comment' + minrows = 6 + maxrows = 15 + cols = 80 + wrap = 'soft' + %] </td> </tr> <tr> diff --git a/template/en/default/attachment/edit.html.tmpl b/template/en/default/attachment/edit.html.tmpl index eefe141f8..53eb44d9e 100644 --- a/template/en/default/attachment/edit.html.tmpl +++ b/template/en/default/attachment/edit.html.tmpl @@ -212,8 +212,13 @@ <td width="25%"> <small> <b>Description:</b><br> - <textarea rows="3" cols="25" name="description" wrap="soft"> - [%- attachment.description FILTER html %]</textarea><br> + [% INCLUDE global/textarea.html.tmpl + name = 'description' + minrows = 3 + cols = 25 + wrap = 'soft' + defaultcontent = attachment.description + %]<br> [% IF attachment.isurl %] <input type="hidden" name="filename" @@ -250,7 +255,12 @@ <div id="smallCommentFrame"> <b>Comment (on the [% terms.bug %]):</b><br> - <textarea name="comment" rows="5" cols="25" wrap="soft"></textarea><br> + [% INCLUDE global/textarea.html.tmpl + name = 'comment' + minrows = 5 + cols = 25 + wrap = 'soft' + %]<br> </div> <input type="submit" value="Submit"><br><br> @@ -264,8 +274,14 @@ [% IF isviewable %] <td width="75%"> - <textarea id="editFrame" name="comment" wrap="soft" cols="80" - style="height: 400px; width: 100%; display: none;"></textarea> + [% INCLUDE global/textarea.html.tmpl + id = 'editFrame' + name = 'comment' + style = 'height: 400px; width: 100%; display: none' + minrows = 10 + cols = 80 + wrap = 'soft' + %] <iframe id="viewFrame" src="attachment.cgi?id=[% attachment.id %]" style="height: 400px; width: 100%;"> <b>You cannot view the attachment while viewing its details because your browser does not support IFRAMEs. <a href="attachment.cgi?id=[% attachment.id %]">View the attachment on a separate page</a>.</b> diff --git a/template/en/default/bug/create/create-guided.html.tmpl b/template/en/default/bug/create/create-guided.html.tmpl index 712f27948..3c29791e5 100644 --- a/template/en/default/bug/create/create-guided.html.tmpl +++ b/template/en/default/bug/create/create-guided.html.tmpl @@ -333,7 +333,11 @@ function PutDescription() { <b>Details</b> </td> <td valign="top"> - <textarea rows="6" cols="80" name="comment"></textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'comment' + minrows = 6 + cols = 80 + %] <p> Expand on the Summary. Please be as specific as possible about what is wrong. @@ -381,11 +385,12 @@ function PutDescription() { <b>Steps to Reproduce</b> </td> <td valign="top"> -<textarea rows="4" cols="80" name="reproduce_steps"> -1. -2. -3. -</textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'reproduce_steps' + minrows = 4 + cols = 80 + defaultcontent = "1.\n2.\n3." + %] <p> Describe how to reproduce the problem, step by step. Include any special setup steps. @@ -398,7 +403,11 @@ function PutDescription() { <b>Actual Results</b> </td> <td valign="top"> - <textarea rows="4" cols="80" name="actual_results"></textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'actual_results' + minrows = 4 + cols = 80 + %] <p> What happened after you performed the steps above? </p> @@ -410,7 +419,11 @@ function PutDescription() { <b>Expected Results</b> </td> <td valign="top"> - <textarea rows="4" cols="80" name="expected_results"></textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'expected_results' + minrows = 4 + cols = 80 + %] <p> What should the software have done instead? </p> @@ -422,7 +435,11 @@ function PutDescription() { <b>Additional Information</b> </td> <td valign="top"> - <textarea rows="8" cols="80" name="additional_info"></textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'additional_info' + minrows = 8 + cols = 80 + %] <p> Add any additional information you feel may be relevant to this [% terms.bug %], such as the <b>theme</b> you were diff --git a/template/en/default/bug/create/create.html.tmpl b/template/en/default/bug/create/create.html.tmpl index 21bfb6104..d5e0081d9 100644 --- a/template/en/default/bug/create/create.html.tmpl +++ b/template/en/default/bug/create/create.html.tmpl @@ -307,13 +307,21 @@ function set_assign_to() { <tr><td align="right" valign="top"><strong>Description:</strong></td> <td colspan="3"> - <textarea name="comment" rows="10" cols="80"> + [% defaultcontent = BLOCK %] [% IF cloned_bug_id %] +++ This [% terms.bug %] was initially created as a clone of [% terms.Bug %] #[% cloned_bug_id %] +++ [% END %] - [% comment FILTER html %]</textarea> + [% comment FILTER html %] + [%- END %] + [% INCLUDE global/textarea.html.tmpl + name = 'comment' + minrows = 10 + maxrows = 25 + cols = 80 + defaultcontent = defaultcontent + %] <br> </td> </tr> diff --git a/template/en/default/bug/edit.html.tmpl b/template/en/default/bug/edit.html.tmpl index 349b05049..3c647b67d 100644 --- a/template/en/default/bug/edit.html.tmpl +++ b/template/en/default/bug/edit.html.tmpl @@ -567,8 +567,14 @@ [% END %] <br> <a name="add_comment"></a> - <textarea name="comment" id="comment" rows="10" cols="80" - accesskey="c"></textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'comment' + id = 'comment' + minrows = 10 + maxrows = 25 + cols = 80 + accesskey = 'c' + %] [% IF NOT bug.cc || NOT bug.cc.contains(user.login) %] <br> diff --git a/template/en/default/global/setting-descs.none.tmpl b/template/en/default/global/setting-descs.none.tmpl index 3ca7fe3f3..a0dbeb1a3 100644 --- a/template/en/default/global/setting-descs.none.tmpl +++ b/template/en/default/global/setting-descs.none.tmpl @@ -23,6 +23,7 @@ "comment_sort_order" => "When viewing $terms.abug, show comments in this order", "csv_colsepchar" => "Field separator character for CSV files", "display_quips" => "Show a quip at the top of each bug list", + "zoom_textareas" => "Zoom textareas large when in use (requires JavaScript)", "newest_to_oldest" => "Newest to Oldest", "newest_to_oldest_desc_first" => "Newest to Oldest, but keep Description at the top", "off" => "Off", diff --git a/template/en/default/global/textarea.html.tmpl b/template/en/default/global/textarea.html.tmpl new file mode 100644 index 000000000..e96721b50 --- /dev/null +++ b/template/en/default/global/textarea.html.tmpl @@ -0,0 +1,50 @@ +[%# 1.0@bugzilla.org %] +[%# The contents of this file are subject to the Mozilla Public + # License Version 1.1 (the "License"); you may not use this file + # except in compliance with the License. You may obtain a copy of + # the License at http://www.mozilla.org/MPL/ + # + # Software distributed under the License is distributed on an "AS + # IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or + # implied. See the License for the specific language governing + # rights and limitations under the License. + # + # The Original Code is the Bugzilla Bug Tracking System. + # + # Contributor(s): Marc Schumann <wurblzap@gmail.com> + #%] + +[%# INTERFACE: + # + # id: (optional) The "id"-attribute of the textarea. + # name: (optional) The "name"-attribute of the textarea. + # accesskey: (optional) The "accesskey"-attribute of the textarea. + # style: (optional) The "style"-attribute of the textarea. + # wrap: (deprecated; optional) The "wrap"-attribute of the textarea. + # minrows: (required) Number of rows the textarea shall have initially + # and when not having focus. + # maxrows: (optional) Number of rows the textarea shall have if + # maximized (which happens on getting focus). If not given, + # the textarea doesn't maximize when getting focus. + # defaultrows: (optional) Number of rows the textarea shall have if + # the zoom_textareas user preference if off. If not given, + # minrows will be used. + # cols: (required) Number of columns the textarea shall have. + # defaultcontent: (optional) Default content for the textarea. + #%] + +<textarea [% IF name %]name="[% name FILTER html %]"[% END %] + [% IF id %] id="[% id FILTER html %]"[% END %] + [% IF accesskey %] accesskey="[% accesskey FILTER html %]"[% END %] + [% IF style %] style="[% style FILTER html %]"[% END %] + [% IF wrap %] wrap="[% wrap FILTER html %]"[% END %] + [% IF defaultrows && user.settings.zoom_textareas.value == 'off' %] + rows="[% defaultrows FILTER html %]" + [% ELSE %] + rows="[% minrows FILTER html %]" + [% END %] + cols="[% cols FILTER html %]" + [% IF maxrows && user.settings.zoom_textareas.value == 'on' %] + onFocus="this.rows=[% maxrows FILTER html %]" + onBlur="this.rows=[% minrows FILTER html %]" + [% END %]>[% defaultcontent FILTER html %]</textarea> diff --git a/template/en/default/list/edit-multiple.html.tmpl b/template/en/default/list/edit-multiple.html.tmpl index d55a4e2db..dbf73b354 100644 --- a/template/en/default/list/edit-multiple.html.tmpl +++ b/template/en/default/list/edit-multiple.html.tmpl @@ -209,7 +209,13 @@ </table> <b><label for="comment">Additional Comments:</label></b><br> -<textarea id="comment" name="comment" rows="5" cols="80"></textarea><br> +[% INCLUDE global/textarea.html.tmpl + name = 'comment' + id = 'comment' + minrows = 5 + maxrows = 25 + cols = 80 +%]<br> [% IF groups.size > 0 %] diff --git a/template/en/default/pages/linkify.html.tmpl b/template/en/default/pages/linkify.html.tmpl index 896f7d41f..9ad92a0d0 100644 --- a/template/en/default/pages/linkify.html.tmpl +++ b/template/en/default/pages/linkify.html.tmpl @@ -30,7 +30,11 @@ </p> <form action="page.cgi" method="post"> - <textarea cols="80" rows="20" name="text"></textarea> + [% INCLUDE global/textarea.html.tmpl + name = 'text' + minrows = 20 + cols = 80 + %] <br> <input type="hidden" name="id" value="linked.html"> <input value="Linkify" type="submit"> diff --git a/template/en/default/whine/schedule.html.tmpl b/template/en/default/whine/schedule.html.tmpl index b49f713a8..4f94b4d71 100644 --- a/template/en/default/whine/schedule.html.tmpl +++ b/template/en/default/whine/schedule.html.tmpl @@ -113,9 +113,14 @@ Descriptive text sent within whine message: </td> <td> - <textarea name="event_[% event.key %]_body" - rows="5" cols="80"> - [% event.value.body FILTER html %]</textarea> + [% INCLUDE global/textarea.html.tmpl + name = "event_${event.key}_body" + minrows = 3 + maxrows = 10 + defaultrows = 5 + cols = 80 + defaultcontent = event.value.body + %] </td> </tr> |