Commit graph

935 commits

Author SHA1 Message Date
MusikAnimal 880c690a10 CodeMirror6: add new modules, feature flag, and URL query parameter
Add a new $wgCodeMirrorV6 temporary feature flag that when enabled,
will load the 'ext.CodeMirror.v6.WikiEditor' module that is built
against CodeMirror 6. You can also pass in the ?cm6enable=1 query
parameter to force use of CodeMirror 6. This is currently only
implemented for the 2010 editor.

Due to packaging constraints with CodeMirror 6, we now use Webpack to
bundle the files, which are then used by ResourceLoader. This is similar
to what is done for Extension:Popups, MobileFrontend, among other
extensions.

A new generic class CodeMirror can be used on other areas where syntax
highlighting is desirable, but not necessarily for editing (i.e. without
WikiEditor).

This commit merely lays the foundation for CodeMirror 6 and updates
WikiEditor to use it. The actual MediaWiki syntax highlighting will come
with a future commit.

With the new Webpack build, the Gruntfile was removed and the tasks
moved to npm commands.

Bug: T317243
Change-Id: I2239d2449b2db3b638551f847eb4eff1aafa6276
2023-10-09 19:51:24 -04:00
jenkins-bot 1a19f48c70 Merge "[build] Bump wdio-mediawiki to v2.3.0" 2023-09-22 18:22:04 +00:00
WMDE-Fisch e6852a47f8 [build] Bump wdio-mediawiki to v2.3.0
Change-Id: I87225bc7cb311b6bbeb57f56e9ed4715f4958f76
2023-09-22 16:01:38 +00:00
James D. Forrester 764ff6478d resources: Manage upstream CodeMirror using ManageForeignResources
Depends-On: Ica6a80d6eb127cc10a00d3d6d0890ad724762ff2
Change-Id: I15721ef93c270a5a2f9194d678cd6876e14c7ea6
2023-09-21 12:40:53 +01:00
David Lynch e9e6361610 Update embedded CodeMirror library to 5.65.15
Was at 5.58.3

Bug: T334994
Change-Id: I74e792a5952973240a111180dde9f5097b48c278
2023-09-20 09:17:03 -05:00
jenkins-bot 4eed68bb4e Merge "build: Update linters" 2023-09-18 17:37:46 +00:00
Ed Sanders 21c121b898 build: Update linters
Change-Id: I49eb2de402a8c89065968cf927a2ca6a361ca684
2023-09-13 14:02:43 +01:00
Ed Sanders d0fe4c0673 Grunt: Use conf.MessagesDirs for banana
Change-Id: I50716a121eff72562a4ba2dd8ea499345da8a997
2023-09-12 18:19:53 +01:00
Translation updater bot 8e5e2170c3 Localisation updates from https://translatewiki.net.
Change-Id: I0ddca034e25562f029baf532a3b6f7b3634a4122
2023-09-12 08:26:32 +02:00
jenkins-bot 406d23f6de Merge "build: Update MediaWiki requirement to 1.41" 2023-08-31 05:34:02 +00:00
Translation updater bot 36b9492ced Localisation updates from https://translatewiki.net.
Change-Id: Ia33b3c9b598b181424e9b7385efa735cb997390c
2023-08-29 08:27:59 +02:00
jenkins-bot 2738060873 Merge "Convert applicable ResourceLoader modules to use packageFiles" 2023-08-24 22:21:10 +00:00
MusikAnimal 46b7208d13 Convert applicable ResourceLoader modules to use packageFiles
Move WikiEditor-specific code to ext.CodeMirror.WikiEditor, leaivng only
CodeMirror-specific things in ext.CodeMirror, including the logUsage
method which was duplicated in the VE plugin and now refactored.

Add .env to .gitignore so that selenium tests can be ran more easily

This patch leaves the other non-mediawiki modes still using the
'scripts' system instead of 'packageFiles'. These are not used in
MediaWiki directly but by some extensions (i.e. PhpTags) and using
packageFiles will break that integration.

Bug: T272035
Change-Id: I3bafef196c1f713443d7b8e9cb7dc2891b379f5d
2023-08-24 11:55:13 -04:00
gerritbot e1fb56e38e Replace some moved Title class uses, now MediaWiki\Title\Title
Bug: T321681
Change-Id: I4ac93c24d2c90d51532fc3c39e60efbb4f8f8bfb
2023-08-19 13:12:12 +00:00
James D. Forrester 2e46dcf630 build: Update MediaWiki requirement to 1.41
All extensions in Wikimedia production are expected to track MediaWiki's release directly.

Change-Id: I1898175817b67e3255376e4817ffca3d4a739d62
2023-08-19 13:10:57 +08:00
WMDE-Fisch 7a49382bdf Add Database group to tests
Tests that create a user account actually use the database and
most be marked as such or they will thow an exception.

See Ic4a72fbfaee730b8417848ae0603443d4995fefc

Change-Id: I827b536006130c9813a2a079eab01be112e691be
2023-08-09 10:51:58 +02:00
Sam Wilson 7d48f2d8bb Use editRecovery.loadEnd JS hook to add change handler
Add core's change handler for CodeMirror changes as well, to
save in-progress edit data.

Depends-On: I32c13c1eeec55dc442b0a00ede9cb74422b0307e
Bug: T342882
Change-Id: I352470752130c7b9b2dfc55a066cecf785d40067
2023-07-31 10:44:08 +08:00
Translation updater bot 1cff0e3f3e Localisation updates from https://translatewiki.net.
Change-Id: Ied0dc3d61d547e35b56f0d67d9f54d58361d8e1f
2023-07-24 09:36:52 +02:00
Translation updater bot c0efed8f61 Localisation updates from https://translatewiki.net.
Change-Id: I44184dd189129b86a7047bd326c530c4be493c40
2023-07-10 09:37:14 +02:00
Func a19cd9b94a ve.ui: Set the CM wrapper to the appropriate language
Bug: T341342
Change-Id: Ibdac3d360527429e396b0c124b57d1531b959a76
2023-07-07 20:54:00 +08:00
Translation updater bot 87ef023efd Localisation updates from https://translatewiki.net.
Change-Id: Ie9a76b8c035681721e6e47b1ddc0e3d6d87583eb
2023-07-06 10:11:29 +02:00
jenkins-bot c82ea859c3 Merge "selenium: run tests concurrently" 2023-06-30 11:39:21 +00:00
WMDE-Fisch 4bb409887d selenium: run tests concurrently
Includes a bit untangling of the setup. Concurrent tests should not
overwrite each others user settings so one of the tests gets it's
own user.

Bug: T337862
Change-Id: Iae245063932d4c5d9e6b61c1fe102505d70c1039
2023-06-30 11:29:32 +02:00
Ed Sanders 9520546e09 Add tool to VE toolbar automatically using 'utility' group
This removes the need for the init module.

Bug: T340751
Depends-On: Ibcc81c90bc9ba6c5fd012c512daf861973b03b2e
Change-Id: Iec3a4c6b00288aee376af47e778c4aa67a98d29b
2023-06-29 14:40:43 +00:00
Ed Sanders 5b69b2380c Always use the strict equality flag when using in_array
Change-Id: Ieb7dc53cbd5b45b6064e05fe5df0401918bbb36d
2023-06-06 13:37:54 +01:00
James D. Forrester 9e9a38d6fc Refactor CodeMirror WebdriverIO tests from sync to async mode
Bug: T300205
Change-Id: Idfcfc984833ca6ca6c09500cd4715a4e5504f84e
2023-06-06 10:49:22 +02:00
libraryupgrader c898ddf371 build: Updating npm dependencies
* grunt-banana-checker: 0.10.0 → 0.11.0
* stylelint-config-wikimedia: 0.14.0 → 0.15.0

Change-Id: I952b7bd8671bd684446b90d92d2b0ba2837b3cc8
2023-06-01 02:55:40 +00:00
Translation updater bot b6dbb27177 Localisation updates from https://translatewiki.net.
Change-Id: I725e26f0262bda7b89f871f9c28441f359ceda56
2023-05-31 08:19:57 +02:00
Translation updater bot 3e046ad947 Localisation updates from https://translatewiki.net.
Change-Id: I187b33194cb6736382471d69a61e0d7920781e75
2023-05-29 09:58:50 +02:00
WMDE-Fisch 6744545c61 Skip user setting for unnamed users
Bug: T329771
Change-Id: I0066c2411bf12fedb1e29cde8306b107c3ab95ba
2023-05-20 15:36:29 +03:00
Volker E ba64a52368 styles: Replace mentioning of WikimediaUI Base and add skin variables
It makes no difference to directly assign Codex Design System for
Wikimedia colors as values instead of re-assigning the outdated
`@wmui-color-*` variables.

Bump to required MediaWiki core version >= v1.41.0.

Also put stylelint-disable before the block it's actually needed.

Bug: T334934
Change-Id: I5696f160d39ef4edec7a1b966fe7e73608c86bdc
2023-05-16 17:58:24 +02:00
jenkins-bot 413adcf654 Merge "Migrate ResourceLoaderCodeMirrorModule to a virtual file callback" 2023-05-10 02:27:00 +00:00
gerritbot b704455012 Update moved class EditPage
See T321882. Moved in Ibefc44eb64aed

Bug: T321681
Change-Id: I2c9bf1c8289f3e45be6f88e685b52371291d66e9
2023-05-06 22:48:02 +00:00
Translation updater bot 49ca50fd1f Localisation updates from https://translatewiki.net.
Change-Id: I4a5e81349bccb7c5452fbf67c1f46937cc8bb733
2023-05-05 10:38:16 +02:00
Tim Starling 7a3f46b490 Migrate ResourceLoaderCodeMirrorModule to a virtual file callback
Bug: T47514
Depends-On: I97d61b5793159cea365740e0563f7b733e0f16de
Change-Id: I31b80fc1c7701fc1075d655270706e341942415d
2023-05-05 16:26:09 +10:00
libraryupgrader 025910fccd build: Updating eslint-config-wikimedia to 0.25.0
Change-Id: I1eab6254c50272e4b794eb60721cc52eae319ad9
2023-05-04 01:35:40 +00:00
Translation updater bot a1c5aeb6e7 Localisation updates from https://translatewiki.net.
Change-Id: I49d0b8a41f048bfb93f0e5f7a2e9e025b3c53cb0
2023-05-02 08:59:28 +02:00
libraryupgrader fc5ad37762 build: Updating dependencies
composer:
* mediawiki/mediawiki-phan-config: 0.12.0 → 0.12.1

npm:
* grunt-eslint: 24.0.0 → 24.0.1

Change-Id: I6a871fed872d8314e82cd083db2ab98ba683d63a
2023-04-29 01:27:19 +00:00
Translation updater bot 44a94a856d Localisation updates from https://translatewiki.net.
Change-Id: If8dbda21fd42581218bba7c9ab5f1ad29e02a562
2023-04-25 08:47:33 +02:00
Translation updater bot 2d89fb5e3b Localisation updates from https://translatewiki.net.
Change-Id: I0493371e6733a6ed51af0c603977f13d7c493597
2023-04-11 09:13:33 +02:00
s-mukuti af8302a46b extension.json: remove unnecessary target definitions
Bug: T329643
Change-Id: I109514e959fb3189282a0715874c09b9fbd00501
2023-03-31 10:25:19 +03:00
libraryupgrader d4d29ace60 build: Updating npm dependencies
* grunt: 1.5.3 → 1.6.1
* stylelint-config-wikimedia: 0.13.1 → 0.14.0

Change-Id: Ib5ce0735dfac337882d65155b767adc773f0691b
2023-03-27 19:38:31 +00:00
jenkins-bot f072ad828b Merge "build: Updating npm dependencies" 2023-03-27 07:13:52 +00:00
Translation updater bot 0012826e46 Localisation updates from https://translatewiki.net.
Change-Id: I24aa53174fc3af89e0b7c29b95f0ea9a337455df
2023-03-27 08:40:43 +02:00
Umherirrender 818245a30f build: Updating npm dependencies
* eslint-config-wikimedia: 0.22.1 → 0.24.0

Change-Id: I576c1693596280e56b05ea6f485c1a995167112c
2023-03-25 22:37:01 +01:00
libraryupgrader 35c9009b5b build: Updating mediawiki/mediawiki-codesniffer to 41.0.0
Change-Id: I689c4ad4408c6ca3029fd5b08e2a9212f12cb05f
2023-03-11 23:25:49 +00:00
Translation updater bot 7be2b3432c Localisation updates from https://translatewiki.net.
Change-Id: I7f389a3fb0ca9e7766d0079ea8153752f2b2f7b1
2023-02-28 08:28:37 +01:00
Translation updater bot 0305140ea1 Localisation updates from https://translatewiki.net.
Change-Id: I6c56ae17fc94579f656ec817132b7b422798e95a
2023-02-20 09:46:11 +01:00
jenkins-bot 775de7751a Merge "Search for toolbar place in toolbarConfig as well as actionConfig" 2023-02-16 00:00:25 +00:00
Ed Sanders 47e42bc61b Search for toolbar place in toolbarConfig as well as actionConfig
The actionToolbar is deprecated and will be going away soon.

Change-Id: I475e987959a037eaa536986cba063ab3ccc0083e
2023-02-14 17:30:33 -08:00