Fix RTL button. Rename Edit Mode label to Markup.

This commit is contained in:
Bart Kamphorst
2019-08-19 22:38:54 +02:00
parent 175c0ceab5
commit c991149422
2 changed files with 5 additions and 4 deletions
@@ -208,7 +208,8 @@
} }
if ( EditorHas.dir() ) { if ( EditorHas.dir() ) {
$('#function-dir').click(function( e ) { $('#function-text-direction').click(function( e ) {
e.preventDefault();
switchRtl(!window.ace_editor.session.$bidiHandler.$isRtl); switchRtl(!window.ace_editor.session.$bidiHandler.$isRtl);
}); });
} }
@@ -570,7 +571,7 @@
* @return boolean * @return boolean
*/ */
dir: function() { dir: function() {
return ($('#gollum-editor #function-dir').length ); return ($('#gollum-editor #function-text-direction').length );
}, },
@@ -634,7 +635,7 @@
$(this).click( FunctionBar.evtFunctionButtonClick ); $(this).click( FunctionBar.evtFunctionButtonClick );
$(this).removeClass('disabled'); $(this).removeClass('disabled');
} }
else if ( !['function-help', 'function-dir'].includes( $(this).attr('id') ) ) { else if ( !['function-help', 'function-text-direction'].includes( $(this).attr('id') ) ) {
$(this).addClass('disabled'); $(this).addClass('disabled');
} }
}); });
+1 -1
View File
@@ -55,7 +55,7 @@
<option>vim</option> <option>vim</option>
<option>emacs</option> <option>emacs</option>
</select> </select>
<label for="format">Edit Mode</label> <label for="format">Markup</label>
<select id="wiki_format" name="format" class="form-select"> <select id="wiki_format" name="format" class="form-select">
{{#formats}} {{#formats}}
{{#enabled}} {{#enabled}}