From b112cdad14ae4254f71f2be9e14bcb44c0eb102a Mon Sep 17 00:00:00 2001 From: chenqiaomin Date: Wed, 25 May 2016 02:03:27 +0000 Subject: [PATCH] Use 'trimmed' for blocktrans in html page blocktrans trimmed option removes newlines from contents of blocktrans and replaces any whitespace at the beginning and end of a line into a single space. This makes translator life easier. More detail is described in the bug report. Change-Id: Ic63629a1afe5606a58797ed69bf847447cad9c02 Closes-Bug: #1585428 --- muranodashboard/templates/catalog/index.html | 2 +- muranodashboard/templates/packages/_import_bundle.html | 2 +- muranodashboard/templates/packages/_upload.html | 2 +- muranodashboard/templates/services/_overview.html | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/muranodashboard/templates/catalog/index.html b/muranodashboard/templates/catalog/index.html index 810f21d23..a14f13a5e 100644 --- a/muranodashboard/templates/catalog/index.html +++ b/muranodashboard/templates/catalog/index.html @@ -111,7 +111,7 @@ {% else %}

{% if no_apps %} - {% blocktrans %}There are no applications in the catalog. You can import apps from + {% blocktrans trimmed %}There are no applications in the catalog. You can import apps from {{ repo_url }}.{% endblocktrans %}

{% blocktrans trimmed %}Go to diff --git a/muranodashboard/templates/packages/_import_bundle.html b/muranodashboard/templates/packages/_import_bundle.html index e74137e56..afe66815b 100644 --- a/muranodashboard/templates/packages/_import_bundle.html +++ b/muranodashboard/templates/packages/_import_bundle.html @@ -28,7 +28,7 @@

{% trans "Description" %}:

{% trans "Bundle Name" %}: {% trans "Bundle's full name."%}

-

{% blocktrans %}The bundle is going to be installed from {{murano_repo_url}} repository.{% endblocktrans %}

+

{% blocktrans trimmed %}The bundle is going to be installed from {{murano_repo_url}} repository.{% endblocktrans %}

{% trans "Description" %}:

diff --git a/muranodashboard/templates/packages/_upload.html b/muranodashboard/templates/packages/_upload.html index 61c7d749b..2e1c52331 100644 --- a/muranodashboard/templates/packages/_upload.html +++ b/muranodashboard/templates/packages/_upload.html @@ -46,7 +46,7 @@

{% trans "Description" %}:

{% trans "Package Name" %}: {% trans "Fully qualified package name." %}

{% trans "Package Version" %}: {% trans "Version of the package (optional)." %}

-

{% blocktrans %}The package is going to be imported from {{murano_repo_url}} repository.{% endblocktrans %}

+

{% blocktrans trimmed %}The package is going to be imported from {{murano_repo_url}} repository.{% endblocktrans %}

{% trans "Description" %}:

diff --git a/muranodashboard/templates/services/_overview.html b/muranodashboard/templates/services/_overview.html index 8748dd30e..b113909bc 100644 --- a/muranodashboard/templates/services/_overview.html +++ b/muranodashboard/templates/services/_overview.html @@ -14,7 +14,7 @@
{% elif key == 'Instances' %} {% for instance in value %} -
{% blocktrans %}Instance{{forloop.counter}} name{% endblocktrans %}
+
{% blocktrans trimmed %}Instance{{forloop.counter}} name{% endblocktrans %}
{{ instance.name }} @@ -30,7 +30,7 @@

{% elif key == 'Stacks'%} {% for stack in value %} -
{% blocktrans %}Heat Orchestration stack{{forloop.counter}} name{% endblocktrans %}
+
{% blocktrans trimmed %}Heat Orchestration stack{{forloop.counter}} name{% endblocktrans %}
{{ stack.name }}