Last modified: 2014-09-23 15:50:24 UTC
Created attachment 15791 [details] screenshot showing 3000x2078px PNG embed The HTML embed mode in the 'use' dialog seems to embed the full-resolution original image, which can be unconscionably huge. See attached screenshot & URL.
Well, you have selected "Original size"... I guess it should not be the default for embedding, though.
Yes, it's the default... which seems unwise for multi-megapixel images. :)
This is pretty rough on the unsuspecting user. It's unclear to me why the HTML output is not directly equivalent to the wikitext --> HTML output (i.e., the HTML we provide to users via MediaViewer's embed feature should try to be identical to the HTML we provide to users already via "[[File:Foo.png]]"-type syntax). Currently the two HTML outputs are not directly equivalent.
(In reply to Tisza Gergő from comment #1) > Well, you have selected "Original size"... If I go to <https://en.wikipedia.org/wiki/State_of_the_Union#mediaviewer/File:Livingood_Obama_State_of_the_Union_2011.jpg>, click "Use this file", click "Embed", click "HTML", and then select "small 217 x 145 px" from the drop-down menu, the suggested embed HTML is: --- <p><a href="https://commons.wikimedia.org/wiki/File:Livingood_Obama_State_of_the_Union_2011.jpg#mediaviewer/File:Livingood_Obama_State_of_the_Union_2011.jpg"><img src="https://upload.wikimedia.org/wikipedia/commons/6/65/Livingood_Obama_State_of_the_Union_2011.jpg" alt="Livingood Obama State of the Union 2011.jpg" height="145" width="217"></a><br>"<a href="https://commons.wikimedia.org/wiki/File:Livingood_Obama_State_of_the_Union_2011.jpg#mediaviewer/File:Livingood_Obama_State_of_the_Union_2011.jpg">Livingood Obama State of the Union 2011</a>" by <a href="//commons.wikimedia.org/wiki/Pete_Souza" title="Pete Souza" class="mw-redirect">Pete Souza</a> (<a href="//en.wikipedia.org/wiki/Executive_Office_of_the_President_of_the_United_States" class="extiw" title="w:Executive Office of the President of the United States">Executive Office of the President of the United States</a>) - <a rel="nofollow" class="external free" href="http://www.whitehouse.gov/photos-and-video/photogallery/2011-state-union-address">http://www.whitehouse.gov/photos-and-video/photogallery/2011-state-union-address</a>. Licensed under Public domain via <a href="//commons.wikimedia.org/wiki/">Wikimedia Commons</a>.</p> --- "<img src="https://upload.wikimedia.org/wikipedia/commons/6/65/Livingood_Obama_State_of_the_Union_2011.jpg" alt="Livingood Obama State of the Union 2011.jpg" height="145" width="217">" is pretty clearly wrong. You're embedding the full-size image and resizing it in-browser. This is a major bug.
Created attachment 16492 [details] Screenshot of <https://en.wikipedia.org/wiki/State_of_the_Union#mediaviewer/File:Livingood_Obama_State_of_the_Union_2011.jpg>, 2014-09-16
(In reply to MZMcBride from comment #5) > Created attachment 16492 [details] > Screenshot of > <https://en.wikipedia.org/wiki/State_of_the_Union#mediaviewer/File:Livingood_Obama_State_of_the_Union_2011.jpg>, 2014-09-16 I'm well aware that the drop-down menu says "Original file <span garbage>", but it's clearly having issues (I'll file further bug reports) and the HTML markup makes it clear that the small option has been selected by the user.
Currently we fetch thumbnail URLs when the user first selects the given file/size combination, which comes with a lot of quirks (such as the embed text appearing seconds later than the menu select action). For a decent fix, we would want multi-size support in imageinfo.