Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bookmarklet languages #999

Closed
wants to merge 7 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion src/JDA/CoreBundle/Resources/translations/messages.en.xliff
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0"?>
<?xml version="1.0"?>
<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
<file source-language="en" datatype="plaintext" original="file.ext">
<body>
Expand Down Expand Up @@ -1961,6 +1961,14 @@ prompt those of us who were not affected to reflect on the way we live our lives
<source>jda.my.wakuInformational</source>
<target>Construct a media rich narrative using this collection on the Waku. Waku is a story telling platform for curation and presentation, give it a try!</target>
</trans-unit>
<trans-unit id="493">
<source>jda.form.contribute.language.french</source>
<target>French</target>
</trans-unit>
<trans-unit id="494">
<source>jda.form.contribute.language.others</source>
<target>Others</target>
</trans-unit>
</body>
</file>
</xliff>
10 changes: 9 additions & 1 deletion src/JDA/CoreBundle/Resources/translations/messages.ja.xliff
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0"?>
<?xml version="1.0"?>
<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
<file source-language="en" datatype="plaintext" original="file.ext">
<body>
Expand Down Expand Up @@ -1986,6 +1986,14 @@ JDAの基本コンセプトの紹介ビデオ、及び使用説明ビデオ・
<source>jda.my.wakuInformational</source>
<target>Waku使うことによって、このコレクションをマルチメディアな物語へと構築することができます。Wakuはキュレートされた震災記録から個人の物語を紡ぎ、発表、シェアできるプラットフォームです。ぜひお試しください!</target>
</trans-unit>
<trans-unit id="493">
<source>jda.form.contribute.language.french</source>
<target>フランス語</target>
</trans-unit>
<trans-unit id="494">
<source>jda.form.contribute.language.others</source>
<target>その他</target>
</trans-unit>
</body>
</file>
</xliff>
2 changes: 2 additions & 0 deletions src/JDA/CoreBundle/Resources/views/Forms/seedSubmit.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,8 @@
<input type="checkbox" name="languageChk" id="japaneseChk" value="Japanese" /> {% trans %}jda.form.contribute.language.japanese{% endtrans %}
<input type="checkbox" name="languageChk" id="chineseChk" value="Chinese" /> {% trans %}jda.form.contribute.language.chinese{% endtrans %}
<input type="checkbox" name="languageChk" id="koreanChk" value="Korean" /> {% trans %}jda.form.contribute.language.korean{% endtrans %}
<input type="checkbox" name="languageChk" id="frenchChk" value="French" /> {% trans %}jda.form.contribute.language.french{% endtrans %}
<input type="checkbox" name="languageChk" id="othersChk" value="Others" /> {% trans %}jda.form.contribute.language.others{% endtrans %}
</td>
</tr>
<tr>
Expand Down
8 changes: 4 additions & 4 deletions src/JDA/CoreBundle/Resources/views/Search/search.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

{% block title %}<title>{% trans %}jda.home.title{% endtrans %}</title>{% endblock %}



{% block stylesheets %}

Expand Down Expand Up @@ -94,13 +94,13 @@ body {
<option value="Video">{% trans %}jda.search.video{% endtrans %}</option>
<option value="Audio">{% trans %}jda.search.audio{% endtrans %}</option>
<option value="Tweet">{% trans %}jda.search.tweet{% endtrans %}</option>
<option value="Document">{% trans %}jda.search.document{% endtrans %}</option>
<option value="Article">{% trans %}jda.search.article{% endtrans %}</option>
<option value="Website">{% trans %}jda.search.website{% endtrans %}</option>
<option value="Document">{% trans %}jda.search.document{% endtrans %}</option>
<option value="Text">{% trans %}jda.search.testimonial{% endtrans %}</option>
<option value="Broadcast">{% trans %}jda.search.broadcast{% endtrans %}</option>
<option value="Article">{% trans %}jda.search.article{% endtrans %}</option>
<option value="Headline">{% trans %}jda.search.headline{% endtrans %}</option>
<option value="Collection">{% trans %}jda.search.collection{% endtrans %}</option>
<option value="Headline">{% trans %}jda.search.headline{% endtrans %}</option>
</select>
</span>
</div>
Expand Down
3 changes: 2 additions & 1 deletion src/JDA/CoreBundle/Resources/views/Team/team.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,13 @@
{% trans %}jda.team.webdeveloper.tyreke{% endtrans %}<br/>
{% trans %}jda.team.webdeveloper.kyle{% endtrans %}<br/>
{% trans %}jda.team.webdeveloper.jessica{% endtrans %}<br/>
Hi Hi Hi Hi Hi
</p>

<h4>{% trans %}jda.team.contentdevelopment{% endtrans %}</h4>
<p>{% trans %}jda.team.content.lead{% endtrans %}<br/>
{% trans %}jda.team.content.developer{% endtrans %}<br/>
{% trans %}jda.team.content.curation{% endtrans %}</br>
{% trans %}jda.team.content.cu ration{% endtrans %}</br>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like there is an extra space here that should be removed.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alex,
I deleted the extra space and tested it in my dev server and now looks fine.
I commited the changes and should take effect in the pending pull request
#1003.

Thanks.

Javier.

On Mon, Oct 5, 2015 at 3:38 PM, Alex Horak [email protected] wrote:

In src/JDA/CoreBundle/Resources/views/Team/team.html.twig
#999 (comment)
:

</p>

<h4>{% trans %}jda.team.contentdevelopment{% endtrans %}</h4>
<p>{% trans %}jda.team.content.lead{% endtrans %}<br/>
{% trans %}jda.team.content.developer{% endtrans %}<br/>
  • {% trans %}jda.team.content.curation{% endtrans %}
  • {% trans %}jda.team.content.cu ration{% endtrans %}

Looks like there is an extra space here that should be removed.


Reply to this email directly or view it on GitHub
https://github.com/Japan-Digital-Archives/Japan-Digital-Archive/pull/999/files#r41206912
.

Javier Cuan

</p>

<h4>{% trans %}jda.team.alumni{% endtrans %}</h4>
Expand Down
37 changes: 20 additions & 17 deletions src/JDA/CoreBundle/Resources/views/Widget/widget.html.twig
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@



{# src/Zeega/\CoreBundle\/Resources/views/Widget/fail.widget.html.twig #}

Expand Down Expand Up @@ -121,14 +121,15 @@
<div class='ingest-info'> <input type="date" id="datepicker"> </div>
</div>


<h3>Language:</h3>
<div id="Language">
<div class='ingest-info'>
<input type="checkbox" class="languageChk" id="englishChk" value="English">English / 英語<br>
<input type="checkbox" class="languageChk" id="japaneseChk" value="Japanese">Japanese / 日本語<br>
<input type="checkbox" class="languageChk" id="chineseChk" value="Chinese">Chinese / 中国語<br>
<input type="checkbox" class="languageChk" id="koreanChk" value="Korean">Korean / 韓国語<br>
<input type="checkbox" class="languageChk" id="koreanChk" value="Korean">Korean / 韓国語<br>
<input type="checkbox" class="languageChk" id="frenchChk" value="French">French / フランス語<br>
<input type="checkbox" class="languageChk" id="othersChk" value="Others">Others / その他<br>
</div>
</div>

Expand Down Expand Up @@ -264,19 +265,19 @@
return;
}

var checkboxes = document.getElementsByClassName("languageChk");
var lent = checkboxes.length;
var checkedCount = 0;
for (i = 0; i < lent; i++) {
if (checkboxes[i].checked) {
checkedCount+=1;
}
var checkboxes = document.getElementsByClassName("languageChk");
var lent = checkboxes.length;
var checkedCount = 0;
for (i = 0; i < lent; i++) {
if (checkboxes[i].checked) {
checkedCount+=1;
}
}

if (checkedCount == 0) {
alert("Please select a language before submitting.");
return;
}
if (checkedCount == 0) {
alert("Please select a language before submitting.");
return;
}

var Browser = jda.module("browser");

Expand Down Expand Up @@ -335,9 +336,11 @@


postObj.attributes.language = $("#englishChk").is(":checked") ? "English|" : "";
postObj.attributes.language += $("#japaneseChk").is(":checked") ? "Japanese|" : "";
postObj.attributes.language += $("#chineseChk").is(":checked") ? "Chinese|" : "";
postObj.attributes.language += $("#koreanChk").is(":checked") ? "Korean|" : "";
postObj.attributes.language += $("#japaneseChk").is(":checked") ? "Japanese|" : "";
postObj.attributes.language += $("#chineseChk").is(":checked") ? "Chinese|" : "";
postObj.attributes.language += $("#koreanChk").is(":checked") ? "Korean|" : "";
postObj.attributes.language += $("#frenchChk").is(":checked") ? "French|" : "";
postObj.attributes.language += $("#othersChk").is(":checked") ? "Others|" : "";

if ($("#lat").val() != "") {
postObj.media_geo_latitude = parseFloat($("#lat").val());
Expand Down
2 changes: 2 additions & 0 deletions web/js/loaders/form.js
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,8 @@ require(loadFiles, function () {
postObj.attributes.language += $("#japaneseChk").is(":checked") ? "Japanese|" : "";
postObj.attributes.language += $("#chineseChk").is(":checked") ? "Chinese|" : "";
postObj.attributes.language += $("#koreanChk").is(":checked") ? "Korean|" : "";
postObj.attributes.language += $("#frenchChk").is(":checked") ? "French|" : "";
postObj.attributes.language += $("#othersChk").is(":checked") ? "Others|" : "";

postObj.published = 0;
postObj.archive = "Seeds";
Expand Down