Commit graph

889 commits

Author SHA1 Message Date
Ed Sanders d2c15e9eb5 Bring in code from MobileFrontend
* Use local edit source tool, and emit event to MF
* Bring in toolbar styles, bonus: remove old desktop style hacks

Bug: T96186
Change-Id: I89351e409aa4e9d626edd7151ae05bdcd58f1cee
2015-07-30 17:13:00 +00:00
Ed Sanders cf191f5fa8 Update VE core submodule to master (8feab4e)
New changes:
11953f7 Localisation updates from https://translatewiki.net.
0dbafb0 Update OOjs UI to v0.12.2
cbd0982 Replace placeholder color with opacity
087365c Support other types of 'empty' document placeholders
7692890 Make scrollIntoView a VE utility function
5a1a159 Localisation updates from https://translatewiki.net.
8edf71e [BREAKING CHANGE] Kill ve.indexOf and thus @until
bb02b02 build: Bump various devDependencies to latest
cb5b2cd Fix scrollIntoView util binding
8feab4e [BREAKING CHANGE] Use config object for Target constructors

Local changes:
* Use config object for Target constructors

Bonus:
* Add CSS classes to MW targets
* Use 'super' calls

Change-Id: Ieb4e4eb3663aab2706c0f3ecc8b82e00555df1d5
2015-07-30 08:28:48 -07:00
Ed Sanders 9921759456 Fix target rename merge conflict in CSS
Change-Id: I4ca015696d51c59a4c533127458bf5453d092bad
2015-07-30 09:47:55 +01:00
Ed Sanders 08a9551c84 MobileArticleTarget: Collapse text style buttons
B/I doesn't fit with link & cite on a iPhone 6

Change-Id: Ib23b2f8540425ee5d8265f369aea250e900a0c5f
2015-07-30 00:25:52 +00:00
jenkins-bot 9f20acfc9a Merge "[BREAKING CHANGE] Bring in some code from MobileFrontend" 2015-07-29 23:47:07 +00:00
Ed Sanders 3593184f42 [BREAKING CHANGE] Bring in some code from MobileFrontend
* Bring in back button & save button from MobileFrontend
  so they are properly styled OOUI widgets
* Accordingly, move toolbar save button code up into base
  MW target.

Bug: T96186
Change-Id: Ic89dd4efb831fc3b09980da16524276f6568619d
2015-07-29 16:16:39 -07:00
Ed Sanders 03449dca80 DesktopArticleTarget-*.css: Placeholder CSS fixes for skins
Change-Id: I8c7f98cc083c0811cd847a8b3874a586487658ca
2015-07-29 12:02:09 -07:00
Ed Sanders bb57348a9e DesktopArticleTarget#activate: Rename pageTarget to target
Change-Id: Iae71a050058afb2c1111a99ede5b969afbf5aca6
2015-07-29 17:58:33 +00:00
Ed Sanders fecdc29a38 Replace ve-init-mw-desktopArticleTarget-* with ve-init-mw-target-*
Except in cases where it is only applied to desktop articles.

Change-Id: I40a9dabcd8454138f94affde809afee9c93732a4
2015-07-29 18:26:36 +01:00
Ed Sanders b5de6fa575 [BREAKING CHANGE] Rename (View|Mobile)PageTarget to (Desktop|Mobile)ArticleTarget
Change-Id: I6a8fa76dc4d70cc04722e30e3fea6a6112d56b40
2015-07-29 18:26:36 +01:00
jenkins-bot 85ca7d3e94 Merge "Close the wikitext switch confirmation dialog if serialisation errors" 2015-07-29 00:41:26 +00:00
Roan Kattouw 6d22fd1aa7 Follow-up 8250c8ad54: unbreak ApiResponseCache
.set() should not overwrite existing deferreds; instead,
it should resolve the existing deferred if it's pending.
This is necessary because .set() is used by processResult().
Without this, passing .get() a title that no information
is known for results in a promise that is never resolved,
because the associated deferred is overwritten as soon
as the API response arrives.

Still make .set() a no-op if data has already been set,
by checking if the deferred is pending. For .resolve() this
doesn't matter, but for modifying this.cacheValues it does.

Bug: T107212
Change-Id: I70e8c5450f23062db214ccc5c585624d41de6509
2015-07-28 15:10:21 -07:00
Florianschmidtwelzow 4981a8253d Allow skin developers to set an offset for toolbar floating
Usage:
In a skin, that needs this offset, e.g. because it has a fixed header, it should add
this config var somewhere before the hook BeforeOutputPage is called:

$wgVisualEditorSkinToolbarScrollOffset['vector'] = 60;
(if 60px is the offset to use)

Depends on: I2e10c12df8277c84d948e48c6a132c03d6324693

Bug: T95528
Change-Id: Iaa86c2f68afa6403fcc4f5b7c655704512beead4
2015-07-28 11:18:07 -07:00
Alex Monk f76b57f1e6 Close the wikitext switch confirmation dialog if serialisation errors
Bug: T103632
Change-Id: Id9aede04ff4f8919770e578fac24ad4a1178b9a6
2015-07-25 14:32:17 +01:00
Ed Sanders 8250c8ad54 Separate 'isMissing' micro cache from full link data cache
Bug: T106819
Change-Id: I72f52d63968aa1ac842b2aa503150cf114f9d711
2015-07-24 16:17:35 +01:00
Alex Monk 82fb5f609a Parse SpamBlacklist error on the server-side
The client won't be able to deal with templates etc.

Bug: T99830
Change-Id: I78611a3f061b1afd73de052aa9ddff48dc368f2d
2015-07-23 18:49:42 +00:00
James D. Forrester 57f8fc5368 build: Drop last jscs over-ride and make pass
Change-Id: I4ff60af79cfc6e09e284d51f9b7ac2afa900f0f5
2015-07-22 15:13:09 -07:00
Ed Sanders 8e0394da5c Support command whitelist feature
Depends on I87d8aa3 in core.

Bug: T106061
Change-Id: I694e4e5a83f281da92380a895b72611141838f42
2015-07-18 18:20:49 -05:00
jenkins-bot 0e5a6aca32 Merge "Don't set browser-prefixed transition CSS classes" 2015-07-18 05:35:45 +00:00
jenkins-bot 3d6af458dd Merge "ve.init.mw.TargetLoader: Error when RESTbase load call fails" 2015-07-18 05:21:37 +00:00
Kunal Mehta 0653804151 Don't set browser-prefixed transition CSS classes
jQuery will take care of this automatically: <https://api.jquery.com/css/#css2>.

Follows up bf56f56f3e.

Change-Id: I4db46fc70a5446a9ffc9f6d4375fae3b53609ee0
2015-07-17 16:31:56 -05:00
Alex Monk 7653dec439 ve.init.mw.TargetLoader: Error when RESTbase load call fails
No retry right now, but we should at least stop failing silently. Doing this
in a window.alert() for now, as OOUI isn't available at this part of the
page load just yet (that will be coming soon).

Bug: T97041
Change-Id: Iacb195667215ee69d3991e4c41651ab6042243c5
2015-07-10 18:13:37 -07:00
jenkins-bot 2cf60686af Merge "Check if links are 'known' rather than 'exist' locally" 2015-07-08 19:29:22 +00:00
Ed Sanders 8971edb480 Check if links are 'known' rather than 'exist' locally
This data is used for marking links red, but links which are known
but don't exist (e.g. interwikis) are not red.

Also fix bug in API caused by trying to return a value of (bool)true which is
apparently not allowed. Use (number)1 instead.

Bug: T104604
Change-Id: I599a513a27b31f7167e688d73bc3685141249971
2015-07-08 20:26:04 +01:00
jenkins-bot 3039da4e30 Merge "Fix section scrolling" 2015-07-08 18:32:03 +00:00
jenkins-bot c39bd98597 Merge "Revert "Make toolbar save button frameless"" 2015-07-08 15:38:55 +00:00
Ed Sanders be5df39f5b Fix section scrolling
Core code now has a scrollIntoView animation triggered on focus
which needs to be cancelled before we scroll to the section heading.

Change-Id: I5eb6a5c98b38c2510d2d7f0108fe56e607b34bd6
2015-07-08 15:34:43 +01:00
Bartosz Dziewoński 652da4afab Revert "Make toolbar save button frameless"
This reverts commit cb11cbd2f5.

Actually not needed after 3d36cac7fc4808f708f03b66f5c099de440e4569
in OOjs UI, and would change the UI in unexpected way.

Bug: T103403
Change-Id: Ia30b168ea29d03aa76ad81d1f9894a67604fdc08
2015-07-07 14:21:04 +00:00
jenkins-bot 9e730bf528 Merge "Save dialog: Show reload link next to FancyCaptchas" 2015-07-02 22:39:26 +00:00
jenkins-bot 052405565c Merge "Revert "Show <newarticletext> as surface placeholder, not an edit notice"" 2015-07-02 20:45:28 +00:00
Alex Monk c912f4e6dc Save dialog: Show reload link next to FancyCaptchas
Bug: T103227
Change-Id: Ib0548aa8ce3e2322dedc9980323e6e1f1cd705a0
2015-07-02 20:12:34 +01:00
Esanders b2ff7aaa17 Revert "Show <newarticletext> as surface placeholder, not an edit notice"
This reverts commit 5ac5c7a05b.

Bug: T104227
Change-Id: Id86dd228c2c671758acc6d2d3314c92da8917472
2015-07-02 15:20:24 +00:00
jenkins-bot 6e601a9930 Merge "Make toolbar save button frameless" 2015-07-01 22:48:16 +00:00
jenkins-bot 859f6daee6 Merge "Show <newarticletext> as surface placeholder, not an edit notice" 2015-07-01 15:49:12 +00:00
Alex Monk 5ac5c7a05b Show <newarticletext> as surface placeholder, not an edit notice
Bug: T104227
Change-Id: If0e1df48c1b3818235f7e02220144d467fb78fe9
2015-07-01 15:46:09 +00:00
Ed Sanders bef186c874 ViewPageTarget-vector.css: Fix non-HD mode typo
Missing comma between two selectors

Change-Id: I3e2ab561991f5f11598be1460f65a239e3c0d7ca
2015-07-01 15:35:55 +00:00
Ed Sanders cb11cbd2f5 Make toolbar save button frameless
Depends on I26b540dd2 in oojs-ui for styling.

Bug: T101165
Change-Id: I075b8cecf9df2026fb1da17e2ebdf0d848a3d250
2015-07-01 12:12:50 +01:00
Ed Sanders 472c98053d Ensure placeholder styling matches document
Bug: T96593
Change-Id: I23bb1393a9a6779b70ed1004496f3ca6ff038e43
2015-06-30 09:47:34 +01:00
Bartosz Dziewoński 6d18641e4d Specify 'associatedWindows' for link and citation tools
Depends on I21fb955ecb697060263538914014d5712e013695 in core.

Bug: T98845
Change-Id: Id7f59c0095e8d85bb608bed0ab60603665fbca47
2015-06-29 16:26:32 -07:00
jenkins-bot bd394194e3 Merge "ve.init.mw.Target: Strip all <script>/<object>/<style>/<embed> on save" 2015-06-25 23:45:00 +00:00
James D. Forrester 4f1881ea74 ve.init.mw.Target: Strip all <script>/<object>/<style>/<embed> on save
Bug: T103430
Change-Id: Ie6ca3181f4c0764625b4d69fa169abc67ffb15bb
2015-06-23 08:42:01 -07:00
Timo Tijhof 87f2d0bc2a Make ext.visualEditor.mwalienextension mandatory (no longer experimental)
This module is required in order to alienate all extension blocks
by default. Otherwise they are interpreted as plain divs which
allow content editable.

Bug: T103455
Change-Id: I08f6b9a516ba6bee6ed18256222108116eceee1e
2015-06-23 03:45:50 +01:00
Timo Tijhof e1ce49509c mw.ViewPageTarget: Ensure canonial view url is restored
When loading VE by clicking Edit on a view url, this naturally
works (we temporarily append our query, and remove it when ready).

When loading VE from a permalink (e.g. Open in new tab) or any
other source linked from HTML pages, then we're not in control
over adding the query (it's already there); we're only in control
over restoring the view url afterwards.

Bug: T102363
Change-Id: I4912ff1c6b28ac987517760ffed481a4cd3bd1ca
2015-06-15 13:28:35 +01:00
Ed Sanders 425e581613 Unregister core image types
Once MW images are registered, we should remove core image support so
we don't accidentally match to them (e.g. an MW inline image with an
unsupported extra RDFa type).

Change-Id: I1c8567346c371fe338f95b232c9ac53e009c5a46
2015-06-02 14:36:14 +01:00
jenkins-bot da3a5dbfc4 Merge "Improve progress bar" 2015-05-12 12:27:28 +00:00
jenkins-bot 788d0b0047 Merge "Remove 3px gap above toolbar in Monobook" 2015-05-12 12:24:42 +00:00
jenkins-bot c35be097d1 Merge "ve.init.mw.ViewPageTarget: Simplify toolbar save button and inner toolbar code" 2015-05-12 12:19:22 +00:00
Trevor Parscal 4297301948 Close the bottom of Vector tabs in VisualEditor
Change-Id: Ie1a0b45300dbc21fb388ee7fc94e0851d0cd5924
2015-05-12 12:56:30 +01:00
Trevor Parscal 293e032786 Remove 3px gap above toolbar in Monobook
Change-Id: I3ccfc4556d2d19e5caa2a4a21b81fab54ca4f414
2015-05-12 12:56:03 +01:00
Bartosz Dziewoński e459c14442 ve.init.mw.ViewPageTarget: Simplify toolbar save button and inner toolbar code
All this is no longer needed since 121216184718e7ebe22d6ecc8f5af5fe4e202465 in
OOjs UI and started causing issues after bb9c9c4f6a2fca6aed0e671e904e469d57da5f34.

Bug: T98795
Change-Id: I6493d6b52b313aac521aee2b0cff1571ea63bbe5
2015-05-12 13:50:40 +02:00