Last modified: 2014-04-07 17:27:36 UTC
In HTML5 <big> is deprecated, so I do not see any reason to have a button for it in the toolbar. The probably only reason why it is there is consistency with <small>, but since HTML5 isn't consistent in that point the toolbar needn't to be either.
FYI, the button code is defined at https://gerrit.wikimedia.org/r/gitweb?p=mediawiki/extensions/WikiEditor.git;a=blob;f=modules/jquery.wikiEditor.toolbar.config.js;hb=7adaa5434045fba764688fedb20820e7f2be4283#l359
Instead of removing the button, its code could be changed to this: ------------------------------------------------------------------ 'big': { 'labelMsg': 'wikieditor-toolbar-tool-big', 'type': 'button', 'icon': 'format-big.png', 'offset': [2, 2], 'action': { 'type': 'encapsulate', 'options': { 'pre': "<span style=\"font-size: larger;\">", 'periMsg': 'wikieditor-toolbar-tool-big-example', 'post': "</span>" } } }, ------------------------------------------------------------------ A gadget could try to do this until the bug is fixed, but ------------------------------------------------------------------ $( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', { 'section': 'advanced', 'group': 'size', 'tool': 'big' } ).wikiEditor( 'addToToolbar', { 'section': 'advanced', 'group': 'size', 'tools': { 'big': { 'labelMsg': 'wikieditor-toolbar-tool-big', 'type': 'button', 'icon': 'format-big.png', 'offset': [2, 2], 'action': { 'type': 'encapsulate', 'options': { 'pre': "<span style=\"font-size: larger;\">", 'periMsg': 'wikieditor-toolbar-tool-big-example', 'post': "</span>" } } } } } ); ------------------------------------------------------------------ would put the button in the wrong position...
(In reply to comment #2) > A gadget could try to do this until the bug is fixed Here is another way: ------------------------------------------------------------------ // Workaround for [[bugzilla:38487]] function fixBigButton(){ $( '.tool-button[rel=big]' ) .off( 'click' ) .on( 'click', function( e ){ e.preventDefault(); $( '#wpTextbox1' ).textSelection( 'encapsulateSelection', { 'pre': '<span style="font-size: larger;">', 'peri': mw.msg( 'wikieditor-toolbar-tool-big-example' ), 'post': '</span>' } ); } ); } if ( $.inArray( mw.config.get( 'wgAction' ), ['edit', 'submit'] ) !== -1 ) { mw.loader.using( 'user.options', function () { if ( mw.user.options.get('usebetatoolbar') ) { mw.loader.using( [ 'jquery.textSelection', 'ext.wikiEditor.toolbar' ], function () { $( fixBigButton ); } ); } } ); } ------------------------------------------------------------------
Gerrit change #53010
Wikitext is not HTML. I'm not sure people actually want uglier wikitext.
(In reply to comment #5) > Wikitext is not HTML. I'm not sure people actually want uglier wikitext. Indeed, this should probably be rejected: I suggest WONTFIX. (Sorry Rahul for the unclear status of this bug.) For instance, I know some Wikimedia wikis where attempts at replacing simple markup with "more correct" HTML by bot were soundly and consistently rejected and forbidden. Wikis which want uglier wikitext can use Helder's solutions above, or bots.
(In reply to comment #6) Its okay,i am happy to contribute in any form!
(In reply to comment #5) > [...] I'm not sure people actually want uglier wikitext. My suggestion was to remove <big> completely, not to replace it with (I agree with you) ugly HTML. I can only see to reasons to user bigger font size than usual: * headlines, these should use == ... ==, not <big> * texts in other scripts that are hard to read in normal font size (like Arabic), these should have a lang="..." attribute, handle bidi correctly, etc. Adding some CSS to make them a bit bigger doesn't make things worse (it's inside a template in most cases anyway) This seems to be not only my opinion: en.wikipedia adds a button for <small> to the old toolbar, but not one for <big> [1], the same is true for a gadget on de.wikipedia [2] [1] [[MediaWiki:Common.js/edit.js]] [2] [[de:Wikipedia:Helferlein/Extra-Editbuttons]]
Change 53010 abandoned by Bartosz Dziewoński: (Bug 38487) Replaced the <big> with <span> in jquery.wikiEditor.toolbar.config.js Reason: Per consensus on the bug. https://gerrit.wikimedia.org/r/53010
*** Bug 24488 has been marked as a duplicate of this bug. ***