mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-15 02:23:58 +00:00
Merge "Avoid jQuery.parseHTML"
This commit is contained in:
commit
d040645244
|
@ -186,7 +186,7 @@ ve.init.mw.DesktopArticleTarget.prototype.getEditableContent = function () {
|
|||
$editableContent = $( '#mw-imagepage-content' );
|
||||
if ( !$editableContent.length ) {
|
||||
// No image content, file doesn't exist, or is on Commons?
|
||||
$editableContent = $( '<div id="mw-imagepage-content">' );
|
||||
$editableContent = $( '<div>' ).attr( 'id', 'mw-imagepage-content' );
|
||||
$before = $( '.sharedUploadNotice, #mw-imagepage-nofile' );
|
||||
if ( $before.length ) {
|
||||
$before.first().after( $editableContent );
|
||||
|
|
|
@ -1725,7 +1725,7 @@ ve.init.mw.ArticleTarget.prototype.submit = function ( wikitext, fields ) {
|
|||
}
|
||||
// Save DOM
|
||||
this.submitting = true;
|
||||
$form = $( '<form method="post" enctype="multipart/form-data" style="display: none;"></form>' );
|
||||
$form = $( '<form>' ).attr( { method: 'post', enctype: 'multipart/form-data' } ).addClass( 'oo-ui-element-hidden' );
|
||||
params = ve.extendObject( {
|
||||
format: 'text/x-wiki',
|
||||
model: 'wikitext',
|
||||
|
|
|
@ -415,7 +415,7 @@ ve.ui.MWSaveDialog.prototype.showMessage = function ( name, message, options ) {
|
|||
if ( options.wrap === undefined ) {
|
||||
options.wrap = 'warning';
|
||||
}
|
||||
$message = $( '<div class="ve-ui-mwSaveDialog-message"></div>' );
|
||||
$message = $( '<div>' ).addClass( 've-ui-mwSaveDialog-message' );
|
||||
if ( options.wrap !== false ) {
|
||||
$message.append( $( '<p>' ).append(
|
||||
// visualeditor-savedialog-label-error
|
||||
|
|
|
@ -37,7 +37,7 @@ ve.ui.MWAceEditorWidget = function VeUiMWAceEditorWidget( config ) {
|
|||
this.autocomplete = config.autocomplete || 'none';
|
||||
this.autocompleteWordList = config.autocompleteWordList || null;
|
||||
|
||||
this.$ace = $( '<div dir="ltr">' );
|
||||
this.$ace = $( '<div>' ).attr( 'dir', 'ltr' );
|
||||
this.editor = null;
|
||||
// Initialise to a rejected promise for the setValue call in the parent constructor
|
||||
this.loadingPromise = $.Deferred().reject().promise();
|
||||
|
|
Loading…
Reference in a new issue