feat: show theme change alert for 3 seconds only

This commit is contained in:
Shivam Mishra 2020-09-18 14:17:00 +05:30
parent 9681147bca
commit fef599f3f3

View file

@ -65,15 +65,15 @@ frappe.Application = Class.extend({
theme: new_theme
}).then(() => {
document.body.dataset.theme = new_theme.toLowerCase();
frappe.show_alert("Theme Changed");
frappe.show_alert("Theme Changed", 3);
})
}
})
this.set_rtl();
if(frappe.boot) {
if(localStorage.getItem("session_last_route")) {
if (frappe.boot) {
if (localStorage.getItem("session_last_route")) {
window.location.hash = localStorage.getItem("session_last_route");
localStorage.removeItem("session_last_route");
}