incubator-bloodhound-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Ollos <ryan.ol...@wandisco.com>
Subject Re: svn commit: r1454970 - in /incubator/bloodhound/trunk/bloodhound_theme/bhtheme: htdocs/bloodhound.css templates/bh_report_edit.html
Date Thu, 14 Mar 2013 05:15:19 GMT
On Sun, Mar 10, 2013 at 6:48 PM, <rjollos@apache.org> wrote:

> Author: rjollos
> Date: Mon Mar 11 01:48:35 2013
> New Revision: 1454970
>
> URL: http://svn.apache.org/r1454970
> Log:
>  * Improved width of the input and text areas on the Report Edit page.
>   * Fixed up text on the Report edit page. For two cases on the page, the
> input label text had already been split from the ''tip'', so presumably the
> translation will already be broken. Therefore it seemed fine to proceed
> with the minor changes of removing the parenthesis and adding a trailing
> period.
>
> Modified:
>
> incubator/bloodhound/trunk/bloodhound_theme/bhtheme/htdocs/bloodhound.css
>
> incubator/bloodhound/trunk/bloodhound_theme/bhtheme/templates/bh_report_edit.html
>
> Modified:
> incubator/bloodhound/trunk/bloodhound_theme/bhtheme/htdocs/bloodhound.css
> URL:
> http://svn.apache.org/viewvc/incubator/bloodhound/trunk/bloodhound_theme/bhtheme/htdocs/bloodhound.css?rev=1454970&r1=1454969&r2=1454970&view=diff
>
> ==============================================================================
> ---
> incubator/bloodhound/trunk/bloodhound_theme/bhtheme/htdocs/bloodhound.css
> (original)
> +++
> incubator/bloodhound/trunk/bloodhound_theme/bhtheme/htdocs/bloodhound.css
> Mon Mar 11 01:48:35 2013
> @@ -457,6 +457,16 @@ h1, h2, h3, h4 {
>    display: none;
>  }
>
> +.report input#title {
> +  max-width: 500px;
> +  width: 100%;
> +}
> +
> +.report textarea.trac-resizable {
> +  max-width: 500px;
> +  width: 100%;
> +}
> +
>  table.listing th.sel, table.listing td.sel {
>   text-align: center;
>   width: 1%
>
> Modified:
> incubator/bloodhound/trunk/bloodhound_theme/bhtheme/templates/bh_report_edit.html
> URL:
> http://svn.apache.org/viewvc/incubator/bloodhound/trunk/bloodhound_theme/bhtheme/templates/bh_report_edit.html?rev=1454970&r1=1454969&r2=1454970&view=diff
>
> ==============================================================================
> ---
> incubator/bloodhound/trunk/bloodhound_theme/bhtheme/templates/bh_report_edit.html
> (original)
> +++
> incubator/bloodhound/trunk/bloodhound_theme/bhtheme/templates/bh_report_edit.html
> Mon Mar 11 01:48:35 2013
> @@ -37,25 +37,25 @@
>        </h1>
>        <div class="span12">
>          <form action="${href.report(report.id)}" method="post"
> id="edit_report"
> -            class="form-horizontal">
> +              class="form-horizontal">
>            <input type="hidden" name="action" value="$action" />
>            <div>
>              <div class="control-group">
>                <label class="control-label" for="title">Report
> Title:</label>
>                <div class="controls">
> -                <input type="text" id="title" name="title"
> value="$report.title" size="50"/><br />
> +                <input type="text" id="title" name="title"
> value="$report.title" /><br />
>                </div>
>              </div>
>              <div class="control-group">
> -              <label for="description" class="control-label" i18n:msg="">
> +              <label class="control-label" for="description" i18n:msg="">
>                  Description:
>                </label>
>                <div class="controls">
> -                <textarea id="description" name="description"
> class="wikitext trac-resizable" rows="10" cols="78">
> +                <textarea id="description" name="description"
> class="wikitext trac-resizable" rows="10">
>  $report.description</textarea>
>                  <p class="help-block">
>                    <span class="label label-info">Tip</span>
> -                  (you may use <a tabindex="42"
> href="${href.wiki('WikiFormatting')}">WikiFormatting</a> here)
> +                  You may use <a tabindex="42"
> href="${href.wiki('WikiFormatting')}">WikiFormatting</a> here.
>                  </p>
>                </div>
>              </div>
> @@ -64,15 +64,15 @@ $report.description</textarea>
>                  <span class="label label-important">Error:</span> $error
>                </div>
>                <label class="control-label" for="query" i18n:msg="">
> -                Query for Report
> +                Query for Report:
>                </label>
>                <div class="controls">
> -                <textarea id="query" name="query" class="trac-resizable"
> cols="85" rows="20">
> +                <textarea id="query" name="query" class="trac-resizable"
> rows="20">
>  $report.sql</textarea>
>                  <p class="help-block">
>                    <span class="label label-info">Tip</span>
> -                  can be either SQL or, if starting with
> <code>query:</code>,
> -                  a <a tabindex="42" href="${href.wiki('TracQuery') +
> '#QueryLanguage'}">TracQuery</a> expression)
> +                  Can be either SQL or, if starting with
> <code>query:</code>,
> +                  a <a tabindex="42" href="${href.wiki('TracQuery') +
> '#QueryLanguage'}">TracQuery</a> expression.
>                  </p>
>                </div>
>              </div>
>

I've been *very slightly* concerned about a few subtle changes that might
break the translations provided by Trac. I don't have much experience
working with the translations, but I think that I know a few best
practices, such as "don't change translatable strings".

What we've done on the report page makes a lot of sense in terms of page
layout, separating the "label" from the "hint". In Trac the "label" and
"hint" existed as a single string. We've separated them in Bloodhound's
bootstrap template, and I suspect that the strings won't be translated
correctly because of this.

Anyway, I just wanted to mention, in case anyone has input and can help me
understand better. Some work I'm doing in a Trac ticket may help with
changing Trac to accommodate theme's such as Bloodhound, so that they don't
break translations:
http://trac.edgewall.org/ticket/11112#comment:2

What I did as part of that ticket is to separate the "label" and "hint"
into separate strings in the Trac template, and I asked the Trac developers
for feedback on the change.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message