Commit graph

25 commits

Author SHA1 Message Date
jaredblumer 12f9be5e69 eslint: Update to eslint-config-wikimedia 0.16.0
* Update ESLint config with Selenium WebdriverIO test suite
* Update modules and Selenium pageobjects and specs per ESLint
requirements
* Update grunt-eslint package to 23.0.0 as required by
eslint-config-wikimedia 0.16.0

Bug: T254495
Change-Id: Ibfcf9115adedf9f2c3e7dac1ac626b41fc97b7c4
2020-06-08 21:17:50 -04:00
Ed Sanders d86b74d3de eslint: Add /mediawiki rules
Change-Id: I1853e273fad3308349c79d188bc30de98fe116c4
2020-02-22 15:59:28 +00:00
Daimona Eaytoy b235e1040a Restyle edit box dimensions
Now it's always wider, and so is the "notes" field. Moreover, the
fallback textarea has the exact same size. Plus removed a parameter
which only made it hard to write a CSS rule for the textarea. Since the
textarea is generated by the same code, and we're always using it for
the same thing (filter syntax, regardless of the final goal), make it
always use the same name.

Bug: T230591
Change-Id: Ibb308e80d954c0e81aa09249c38c39572f157948
2019-08-17 18:53:13 +02:00
Daimona Eaytoy 6e2b66f96d build: Update eslint-config-wikimedia to 0.10.1
And exclude no-global-selectors for now...

Change-Id: I0cea497ff8d8c749ea4f365c968428af01e85d18
2019-02-18 19:26:42 +01:00
jenkins-bot 9ce4afb010 Merge "Add names to anonymous JS function" 2019-01-19 13:27:43 +00:00
Ed Sanders 663a66dc0a Remove obsolete aliases from closures
Bug: T208951
Change-Id: I1330672b62c9d8f49cf31264995e7a07b467178f
2018-11-23 15:44:58 +00:00
Daimona Eaytoy 9d02b3947a Add names to anonymous JS function
To have clearer stack traces.

Change-Id: Ia086cef5dc916c21a94af7856715754b6bfb496b
2018-11-19 15:46:09 +01:00
Daimona Eaytoy e60dacbbea Fix code comments
Fixed some comments adding explanations, fixing syntax, and parameter types
for docblocks. Also fixed some whitespace mess, and added a missing use
statement.

Change-Id: I3547c90bdaa2cab5443e8bf0c63b217fe6ba663f
2018-10-03 16:45:03 +02:00
Daimona Eaytoy db4a0a1eec Break long lines in JS code
Bug: T203365
Change-Id: If9d5f8d4c341f2f273eda3f1fd54d59a04a9d263
2018-09-03 10:49:24 +02:00
Daimona Eaytoy 3c1dae9e14 Allow users with abusefilter-view-private to use testing interface
Now the required need will be abusefilter-modify OR
abusefilter-view-private for /tools, /test and /examine.

Bug: T193903
Change-Id: I3f1a91a2cc1df2272e5d4099cefd7c649a0683d5
2018-06-24 14:10:38 +00:00
Daimona Eaytoy 7450fb1d62 Switch /test and /examine/# to OOUI
Standardized Special:AbuseFilter/test and /examine/# to OOUI. They need
to be updated together, since they share the same load filter button
(now centralized) which needs to be handled in a different way.

Bug: T132284
Bug: T58367
Bug: T58368
Depends-On: If3d6a994142e34686bb7fc9f09093f751b599485
Change-Id: Ib935e8c9706e987468e52ec2ad1c7219b35fb9d5
2018-03-30 13:12:36 -04:00
James D. Forrester de2a7b07d4 build: Replace jshint with eslint
Bug: T186753
Change-Id: I067adf86a220d59ff1693bef74d7590d4c63d3c2
2018-02-08 16:26:50 +00:00
helderwiki 20dabefe22 Improve error handling for HTTP requests
The API provides more details about HTTP errors, so show these to
the user instead of a generic "An unknown error occurred."

Bug: 68767
Change-Id: I3188b9729c815a07c65a7dbef4d40deebe29b87d
2014-08-02 11:56:32 +00:00
Marius Hoch baf5001d34 Remove redundant class for syntax errors
Removed the redundant clss mw-abusefilter-examine-syntaxerror
as it was causing trouble because the syntax checker in
ext.abuseFilter.edit.js wasn't aware of it.

Change-Id: Ibb90c3e096c3914905c03a3e30c08ba8d14c9024
2013-05-24 16:45:35 +02:00
Marius Hoch 87094b9c0a Add .jshintrc for AbuseFilter and make it pass
Change-Id: I1cee072e6c751e441e77e6f005676fe13841283e
2013-04-17 15:03:36 +02:00
Timo Tijhof 5d50832447 JSHint: If you use 'use strict', make sure you actually pass it.
Someone added "use strict" to AbuseFilter JS files, but it didn't
actually pass in strict mode.

Change-Id: I0cf26b4dacfa88fb40d0595276db65239823763a
2013-04-02 21:44:01 +02:00
Marius Hoch e3d15fe915 Overhaul of the AbuseFilter JS
I've changed the JS of the AbuseFilter extension to match our
coding conventions and made it use mediaWiki.Api(). Furthermore
I fixed several error handlers and made some things nicer in
general while trying to not change the user appearance.

I've tested the changes as good as I could (I'm pretty sure everything
works).

Change-Id: Iaa0f99367bd7e0bfaf7249dcc9ac9ce9881b46e1
2013-03-07 14:14:25 +01:00
Marius Hoch 1958d74854 Fix AbuseFilter JS
Temp. fix, please look at https://gerrit.wikimedia.org/r/30110

Change-Id: Ic890a6f7b39618dba9f310244777e69435940cce
2012-10-26 16:21:08 +02:00
Marius Hoch f52f940ee5 Fix the AbuseFilter JS
This is bad style, but it works... please take a look at
https://gerrit.wikimedia.org/r/30110 which is much cleaner
and doesn't have the problems as well.

Change-Id: I91684de0c8594917736812846ed3782653a46e99
2012-10-26 15:57:54 +02:00
Siebrand Mazeland 176227e721 Maintenance for AbuseFilter extension.
* Replace deprecated methods.
* Remove no longer needed function fnmatch().
* Remove superfluous newlines.
* Remove unused and redundant local variables and globals.
* Deglobalization.
* Update documentation.
* Fix incorrect return values or add FIXMEs when in doubt.
* Escape output in a few places where needed.
* Remove unneeded MEDIAWIKI constant checks.
* Fix various JSHint/JSLint issues.

Patch Set 11: Merged https://gerrit.wikimedia.org/r/24701 into
this one per Siebrand's request

Change-Id: I02ba4ce31b6aca5b7324114093f8ece143abc295
2012-10-09 22:26:45 +02:00
Tim Starling 44c29b8c4f * (bug 34538) Fixed compatibility with $wgResourceLoaderExperimentalAsyncLoading in some extensions.
* Tested AbuseFilter.
* Did not test ArticleCreationWorkflow, Configure, ContributionTracking, FlaggedRevs, FundraiserPortal, InlineCategorizer, MarkAsHelpful, Math/Mathjax.
* Fixed a typo in a comment in LiveTranslate.
* Did not review extensions alphabetically after MoodBar.
2012-02-21 04:03:00 +00:00
John Du Hart 4926aeae24 Followup r98490, since the module names changed the variable names need changing as well 2011-09-30 00:05:08 +00:00
John Du Hart 3f06314486 Followup r95572, rename API modules to reduce chance of collisions per CR 2011-09-29 23:30:42 +00:00
John Du Hart 39f30c3f22 Followup r95572 to change variable names and use an associative array per Krinkle and Roan on IRC 2011-08-26 20:26:57 +00:00
John Du Hart b30697e94c Adds ResourceLoader support to AbuseFilter
Rewrote javascript to use jQuery
Added API modules to replace sajax_* calls
Solves bug 29714
2011-08-26 20:12:34 +00:00