The switch to source mode code path was causing onSerializeComplete to
be called, which accesses this.saveDialog because it assumes it's being
called from onSaveDialogReview.
In fact, onSaveDialogReview was calling it twice, once as the callback
it passes to serialize() and once in response to the serializeComplete
event. Cleaned this up by renaming the function and removing the
event binding, so it's now only called once and only for reviewing
changes to new pages, not in the switch to source mode code path.
Bug: 62544
Change-Id: I86eea57806a20408c8dc89a234c39cae1d969bca
When an image is smaller than the default size, the placeholder 'default'
value will be the image's actual size. This means that if a user selects
default thumb size for the image, it won't be changed unless the original
size is bigger than the default. Also adjusted so that default size limits
width only, and doesn't act as a bounding box on size change.
Bug: 62293
Change-Id: I8341776794843ff63a93bedeadf5921851c57a26
Initially we were only deploying to $wgContentNamespaces, but it's highly likely
that users will want to edit their own user pages in VE anyway. Note that this is
how it's been deployed for Wikimedia for a year now.
Additionally, this helps fix a bug in the browser tests that assumed NS_USER was
a VE-able namespace when that was only true in production config, and not for new
wikis (such as created during automated setup).
Bug: 57104
Change-Id: Icebc24f82fb49e9e80388b6202efa366360ce33c
This can be overriden in subclasses (such as MobileViewTarget) so that
we can customize the way the surface is created.
Change-Id: Id17695c8c75c7ae6c549f915625667389aad5f2f
Make sure the magnify button in the caption is properly shown or
hidden when image type changes. The magnify icon will always be
built, but will be shown and hidden using CSS rules.
Bug: 62139
Change-Id: Ib9a4569239ed70d16a153fb0823e283203fba1d4
New changes:
2074a5d Fix application of slug focus classes
9f4ab6a Have Protected/ResizableNode respond to rerender event
9d7a290 Rerender focusedNode after slug collapse
de7d9ab Use en-us spelling 'focused'
7fae4c2 Add missing returns documentation to getSurfaceFragment
5177898 Remove unneeded assignment
a1c12c2 Localisation updates from https://translatewiki.net.
5648139 Localisation updates from https://translatewiki.net.
548728a Restore error box to VE demo page
684e55d Localisation updates from https://translatewiki.net.
3c4a081 ve.ce.Node: Change slug color from darker grey to lighter blue/grey
Change-Id: Icb20d78bb1fe65dd9107e43317148d4990bcfc6b
While the documentation is unclear, it seems that the 'thumbsize' in
$wgDefaultUserOptions is setting up width limit rather than a general
bounding box.
Things that are adapted in this fix:
* Only resize the image if the image is bigger than default and marked
as default size.
* Only limit width, even if the image is tall.
* Add rounding to calculated height value.
* Make sure new images follow these rules as well on insertion.
Bug: 62293
Bug: 62279
Change-Id: I37525bf3480bb1da8b0538f9b38576616aabbfa6
* CODING.md was renamed to CONTRIBUTING.md a while back.
* Fix link to upstream CONTRIBUTING.md (was pointing at itself,
follows-up 902f1b7).
Change-Id: I465642b842fb2724a57a5c4d93525a9bf46b39ca
The experience should be consistent between mobile and desktop.
We should explore re-styling these buttons to look like
Ib3c94d19231b018a509b78269001223ad0568795 in desktop as well
at a later date.
Change-Id: Ic9e4c5d12c3c75fcb195432c9155ec0a7eecac04
New changes:
3349216 Bold/italic icons for fa
e1d8ebd Add oojs-ui-apex.css to modules.json
beb5e43 Update OOjs UI to v0.1.0-pre (8b13d2b7f7)
Change-Id: I6f46569ed7a95273c72f9629e02f7d7a3fbf4870
Fix a bug in MediaEditDialog that resulted from sync issues when the
'select' event is fired for OO.ui.ButtonSelectWidget widgets.
Use the details of the selected item given from the event rather than
checking the state of the widget with getSelectedItem().
Change-Id: Ifbbf722ff374e10b680a6b55ab99f5fc86480c40
Split tracking out of the base target and from viewPageTarget
Primary reasons for this change:
* Makes it possible to resolve an issue with tracking in mobile
* Lets us reuse the viewPage save workflow tracking
* Support existing and new targets with tracking
* Simplification of target classes
Change-Id: I036e4f2129d929db0a3b9a4baa87c946a4b194a9
Not removing the existing message for "Transclusion" for now in case
that's needed later.
Bug: 55434
Change-Id: I0ee722e821051970b4a445b5a7a0e93f144f3185
* Automatically select single mode when possible
* Allow dynamic switching when possible
* Hide most of the controls and information when in single mode
* Allow parameter model to be instantiated without name and value args
* Place add param buttons at the bottom of template and param pages
which are only visible when in single mode and on the last page
Change-Id: Iaffbf1863b808c8089dfcf09a976d165f28c8b74
This doesn't really fix the underlying issue that the
width and height are overridden to be the default size
in the DM even if that's wrong (in the case the image's
original size is smaller than the default thumbnail size),
but it fixes the DOM corruption by storing the original
width&height and restoring them if the image still has
defaultSize=true on the way out.
Bug: 62172
Change-Id: Iaee798c5bb501310e52d0ac832b2e7cd833fc438
New changes:
08d1b0b Alignment icons
0e418e8 Update constructors of inspectors and dialogs as per changes in I345d6e6
c81252c Update OOjs UI to v0.1.0-pre (e1b23620c0)
Change-Id: I6e904dcce0116c34373fda4a8fe86f7603bfea59