Loading package.json +1 −1 Original line number Diff line number Diff line Loading @@ -19,6 +19,6 @@ "openseadragon": "^2.4.1", "popper.js": "^1.14.7", "readline": "^1.3.0", "xmldom": "^0.1.27" "xmldom": "^0.1.31" } } plugins/equations/equations.js +11 −4 Original line number Diff line number Diff line Loading @@ -18,10 +18,17 @@ class EquationPlugin extends Plugin{ //appends text options components $("#options-list").append("<li role='separator' class='divider'></li><li><a href='#'>" +"<input id='toggle_pb' type='radio' name='equations' onchange='toggleModernEquations(false)' checked=''>Afficher les images de l\'édition originale</a></li>"); $("#options-list").append("<li><a href='#'><input id='toggle_pb' type='radio' name='equations'" + " onchange='toggleModernEquations(true)' checked='' >Afficher les équations modernisées en mode texte</a></li><li role='separator' class='divider'></li>"); +"<input id='toggle_equations_on' type='radio' name='equations' checked>Afficher les images de l\'édition originale</a></li>"); $("#options-list").append("<li><a href='#'><input id='toggle_equations_off' type='radio' name='equations'>"+ "Afficher les équations modernisées en mode texte</a></li><li role='separator' class='divider'></li>"); this.setEquationsVisible(); let self = this; $('#toggle_equations_on').change(function(e){ self.toggleModernEquations(true); }); $('#toggle_equations_off').change(function(e){ self.toggleModernEquations(false); }); } Loading @@ -31,7 +38,7 @@ class EquationPlugin extends Plugin{ } toggleModernEquations(on){ console.log("Set modern equations visible =" + on) //console.log("Set modern equations visible =" + on) if(on){ $(".tex").show(); $(".formula").hide(); Loading Loading
package.json +1 −1 Original line number Diff line number Diff line Loading @@ -19,6 +19,6 @@ "openseadragon": "^2.4.1", "popper.js": "^1.14.7", "readline": "^1.3.0", "xmldom": "^0.1.27" "xmldom": "^0.1.31" } }
plugins/equations/equations.js +11 −4 Original line number Diff line number Diff line Loading @@ -18,10 +18,17 @@ class EquationPlugin extends Plugin{ //appends text options components $("#options-list").append("<li role='separator' class='divider'></li><li><a href='#'>" +"<input id='toggle_pb' type='radio' name='equations' onchange='toggleModernEquations(false)' checked=''>Afficher les images de l\'édition originale</a></li>"); $("#options-list").append("<li><a href='#'><input id='toggle_pb' type='radio' name='equations'" + " onchange='toggleModernEquations(true)' checked='' >Afficher les équations modernisées en mode texte</a></li><li role='separator' class='divider'></li>"); +"<input id='toggle_equations_on' type='radio' name='equations' checked>Afficher les images de l\'édition originale</a></li>"); $("#options-list").append("<li><a href='#'><input id='toggle_equations_off' type='radio' name='equations'>"+ "Afficher les équations modernisées en mode texte</a></li><li role='separator' class='divider'></li>"); this.setEquationsVisible(); let self = this; $('#toggle_equations_on').change(function(e){ self.toggleModernEquations(true); }); $('#toggle_equations_off').change(function(e){ self.toggleModernEquations(false); }); } Loading @@ -31,7 +38,7 @@ class EquationPlugin extends Plugin{ } toggleModernEquations(on){ console.log("Set modern equations visible =" + on) //console.log("Set modern equations visible =" + on) if(on){ $(".tex").show(); $(".formula").hide(); Loading