Skip to content

Commit

Permalink
Merge branch 'tangram.i18next' of https://github.com/VishnuVardhanBR/…
Browse files Browse the repository at this point in the history
…sugarizer into pr/1437
  • Loading branch information
Lionel Laské committed Jan 3, 2024
2 parents b198cb1 + 362bf62 commit 10be436
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion activities/Tangram.activity/js/DatasetList.js
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ var DatasetList = {
computed: {
currentCategoryTitle: function () {
let ct = this.$root.SugarL10n.dictionary ? this.$root.SugarL10n.dictionary["Data" + this.dataSetHandler.currentCategories[0].replace(/ /g, "")] : null;
let categoryTitle = ct ? ct.textContent : this.dataSetHandler.currentCategories[0];
let categoryTitle = ct ? ct : this.dataSetHandler.currentCategories[0];
return categoryTitle;
}
},
Expand Down
2 changes: 1 addition & 1 deletion activities/Tangram.activity/js/SettingEditor.js
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ var SettingEditor = {

currentCategoryTitle: function() {
let ct = this.$root.SugarL10n.dictionary ? this.$root.SugarL10n.dictionary["Data" + this.dataSetHandler.currentCategories[0].replace(/ /g, "")] : null;
let categoryTitle = ct ? ct.textContent : this.dataSetHandler.currentCategories[0];
let categoryTitle = ct ? ct : this.dataSetHandler.currentCategories[0];
return categoryTitle;
}
},
Expand Down
2 changes: 1 addition & 1 deletion activities/Tangram.activity/js/activity.js
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ var app = new Vue({
for (var i = 0; i < this.DataSetHandler.AllCategories.length; i++) {
let index = this.DataSetHandler.currentCategories.findIndex(ele => ele === this.DataSetHandler.AllCategories[i]);
let ct = this.SugarL10n.dictionary ? this.SugarL10n.dictionary["Data" + this.DataSetHandler.AllCategories[i].replace(/ /g, "")] : null;
let categoryTitle = ct ? ct.textContent : this.DataSetHandler.AllCategories[i];
let categoryTitle = ct ? ct : this.DataSetHandler.AllCategories[i];
categoryButtonsContent += `<div id="category-button-` + (i + 1) + `" tangramcategory="` + this.DataSetHandler.AllCategories[i] + `" class="palette-item` + (index !== -1 ? ` palette-item-selected` : ``) + `">` + categoryTitle + `</div>`;
if (this.DataSetHandler.AllCategories[i] === this.tangramCategories[0]) {
changeCategory = false;
Expand Down

0 comments on commit 10be436

Please sign in to comment.