Commit graph

539 commits

Author SHA1 Message Date
Roan Kattouw efe925067c Followup 0f45399: move some forgotten files out of mwcore
Transclusion/TemplateModel classes to mwtransclusion, CE
LinkAnnotations to mwlink.

Change-Id: I4fdef01ce50a78e109a6297d287da49ca8e41d08
2014-02-26 17:42:00 -08:00
jenkins-bot 66df1ec1b5 Merge "Track edits where user switched into wikitext editor from VE" 2014-02-27 01:35:56 +00:00
Krenair 952a239866 Track edits where user switched into wikitext editor from VE
By adding a tag called 'visualeditor-switched'.

Bug: 56465
Change-Id: I1426d300499b59ca55c9b97fc1560f4adbfa9295
2014-02-27 01:33:40 +00:00
James D. Forrester 532077b57f Don't use a changeable tooltip for edit notices
We can't change tooltips once they're set for buttons like this (they're
static), so for values that can change we need to use language that does
not need plurals.

Bug: 61891
Change-Id: I78e5576e348ee92bc39315fd494b3398ae2c14bf
2014-02-27 01:20:43 +00:00
James D. Forrester 0f45399082 Split up ext.visualEditor.mwcore into smaller parts
Core retains core functionality, including text styling and architectural
items like dialogs.

The new modules are:
* mwformatting
* mwimage
* mwlink
* mwmeta
* mwreference
* mwtransclusion

The new modules are loaded in ViewPageTarget (for desktop), except for
mwlinks which is included from MWTarget (for desktop and mobile), per the
needs of the Mobile team.

Also, mwgallery was moved to desktop-only loading status.

Some styles which were loaded in mwcore but only used in modules is now
loaded in said modules.

This does not split up ext.visualEditor.core yet, which is left as an
exercise for the fool-hardy.

Bug: 61075
Change-Id: I6374854eaa13af824c11078d2f7004dc8a211a30
2014-02-26 16:31:15 -08:00
jenkins-bot 84fb866ed7 Merge "Set up wiki-default image size" 2014-02-26 20:31:49 +00:00
Trevor Parscal e2f6d798b8 Rename MWTemplateParameter* classes to MWParameter*
* The name was getting super long, and the Template prefix doesn't
  appear to be important.
* Soon we will add a placeholder class, which would have been
  MWTemplateParameterPlaceholder, but now just MWParameterPlaceholder
  which seems a little less ridiculous.

Change-Id: Ie2dfe0d4c7b960cd554f89fa6340173e8786c88a
2014-02-26 10:54:45 +00:00
Moriel Schottlender b54575a797 Set up wiki-default image size
This commit makes several adjustments to make sure default size is being
handled correctly:

* Add wiki's default size configuration parameter to the
  VisualEditor.hooks.php file so it can be called from VE.
* Make sure new images are inserted with default size and are
  marked 'defaultSize = true' for the DM to handle.
* Force default size if 'defaultSize=true' in the DM
* Add a 'default|custom' switch to the media edit dialog for size
  inputs. When 'default' is chosen, the media size widget will be
  emptied, displaying its placeholders (default size)
* When the size widget's values are 0 it will automatically turn to
  default size values. If the value started default and the user
  typed in a size, it will automatically override default and use
  custom size.

Bug: 47804
Change-Id: Ib973ea2afa96090a4ba61b2b55ee63457f1329c1
2014-02-25 16:26:15 -05:00
Ed Sanders 0ca90d8965 Ensure VE init runs after mw.util.init
VE init sets up access keys in some cases, but they have not
been set to the correct string for the browser until mw.util.init
has been called, so add a dependency on mw.page.startup to the
init module.

Change-Id: I494b364b485e678122e7f235df88b80fb503fa94
2014-02-21 18:28:37 +00:00
Moriel Schottlender e2f06d4875 Revamp media edit dialog's position widget
Added checkbox to set position (left/center/right) or none if unchecked.
Also handle 'default' position based on the wiki direction.

Bug: 61155
Change-Id: Iddd78c98929759a13d2dc5a774e72b59cbe28c36
2014-02-20 15:47:23 -08:00
Krinkle 2dd888814a Revert "Converting ViewPageTarget CSS files to LESS"
We don't yet have any way to test or verify anything with less. Not the less
syntax, not the less compilation, not the resulting css code quality.

Using it at this point doesn't seem worth the cost of not having any of that.

This reverts commit 17ddf031fe.

Change-Id: I7e8ab90f7a9f77f5cf6d7baeab586d4e0332042e
2014-02-20 22:55:49 +00:00
kaldari 17ddf031fe Converting ViewPageTarget CSS files to LESS
Just doing simple nesting for now. No mix-ins or variables.

There are no actual style changes in this commit.

Change-Id: Ied29358d39703ca6d2c896c2d44d9cf397d51d4e
2014-02-20 13:55:29 -08:00
jenkins-bot 4a0674609b Merge "Split VE-MW's ve.ce.Node.css file into per-node files" 2014-02-20 21:48:07 +00:00
James D. Forrester c6bcc10d6c Split VE-MW's ve.ce.Node.css file into per-node files
Bug: 61075
Change-Id: I9bfa43e23c95a916ae082c33693f33492670445e
2014-02-20 13:44:03 -08:00
James D. Forrester 0390da9dbc Remove SyntaxHighlight code
Unused. Will move instead to the SyntaxHighlight extension.

Change-Id: If4d786b55aca45a517c098f3282ba553da0ceb9c
2014-02-20 11:59:37 -08:00
jenkins-bot 327380c501 Merge "Let users set __NEWEDITSECTION__ & __NONEWEDITSECTION__ status" 2014-02-20 03:23:33 +00:00
James D. Forrester ffbe2565bb Let users set __NEWEDITSECTION__ & __NONEWEDITSECTION__ status
Add a trinary option to the page settings pane of the meta dialog that
lets users set the page to have __NEWEDITSECTION__, __NONEWEDITSECTION__,
or neither (and so have default behaviour).

Bug: 57168
Change-Id: I3198409c6aaa4cbce7e26fd56d390ffc91e91eef
2014-02-19 19:21:49 -08:00
jenkins-bot 78bdbb4c43 Merge "Let users set __NOINDEX__ & __INDEX__ status" 2014-02-20 01:50:29 +00:00
James D. Forrester 051c3498ae Let users set __NOINDEX__ & __INDEX__ status
Add a trinary option to the page settings pane of the meta dialog that
lets users set the page to have __INDEX__, __NOINDEX__ or neither (and so
have the default behaviour).

Bug: 57167
Change-Id: I30d483b5b6c3df7ee56a52c744bbdc610a01873d
2014-02-19 17:48:03 -08:00
jenkins-bot 71984326d1 Merge "Show placeholder text in group input box on reference list dialog" 2014-02-20 00:43:57 +00:00
jenkins-bot 3e0a88c03d Merge "Add MW-specific keyboard shortcut help" 2014-02-19 23:57:45 +00:00
Ed Sanders 2ce113f0c7 Add MW-specific keyboard shortcut help
For now just accessKey+S for save.

Change-Id: Idf4fa31b98d1fa9ea62d9a9f2937ae7496a9a201
2014-02-19 23:53:22 +00:00
jenkins-bot 01570025d3 Merge "Show preview of edit summary in review screen" 2014-02-19 23:07:19 +00:00
Krenair 675d91b7e8 Show preview of edit summary in review screen
Bug: 42139
Change-Id: I0bbfd0dd993da67295dea47129ca9f398f318b64
2014-02-19 15:03:04 -08:00
jenkins-bot 0d2ea63596 Merge "Use accesskey=s on the save buttons" 2014-02-19 21:42:13 +00:00
kaldari 9f1179938c Move some skin styling from ve.ce.Node.css to a shared skin css file
The styling of the image thumbnails should be controlled at the
skin level, not by the generic VE styles. Moving the thumb/figure
styles from ve.ce.Node.css to ViewPageTarget-shared.css. Otherwise
no changes to the styles themselves.

Also adding minerva (the mobile skin) to the list of supported skins.

Bug: 60542
Change-Id: I67ab6d5b91cee7e587f61df26e7dae74c1068788
2014-02-19 13:30:30 -08:00
Krenair ec8234f183 Use accesskey=s on the save buttons
Bug: 50897
Change-Id: I31d6b9ea065b3be85ed07fba7437bed71010512b
2014-02-19 19:34:13 +00:00
Krenair 9c40de10b1 Show placeholder text in group input box on reference list dialog
Set to "General references" for now.

Bug: 59180
Change-Id: I39c3692c71674ff656617500aa22ec7191db2e96
2014-02-18 20:56:45 +00:00
jenkins-bot 4944dff419 Merge "Let users set #REDIRECT and __STATICREDIRECT__ status" 2014-02-14 03:46:12 +00:00
jenkins-bot 912fda938d Merge "Explain what the number on the edit summary screen means" 2014-02-13 01:09:33 +00:00
James D. Forrester 5af9f61520 Let users set #REDIRECT and __STATICREDIRECT__ status
Adds setting and unsetting the #REDIRECT status of the page from the page
settings pane of the meta dialog, and toggle whether this is a static
redirect (i.e., it is not automatically changed when its target is moved).

If the page has a redirect set, the meta dialog will be shown on opening
the page so that users can adjust the redirect more swiftly.

Bug: 47328
Bug: 50878
Bug: 57173
Change-Id: Ibd89cf04486799f292b9fd045dae5bc23fcf6fd4
2014-02-12 15:24:12 -08:00
James D. Forrester e4f983356b Add tooltips to the drop-down menus explaining what they do
Needs Ic967b88d55daf48d365487e17f76488b3f02c60f to work properly.

Bug: 59719
Change-Id: I449be926e830de241a870d96bf30c835f60ca77d
2014-02-12 22:07:24 +00:00
Krenair c4903ac684 Explain what the number on the edit summary screen means
Bug: 50902
Change-Id: Ic548e624c1e7375b3151cc9d2f051a5bc665c759
2014-02-09 03:14:09 +00:00
jenkins-bot 6907654de1 Merge "Add image type change to media edit dialog" 2014-02-08 00:45:49 +00:00
Moriel Schottlender 19c584d166 Add image type change to media edit dialog
Adding a type change to the media edit dialog. Also changing SelectWidgets
to ButtonSelectWidgets for consistency.

Bug: 38129
Change-Id: I9c855e6381d970b5f08460822366f6333af24f82
2014-02-07 16:41:50 -08:00
jenkins-bot 50b6de4866 Merge "Mark disambiguation and redirect pages in the link inspector" 2014-02-08 00:09:26 +00:00
Krenair 60d8021765 Mark disambiguation and redirect pages in the link inspector
Bug: 50240
Change-Id: If975398e4d6b13eea6207ee80b33067e65acd724
2014-02-07 23:48:41 +00:00
Antoine Musso ae5e922837 Global setting for Parsoid HTTP proxy
On sites using $wgHTTPProxy, any curl requests made via MWHttpRequest
would be passed through that proxy. The Parsoid daemon is most probably
reachable directly, hence we want to be able to disable the proxy.
This can be done using the new $wgVisualEditorParsoidHTTPProxy which is
passed to MWHttpRequest in VisualEditor API.

Change-Id: I855249950b1b368ae0afe662154eb48e5b1a14f2
2014-02-07 14:45:56 -08:00
James D. Forrester 2d834ec8c6 Blacklist Amazon Silk
User agent strings from http://docs.aws.amazon.com/silk/latest/developerguide/user-agent.html
Relies on I853e8861

Bug: 50777
Change-Id: I8830d56b9460a72d9a9880fb7120f338dd0f598c
2014-02-07 22:21:35 +00:00
jrobson 239bae7512 Allow better toolbar customisation for VisualEditor
The toolbar in very desktop vector skin specific
In mobile we want to have more control over the toolbar,
and its placement.
* Thus make setUpToolbar abstract
And move the function to ViewPageTarget

* Introduce ve.init.mw.Target.static.iconModuleStyles to
allow the use of different icons
* Update the mobile toolbar to only have B and I tools

Change-Id: I4c72b4b9128b3a74de8b8b5bce7664fbb315216b
2014-02-06 15:45:08 -08:00
Moriel Schottlender b522994344 Adding position setting to media edit dialog
This adds an image position/alignment to the media edit dialog.

Bug: 51293
Change-Id: I15fbd1ed0998a9093fa039b76624395d661af05b
2014-02-05 20:56:37 +00:00
Moriel Schottlender e8205a7133 Adding alternate text to media edit dialog
Adding an option to add or edit alt text to images in the media edit
dialog.

Bug: 38129
Change-Id: I6d339781822175c40c66a4689ec6e1a873cb081d
2014-02-05 20:56:30 +00:00
Ed Sanders fb4f7d3e24 The great image scaling rewrite of 2014 (MW)
Implement new logic in ve.Scalable from I5b4f0f91b.

Also update VE core submodule to master (57ed8d3).

New changes:
59a0afe The great image scaling rewrite of 2014

Change-Id: I24a2976036310d3814cc7d1853a68745e0499bd5
2014-02-05 12:55:11 -08:00
James D. Forrester 87dd841150 Add placeholder for gallery editor
Change-Id: Id351cea8614282924eb9b1644693f7cd71fd9fa4
2014-02-03 14:05:49 -08:00
Moriel Schottlender 8130acebfd Changing image size in MWMediaEditDialog
Adding the ability to edit image size in the media edit dialog.
The size is now a separate widget.

The following changes were made:
* The dialog was changed to a booklet with 'general settings' and
  'advanced settings', in preparation for other edit features.
* The original image maximum size is fetched from the API and cached.
* Maximum size is limited to the image's original maximum size.
* Aspect ratio is kept when changing height or width, using original
  image size to preserve a sane ratio through the MediaSizeWidget.
* If an error is found in the size, the image will retain its previously
  set dimensions.

Depends on MediaSizeWidget: I3d0f9348a52

Bug: 38129
Change-Id: I2946fb21c46ce05583b219f665ef68928188899e
2014-01-22 18:43:45 -08:00
Trevor Parscal 7994eae8c2 MediaWiki language inspector updates
* Add ULS, which was removed from VE core
* Add experimental mwlanguage module which adds ULS integration
* Hook in ULS to the existing language widget

Also update VE core submodule with changes:
* 1e92abe Generic language inspector

Bug: 47759
Change-Id: I325a4dcc316d0334fadfcaa46ad3acd45c6bf84b
2014-01-18 01:02:23 +00:00
jenkins-bot adf8249688 Merge "Ultra-basic gallery editing" 2014-01-15 23:27:06 +00:00
James D. Forrester 842688c51b Ultra-basic gallery editing
'Cos Erik doesn't like things he can't edit.

Change-Id: I1d9fb1215bb16b1245eddd87c977fb5bfdee4da9
2014-01-15 15:13:12 -08:00
jenkins-bot c8a1e16749 Merge "Display indicators for required parameters in template dialog" 2014-01-15 22:23:20 +00:00
Trevor Parscal c8f7845def Display indicators for required parameters in template dialog
Update submodule for changes in OOUI (I1c047b55c7a0d5cf3e0aa0cc3f9a4da7d45c0304)

Change-Id: I8f84a9ae277e5093356f591f7a56e8cebf4a1893
2014-01-15 14:15:21 -08:00