Valider 03d55463 rédigé par marcimat's avatar marcimat
Parcourir les fichiers

Des événements input (comme a intégré markitup sur les boutons) lorsqu'on...

Des événements input (comme a intégré markitup sur les boutons) lorsqu'on bloque le comportement des touches "return".
parent 85504196
Chargement en cours
Chargement en cours
Chargement en cours
Chargement en cours
+9 −0
Numéro de ligne d'origine Numéro de ligne de diff Ligne de diff
@@ -801,13 +801,22 @@
							if (ctrlKey === true) {  // Enter + Ctrl
								ctrlKey = false;
								markup(options.onCtrlEnter);
								if (!options.onCtrlEnter.keepDefault) {
									textarea.dispatchEvent(new Event('input'));
								}
								return options.onCtrlEnter.keepDefault;
							} else if (shiftKey === true) { // Enter + Shift
								shiftKey = false;
								markup(options.onShiftEnter);
								if (!options.onShiftEnter.keepDefault) {
									textarea.dispatchEvent(new Event('input'));
								}
								return options.onShiftEnter.keepDefault;
							} else { // only Enter
								markup(options.onEnter);
								if (!options.onEnter.keepDefault) {
									textarea.dispatchEvent(new Event('input'));
								}
								return options.onEnter.keepDefault;
							}
						}