Browse Source

Fix editor toggle on touchscreens

tags/v1.2.0
Skylar Ittner 7 months ago
parent
commit
978445d551
2 changed files with 6 additions and 10 deletions
  1. 5
    9
      www/js/settings.js
  2. 1
    1
      www/routes.js

+ 5
- 9
www/js/settings.js View File

@@ -5,12 +5,8 @@
*/


/**
* Toggle the setting to use the alternate note editor.
* @returns {undefined}
*/
function toggleeditor() {
var toggle = app.toggle.get('.item-content[data-setting=editor] .toggle');
console.log(toggle.checked);
localStorage.setItem("alternateeditor", toggle.checked);
}
$('.item-content[data-setting=editor] .toggle input').on("change", function () {
var checked = $(this).prop('checked');
console.log(checked);
localStorage.setItem("alternateeditor", checked);
})

+ 1
- 1
www/routes.js View File

@@ -89,7 +89,7 @@ var routes = [
text: "Turn on if you're having issues editing notes.",
toggle: true,
checked: localStorage.getItem("alternateeditor") == "true",
onclick: "toggleeditor();"
onclick: ""
},
{
setting: "versions",

Loading…
Cancel
Save