chore: remove pointless template strings

This commit is contained in:
Ankush Menat 2022-08-04 15:24:34 +05:30
parent ec8f20c097
commit 16fdff8231
7 changed files with 14 additions and 14 deletions

View file

@ -281,7 +281,7 @@ frappe.ui.form.QuickEntryForm = class QuickEntryForm {
render_edit_in_full_page_link() {
var me = this;
this.dialog.add_custom_action(`${__("Edit Full Form")}`, () => me.open_doc(true));
this.dialog.add_custom_action(__("Edit Full Form"), () => me.open_doc(true));
}
set_defaults() {

View file

@ -142,10 +142,10 @@ frappe.views.ListViewSelect = class ListViewSelect {
setup_dropdown_in_sidebar(view, items, default_action) {
if (!this.sidebar) return;
const views_wrapper = this.sidebar.sidebar.find(".views-section");
views_wrapper.find(".sidebar-label").html(`${__(view)}`);
views_wrapper.find(".sidebar-label").html(__(view));
const $dropdown = views_wrapper.find(".views-dropdown");
let placeholder = `${__("Select {0}", [__(view)])}`;
let placeholder = __("Select {0}", [__(view)]);
let html = ``;
if (!items || !items.length) {

View file

@ -43,7 +43,7 @@ export default class Header extends Block {
frappe.utils.icon("drag", "xs"),
null,
"drag-handle",
`${__("Drag")}`,
__("Drag"),
null,
$widget_control
);

View file

@ -133,7 +133,7 @@ export default class Paragraph extends Block {
frappe.utils.icon("drag", "xs"),
null,
"drag-handle",
`${__("Drag")}`,
__("Drag"),
null,
$para_control
);

View file

@ -41,7 +41,7 @@ export default class Spacer extends Block {
frappe.utils.icon("drag", "xs"),
null,
"drag-handle",
`${__("Drag")}`,
__("Drag"),
null,
$widget_control
);

View file

@ -222,7 +222,7 @@ frappe.views.Workspace = class Workspace {
}
let page = this.get_page_to_show();
this.page.set_title(`${__(page.name)}`);
this.page.set_title(__(page.name));
this.update_selected_sidebar(this.current_page, false); //remove selected from old page
this.update_selected_sidebar(page, true); //add selected on new page
@ -476,7 +476,7 @@ frappe.views.Workspace = class Workspace {
frappe.utils.icon("duplicate", "sm"),
() => this.duplicate_page(item),
"duplicate-page",
`${__("Duplicate Workspace")}`,
__("Duplicate Workspace"),
null,
sidebar_control
);
@ -485,7 +485,7 @@ frappe.views.Workspace = class Workspace {
frappe.utils.icon("drag", "xs"),
null,
"drag-handle",
`${__("Drag")}`,
__("Drag"),
null,
sidebar_control
);

View file

@ -30,7 +30,7 @@ export default class Widget {
frappe.utils.icon("drag", "xs"),
null,
"drag-handle",
`${__("Drag")}`,
__("Drag"),
null,
this.action_area
);
@ -43,7 +43,7 @@ export default class Widget {
this.footer.css("opacity", 0.5);
}
const classname = this.hidden ? "fa fa-eye" : "fa fa-eye-slash";
const title = this.hidden ? `${__("Show")}` : `${__("Hide")}`;
const title = this.hidden ? __("Show") : __("Hide");
frappe.utils.add_custom_button(
`<i class="${classname}" aria-hidden="true"></i>`,
() => this.hide_or_show(),
@ -61,7 +61,7 @@ export default class Widget {
frappe.utils.icon("edit", "xs"),
() => this.edit(),
"edit-button",
`${__("Edit")}`,
__("Edit"),
null,
this.action_area
);
@ -158,7 +158,7 @@ export default class Widget {
this.refresh();
}
const title = this.width == "Full" ? `${__("Collapse")}` : `${__("Expand")}`;
const title = this.width == "Full" ? __("Collapse") : __("Expand");
this.resize_button.attr("title", title);
}
@ -177,7 +177,7 @@ export default class Widget {
this.show_or_hide_button.empty();
const classname = this.hidden ? "fa fa-eye" : "fa fa-eye-slash";
const title = this.hidden ? `${__("Show")}` : `${__("Hide")}`;
const title = this.hidden ? __("Show") : __("Hide");
$(`<i class="${classname}" aria-hidden="true" title="${title}"></i>`).appendTo(
this.show_or_hide_button