Skip to content

Commit

Permalink
Fixed #5503 - The JSON Editor tab caption appears untranslated (#5505)
Browse files Browse the repository at this point in the history
Co-authored-by: tsv2013 <[email protected]>
  • Loading branch information
tsv2013 and tsv2013 authored May 17, 2024
1 parent 739a677 commit 6a0313b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export class TabJsonEditorAcePlugin
creator.addPluginTab(
"editor",
this,
getLocString("ed.jsonEditor"),
"ed.jsonEditor",
"svc-tab-json-editor-ace"
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export class TextareaJsonEditorModel extends JsonEditorBaseModel {
textareaElement.value = textareaElement.value.substring(0, start) +
"\t" + textareaElement.value.substring(end);
textareaElement.selectionStart =
textareaElement.selectionEnd = start + 1;
textareaElement.selectionEnd = start + 1;
e.stopPropagation();
}
return true;
Expand All @@ -45,7 +45,7 @@ export class TextareaJsonEditorModel extends JsonEditorBaseModel {
this.isProcessingImmediately = false;
}
protected gotoError(at: number, row: number, column: number): void {
if(!this.textElement) return;
if (!this.textElement) return;
const el = this.textElement;
el.selectionStart = at;
el.selectionEnd = at;
Expand Down Expand Up @@ -86,14 +86,13 @@ export class TextareaJsonEditorModel extends JsonEditorBaseModel {

export class TabJsonEditorTextareaPlugin
extends TabJsonEditorBasePlugin
implements ICreatorPlugin
{
implements ICreatorPlugin {
constructor(creator: SurveyCreatorModel) {
super(creator);
creator.addPluginTab(
"editor",
this,
getLocString("ed.jsonEditor"),
"ed.jsonEditor",
"svc-tab-json-editor-textarea"
);
}
Expand Down

0 comments on commit 6a0313b

Please sign in to comment.