Ryan Lane has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/78214


Change subject: htmlform multiselect chosen: Replace lists
......................................................................

htmlform multiselect chosen: Replace lists

Rather than appending a new checkbox list and removing the old one,
replace the old list with the new one, to preserve ordering.

Change-Id: Idd77455bdbaf423e7a51cf3789460d1980f78922
---
M resources/mediawiki/mediawiki.htmlform.js
1 file changed, 1 insertion(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/14/78214/1

diff --git a/resources/mediawiki/mediawiki.htmlform.js 
b/resources/mediawiki/mediawiki.htmlform.js
index aedb28d..6b2f9bb 100644
--- a/resources/mediawiki/mediawiki.htmlform.js
+++ b/resources/mediawiki/mediawiki.htmlform.js
@@ -103,8 +103,7 @@
                $fieldLabelText.text( $oldContainer.find( '.mw-label label' 
).text() );
                $fieldLabel.append( $fieldLabelText );
                $container.prepend( $fieldLabel );
-               $oldContainer.parent().append( $container );
-               $oldContainer.remove();
+               $oldContainer.replaceWith( $container );
                return $container;
        }
 

-- 
To view, visit https://gerrit.wikimedia.org/r/78214
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Idd77455bdbaf423e7a51cf3789460d1980f78922
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Ryan Lane <rl...@wikimedia.org>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to