Skip to content

Commit

Permalink
add translation for buttons: edit button
Browse files Browse the repository at this point in the history
  • Loading branch information
Nriver committed Jul 31, 2024
1 parent 75e8a6c commit d84f438
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/public/app/widgets/buttons/edit_button.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import OnClickButtonWidget from "./onclick_button.js";
import appContext from "../../components/app_context.js";
import attributeService from "../../services/attributes.js";
import protectedSessionHolder from "../../services/protected_session_holder.js";
import { t } from "../../services/i18n.js";

export default class EditButton extends OnClickButtonWidget {
isEnabled() {
Expand All @@ -14,7 +15,7 @@ export default class EditButton extends OnClickButtonWidget {
super();

this.icon("bx-edit-alt")
.title("Edit this note")
.title(t("edit_button.edit_this_note"))
.titlePlacement("bottom")
.onClick(widget => {
this.noteContext.viewScope.readOnlyTemporarilyDisabled = true;
Expand Down
3 changes: 3 additions & 0 deletions src/public/translations/cn/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -555,5 +555,8 @@
},
"create_pane_button": {
"create_new_split": "拆分面板"
},
"edit_button": {
"edit_this_note": "编辑此笔记"
}
}
3 changes: 3 additions & 0 deletions src/public/translations/en/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -556,5 +556,8 @@
},
"create_pane_button": {
"create_new_split": "Create new split"
},
"edit_button": {
"edit_this_note": "Edit this note"
}
}

0 comments on commit d84f438

Please sign in to comment.