Commit graph

18725 commits

Author SHA1 Message Date
Translation updater bot 09e405386b Localisation updates from https://translatewiki.net.
Change-Id: Id7717ffa2fa37ec29cd883655c1b2610316e3725
2022-02-25 09:46:26 +01:00
Translation updater bot 026a11357a Localisation updates from https://translatewiki.net.
Change-Id: I6c06fe5619c54ab31919705b2a46b8ee65d2013b
2022-02-24 08:50:19 +01:00
James D. Forrester 10526ca45a Update VE core submodule to master (a75d285a8)
New changes:
a75d285a8 ve.ce.Surface: Fix error on load when document has no content offsets

Bug: T302362
Change-Id: I55cb19b390461264316fc75a09ae90e26bc5f34d
2022-02-23 12:25:00 -05:00
Ed Sanders b0dcf1fc69 Update VE core submodule to master (492815b58)
New changes:
a50d13e3b Localisation updates from https://translatewiki.net.
a0c3637de Localisation updates from https://translatewiki.net.
17daebc83 ve.ce.Surface test: Add test for special image paste handling codepath
f4b688e1b Always use clipboard paste data if "important elements" have been dropped
f0e5c16c9 afterPaste: Add 'figure' to importantElement list
abd5894ef Show copy button when selecting focusable nodes on mobile

Local changes:
* Load new clipboard messages

Bug: T101113
Change-Id: I05f9dc850d3cac740916d26a0c2b0d390e47fbb1
2022-02-23 12:45:42 +01:00
Translation updater bot 5b2d70432e Localisation updates from https://translatewiki.net.
Change-Id: I68902cd40cb95a9d363b47d81c34ab01b56d0b7b
2022-02-23 08:19:42 +01:00
David Lynch 14f99d05fd Avoid undefined index for mobileformat
Bug: T302344
Change-Id: Icf051b6fdec627c6477a7b2abd1ba4ccd5b3a259
2022-02-22 21:23:07 +00:00
jenkins-bot f259cb3072 Merge "Never collapse newly added templates in transclusion dialog" 2022-02-22 15:03:45 +00:00
Translation updater bot e65c63f2ad Localisation updates from https://translatewiki.net.
Change-Id: I9029503fcc32f8c9555d5e173c6221d5b2e388e2
2022-02-22 14:20:50 +01:00
Thiemo Kreuz 0d989b6fee Never collapse newly added templates in transclusion dialog
Bug: T300640
Change-Id: Id400951cf98f1eda780700d726fc10afbc1eaa90
2022-02-22 11:37:21 +01:00
Translation updater bot 596d4e53dd Localisation updates from https://translatewiki.net.
Change-Id: I6dabdf19528a1577d0d019ea7b6ceedd00161903
2022-02-22 08:12:30 +01:00
jenkins-bot e9f8ffa5a1 Merge "Log whenever browser plugin spam is detected" 2022-02-21 23:29:39 +00:00
Ed Sanders 4501771243 Log whenever browser plugin spam is detected
Our theory is that browser plugin spam shouldn't reach
the DM document unless we've made a coding error like
I194ff1d57. Log future errors so if there is more plugin
spam in the future, we can investigate the cause.

Bug: T298147
Depends-On: I705195bc5d0f76a38da5d2cc09fab184a2c32401
Change-Id: I3403859906ceaa51be63b0d79f474f0289ab4408
2022-02-21 22:48:46 +00:00
jenkins-bot 839a62829d Merge "Add and fix default values in parameter documentation" 2022-02-21 13:41:51 +00:00
jenkins-bot 8c1ad11a7d Merge "MWEditSummaryWidget: Handle multi-line comments" 2022-02-21 13:39:01 +00:00
jenkins-bot fe69e22761 Merge "tests: Mock wgVisualEditor instead of relying on SpecialPage value" 2022-02-21 13:32:51 +00:00
jenkins-bot d79527e1f2 Merge "Always scroll to top when loading VE source mode" 2022-02-21 13:23:28 +00:00
Thiemo Kreuz bc0a34b0ed Add and fix default values in parameter documentation
Same random finds while working on something else. I carefully
checked and made sure these methods are actually called without the
optional parameter.

Change-Id: Iab36fd130258322985b5d6e7f8e1f7b4ee235ba2
2022-02-21 13:19:21 +00:00
jenkins-bot aa8b08bd1a Merge "DesktopArticleTarget.init: Handle popState target reactivation properly" 2022-02-21 13:14:38 +00:00
jenkins-bot ba5f31ef8f Merge "DesktopArticleTarget.init: Make getInitialEditMode re-usable" 2022-02-21 13:12:00 +00:00
jenkins-bot 400770088b Merge "build: Update stylelint-config-wikimedia to 0.12.1" 2022-02-21 13:09:17 +00:00
jenkins-bot 2a72f4e290 Merge "Remove not needed self = this indirections" 2022-02-21 12:57:41 +00:00
jenkins-bot e497efca9e Merge "Use .bind() syntax where it makes code more readable" 2022-02-21 12:55:26 +00:00
jenkins-bot 86d01b6c04 Merge "selenium: Wait for VisualEditor to load" 2022-02-21 12:22:52 +00:00
Thiemo Kreuz 3c042049bf Use .bind() syntax where it makes code more readable
This focuses on a few trivial cases where the syntax helps making
the code more readable. One level of indirection is gone with this.

Change-Id: Ibf25d7eaa06952e69b36bd5a78a48d04ac62890c
2022-02-21 10:34:03 +00:00
Thiemo Kreuz 58e27f56d6 Remove not needed self = this indirections
These are only needed when we need to access a specific `this` from
within another `function () {}` context. This is not the case in the
situations here.

This is split from Ibf25d7e to make it smaller and easier to argue
about.

Change-Id: Ide1476de91fc343aa992ad92a1321d3a38b06dd0
2022-02-21 10:52:24 +01:00
Translation updater bot a6ffafb982 Localisation updates from https://translatewiki.net.
Change-Id: Ic09d05200ddc74ef9c26799f019a154292a9a7db
2022-02-21 08:17:15 +01:00
Ed Sanders e21acbe847 build: Update stylelint-config-wikimedia to 0.12.1
Change-Id: I989c038e86610ae2b724b3d9f08c9cd33047bfea
2022-02-20 13:59:31 +00:00
Lucas Werkmeister 957036fa19 MWEditSummaryWidget: Handle multi-line comments
The `.` character class matches any character *except* line terminators,
but edit summaries can contain those. Use [^] to match truly everything
in the comment part. (In the section part, I assume `.` is okay.)

Bug: T302103
Change-Id: I29fcdd7489d118674bab5cfe5c0a15b8e4efac64
2022-02-18 19:54:03 +01:00
Ed Sanders e4c22ec0d6 Don't suppress teardown prompt when pressing escape
Follow-up to If9e5d1fbf00f8359.

Bug: T302096
Change-Id: I60fcddee7bf0dfb3a39e92d26898da2963861c19
2022-02-18 18:15:40 +00:00
jenkins-bot 0db6720128 Merge "Move methods from DesktopArticleTraget to ArticleTarget" 2022-02-18 18:04:28 +00:00
jenkins-bot d7a33aa9f9 Merge "ApiVisualEditorEdit: Pass useskin & mobileformat to ApiParse" 2022-02-18 18:01:45 +00:00
jenkins-bot a1a518236e Merge "DesktopArticleTarget.init: Only bind event listener once" 2022-02-18 17:52:20 +00:00
Ed Sanders c8072f1af2 Move methods from DesktopArticleTraget to ArticleTarget
To allow them to be used by MobileArticleTarget.

Change-Id: I33e8b3c2361c2dfd0fae8aa41eacf993c93c9c48
2022-02-18 17:04:04 +00:00
Ed Sanders 93a7f33989 ApiVisualEditorEdit: Pass useskin & mobileformat to ApiParse
Passing the useskin parameter ensures that output hooks are run
on the new page HTML. This already happens because we request
the 'subtitle' and 'categorieshtml' props which also trigger
skin mode (along with the 'headhtml' which we don't request).

However it is better for us to be explicit that we want the rendering
for a specific skin, rather than relying on these props to trigger
the correct mode.

Also pass through mobileformat param, which is added by a hook
in MobileFrontend.

Change-Id: I1cd2c5c5c13ae0b90cc32e441b453532343a434a
2022-02-18 16:59:07 +00:00
Translation updater bot acbcc68034 Localisation updates from https://translatewiki.net.
Change-Id: Ida6e604a86787ff6a921377d7abf7c2d17b9fd6b
2022-02-17 08:12:26 +01:00
Ed Sanders 54cd911db0 DesktopArticleTarget.init: Handle popState target reactivation properly
This ensures the full loading sequence is shown when the
user opens VE using history navigation.

Bug: T301843
Change-Id: Ia7a641c8bd5a036f23c9da94bc539d8cf66c5021
2022-02-16 15:56:24 +00:00
Ed Sanders c3f88d72c8 DesktopArticleTarget.init: Make getInitialEditMode re-usable
Also let parseSection handle undefined.

Change-Id: I2ec9e7e642d116a555c03af6070f7577ce7030a7
2022-02-16 15:56:24 +00:00
Ed Sanders ca6ed21835 Always scroll to top when loading VE source mode
Change-Id: Ibfbb241f523fbdfcf6eb9fd1aeaa0e13782586aa
2022-02-16 15:17:19 +00:00
Ed Sanders 88609cb885 DesktopArticleTarget.init: Only bind event listener once
Previously we were adding an event listener every time the
target was opened, and not removing the old ones.

Change-Id: I0ce609f1d9e2d6fb00b605dcade6f27e7a887b9d
2022-02-16 14:41:04 +00:00
Željko Filipin 09668285d6 selenium: Wait for VisualEditor to load
Bug: T296187
Change-Id: Iac98690dd49b6e82062973da05ce30c6f08ba8bc
2022-02-16 14:57:13 +01:00
Timo Tijhof bdb7737a5a tests: Mock wgVisualEditor instead of relying on SpecialPage value
Found via Iaf989bc50363a (patch set 6):

> FAILED TESTS:
>   ve.init.mw.DesktopArticleTarget
>     ✖ init
>     Died on test #1
>     TypeError: Cannot set property 'pageLanguageCode' of null
>         at Object.<anonymous>

Bug: T89434
Change-Id: I8ad2cc4c115224eb276d1488091b9518fde739f9
2022-02-16 10:19:11 +00:00
Translation updater bot d1e6239567 Localisation updates from https://translatewiki.net.
Change-Id: If9fe790be7f6f5735fd85d5af9d07a59391a5103
2022-02-16 08:13:45 +01:00
jenkins-bot d4bfe21e3d Merge "Improve smooth scroll to section behaviour" 2022-02-16 02:39:24 +00:00
jenkins-bot a56ade0a02 Merge "Remove 'Hook' from new hook's method name" 2022-02-15 17:05:19 +00:00
Ed Sanders 8101b6511e Improve smooth scroll to section behaviour
* Append the toolbar before starting the scroll
* If the toolbar is floating set the anchor to full height
  immediately. This shouldn't cause the content to jump down
  due to scroll anchoring:
  (https://developer.mozilla.org/en-US/docs/Web/CSS/overflow-anchor/Guide_to_scroll_anchoring)
  But add our own logic for it for browsers which don't support that.
* Now the browser only has to deal with the scroll animation,
  and not the height animation of the toolbar anchor at the
  same time, making it smoother and less buggy.

Bug: T301773
Change-Id: I61d533d40758d559b03c858e0006ef2e4f0fcd16
2022-02-15 15:23:47 +00:00
Translation updater bot 13ea85af8d Localisation updates from https://translatewiki.net.
Change-Id: Id4878e24f1ef04f63419b7fde98469b67959a009
2022-02-15 08:18:02 +01:00
Ed Sanders 5f8c5144ca Remove 'Hook' from new hook's method name
Only the class name needs the -Hook suffix.

Change-Id: I8c600ddb24a9d3a33ed78501639032d98e1e575f
2022-02-14 23:26:05 +00:00
Bartosz Dziewoński 89842933af Update VE core submodule to master (71a2d651c)
New changes:
1d8fbde1f Prefer the start of a CBN when selecting first visible offset

Bug: T299112
Change-Id: I49f1032905772b27ed8065f7c5b0068a32a15bf1
2022-02-14 22:07:54 +01:00
jenkins-bot b7a0a690fb Merge "Desktop: Always show loading progress in a toolbar placeholder" 2022-02-14 17:00:08 +00:00
jenkins-bot 23e9f189d6 Merge "Smooth scroll the heading to the right place while target is loading" 2022-02-14 16:59:49 +00:00