Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merging latest changes from ContactPage #1

Open
wants to merge 367 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
367 commits
Select commit Hold shift + click to select a range
48b960f
Localisation updates from https://translatewiki.net.
translatewiki Aug 5, 2022
2506d00
Localisation updates from https://translatewiki.net.
translatewiki Aug 8, 2022
7924c33
Localisation updates from https://translatewiki.net.
translatewiki Aug 9, 2022
20478f1
Localisation updates from https://translatewiki.net.
translatewiki Aug 11, 2022
7cacc0b
Localisation updates from https://translatewiki.net.
translatewiki Aug 12, 2022
c681a9b
Localisation updates from https://translatewiki.net.
translatewiki Aug 16, 2022
f0f2882
Localisation updates from https://translatewiki.net.
translatewiki Aug 17, 2022
c7241fb
Localisation updates from https://translatewiki.net.
translatewiki Aug 19, 2022
9c10cef
Localisation updates from https://translatewiki.net.
translatewiki Aug 22, 2022
5facfb5
Localisation updates from https://translatewiki.net.
translatewiki Aug 29, 2022
0ee4b1d
Stop running EmailUser hook on Special:Contact
ZabeMath Aug 30, 2022
d200e68
Localisation updates from https://translatewiki.net.
translatewiki Sep 5, 2022
788386b
Localisation updates from https://translatewiki.net.
translatewiki Sep 9, 2022
ec11af7
Localisation updates from https://translatewiki.net.
translatewiki Sep 22, 2022
ef80b58
Localisation updates from https://translatewiki.net.
translatewiki Oct 4, 2022
f27b599
build: Updating grunt-banana-checker to 0.10.0
Oct 6, 2022
8e19f10
build: Updating mediawiki/mediawiki-phan-config to 0.12.0
Oct 9, 2022
fe3ee08
Localisation updates from https://translatewiki.net.
translatewiki Oct 10, 2022
bffbda6
Localisation updates from https://translatewiki.net.
translatewiki Oct 14, 2022
060a050
build: Updating minimatch to 3.0.8
Oct 21, 2022
ad99d67
build: Updating mediawiki/mediawiki-codesniffer to 40.0.1
Nov 16, 2022
2eb5557
Localisation updates from https://translatewiki.net.
translatewiki Nov 21, 2022
657e584
Localisation updates from https://translatewiki.net.
translatewiki Dec 1, 2022
87f9c12
Localisation updates from https://translatewiki.net.
translatewiki Dec 19, 2022
f94d3c5
Suppress Phan check for plain text output
Dec 19, 2022
8431265
Localisation updates from https://translatewiki.net.
translatewiki Dec 21, 2022
6cb1bd8
Don't display info text when email is required
Nov 30, 2022
3f769d4
Start on selenium tests for ContactPage
Dreamy-Jazz Dec 20, 2022
d884bf8
Localisation updates from https://translatewiki.net.
translatewiki Dec 23, 2022
bf72322
Localisation updates from https://translatewiki.net.
translatewiki Dec 26, 2022
dd33b42
Localisation updates from https://translatewiki.net.
translatewiki Jan 2, 2023
3fafac7
Localisation updates from https://translatewiki.net.
translatewiki Jan 3, 2023
bf69a6f
Localisation updates from https://translatewiki.net.
translatewiki Jan 5, 2023
29c2237
Localisation updates from https://translatewiki.net.
translatewiki Jan 9, 2023
ab9486e
Merge "Suppress Phan check for plain text output"
Jan 19, 2023
2872ae4
Merge "Start on selenium tests for ContactPage"
Jan 19, 2023
f7215fc
Merge "Don't display info text when email is required"
Jan 20, 2023
586ef7f
Prevent crash if AdditionalFields not set
Dec 1, 2022
2a36e07
Provide recipient username to emailsenttext message
Nov 30, 2022
0f5deb2
Localisation updates from https://translatewiki.net.
translatewiki Jan 26, 2023
91b4c33
build: Updating ua-parser-js to 1.0.33
Jan 26, 2023
d7317a7
Localisation updates from https://translatewiki.net.
translatewiki Jan 30, 2023
da56f0b
build: Updating http-cache-semantics to 4.1.1
Feb 3, 2023
7360747
Allow multiple messages to be form specific in the contact form
Dreamy-Jazz Feb 12, 2023
d7e9104
Localisation updates from https://translatewiki.net.
translatewiki Feb 15, 2023
58d1ad1
Localisation updates from https://translatewiki.net.
translatewiki Mar 3, 2023
0f13cb2
Localisation updates from https://translatewiki.net.
translatewiki Mar 6, 2023
99b9f6a
Localisation updates from https://translatewiki.net.
translatewiki Mar 7, 2023
cac98fc
Localisation updates from https://translatewiki.net.
translatewiki Mar 9, 2023
954a2ac
build: Updating mediawiki/mediawiki-codesniffer to 41.0.0
Mar 11, 2023
2540cfb
Localisation updates from https://translatewiki.net.
translatewiki Mar 13, 2023
1c2cbb2
build: Updating npm dependencies
Mar 14, 2023
5f33c00
Localisation updates from https://translatewiki.net.
translatewiki Mar 15, 2023
fb53076
Localisation updates from https://translatewiki.net.
translatewiki Mar 16, 2023
9539477
Localisation updates from https://translatewiki.net.
translatewiki Mar 17, 2023
9b14b36
ContactPage: Special page aliases should not store in zh
winstonsung Mar 22, 2023
3040625
Localisation updates from https://translatewiki.net.
translatewiki Mar 24, 2023
60d6d4c
Merge "ContactPage: Special page aliases should not store in zh"
Mar 27, 2023
4d79ce4
Localisation updates from https://translatewiki.net.
translatewiki Mar 31, 2023
e45f13a
Localisation updates from https://translatewiki.net.
translatewiki Apr 3, 2023
7f0e9fb
selenium: Update @wdio/* npm packages
pwangai Apr 5, 2023
357a5d3
Localisation updates from https://translatewiki.net.
translatewiki Apr 10, 2023
69e5a6d
Localisation updates from https://translatewiki.net.
translatewiki Apr 24, 2023
3840629
Replace deprecated Hooks::run
umherirrender Apr 27, 2023
2ce89f1
build: Updating dependencies
Apr 29, 2023
1f6996d
Merge "Replace deprecated Hooks::run"
May 2, 2023
65ec747
build: Updating eslint-config-wikimedia to 0.25.0
May 3, 2023
0f10b3b
Localisation updates from https://translatewiki.net.
translatewiki May 5, 2023
ad166fe
Localisation updates from https://translatewiki.net.
translatewiki May 8, 2023
f587f57
Define merge strategy for ContactConfig as array_plus_2d
Dreamy-Jazz Dec 20, 2022
95b0c69
build: Updating grunt-banana-checker to 0.11.0
Jun 1, 2023
11e085a
Localisation updates from https://translatewiki.net.
translatewiki Jun 1, 2023
72e7f5e
Localisation updates from https://translatewiki.net.
translatewiki Jun 8, 2023
bb22883
Create HookRunner class and the hook handler interfaces
umherirrender Jun 3, 2023
20e5f9f
Merge "Create HookRunner class and the hook handler interfaces"
Jun 8, 2023
690fbad
Localisation updates from https://translatewiki.net.
translatewiki Jun 12, 2023
f8e8c12
Localisation updates from https://translatewiki.net.
translatewiki Jun 14, 2023
d7c67b7
Localisation updates from https://translatewiki.net.
translatewiki Jun 19, 2023
e6917e1
Localisation updates from https://translatewiki.net.
translatewiki Jul 6, 2023
28bfb6c
Localisation updates from https://translatewiki.net.
translatewiki Jul 19, 2023
626db17
Localisation updates from https://translatewiki.net.
translatewiki Jul 20, 2023
402cc81
Localisation updates from https://translatewiki.net.
translatewiki Jul 24, 2023
1090a18
Localisation updates from https://translatewiki.net.
translatewiki Aug 2, 2023
95163de
Localisation updates from https://translatewiki.net.
translatewiki Aug 7, 2023
4cf17e8
Localisation updates from https://translatewiki.net.
translatewiki Aug 10, 2023
1debc9d
Localisation updates from https://translatewiki.net.
translatewiki Aug 14, 2023
179c846
build: Update MediaWiki requirement to 1.41
jdforrester Aug 19, 2023
068fbc6
Treat temporary users as logged out for MustBeLoggedIn config
Dreamy-Jazz Aug 22, 2023
e27d7ee
Localisation updates from https://translatewiki.net.
translatewiki Aug 24, 2023
f17429a
Localisation updates from https://translatewiki.net.
translatewiki Sep 1, 2023
852bab9
Merge "Treat temporary users as logged out for MustBeLoggedIn config"
Sep 5, 2023
251aee7
Localisation updates from https://translatewiki.net.
translatewiki Sep 6, 2023
57754fa
Localisation updates from https://translatewiki.net.
translatewiki Sep 7, 2023
db3c32b
Localisation updates from https://translatewiki.net.
translatewiki Sep 13, 2023
084d64f
Localisation updates from https://translatewiki.net.
translatewiki Sep 18, 2023
9f430c3
Localisation updates from https://translatewiki.net.
translatewiki Sep 27, 2023
0396534
SpecialPage::getDescription() should return a Message
MatmaRex Sep 27, 2023
f5c0229
Localisation updates from https://translatewiki.net.
translatewiki Oct 2, 2023
71705d1
Localisation updates from https://translatewiki.net.
translatewiki Oct 4, 2023
1f8a6d3
Localisation updates from https://translatewiki.net.
translatewiki Oct 9, 2023
ad00b84
Localisation updates from https://translatewiki.net.
translatewiki Oct 16, 2023
d797ea2
build: Update linters
edg2s Oct 20, 2023
135b0a9
Localisation updates from https://translatewiki.net.
translatewiki Oct 23, 2023
c43d62e
ContactPage.alias.php: Add alias for Serbian (Latin script)
kizule Oct 28, 2023
69fda88
Localisation updates from https://translatewiki.net.
translatewiki Nov 6, 2023
b91ed83
Localisation updates from https://translatewiki.net.
translatewiki Nov 20, 2023
e36556c
Localisation updates from https://translatewiki.net.
translatewiki Nov 22, 2023
e80e879
Localisation updates from https://translatewiki.net.
translatewiki Nov 27, 2023
62d7c63
Update UserOptionsLookup's FQN
Nov 29, 2023
7c48696
Localisation updates from https://translatewiki.net.
translatewiki Dec 4, 2023
ae025dc
Use namespaced classes
umherirrender Dec 10, 2023
61bc52e
Localisation updates from https://translatewiki.net.
translatewiki Dec 18, 2023
f497f34
Localisation updates from https://translatewiki.net.
translatewiki Dec 20, 2023
92f374f
Localisation updates from https://translatewiki.net.
translatewiki Dec 26, 2023
04e4238
Localisation updates from https://translatewiki.net.
translatewiki Jan 8, 2024
cae7642
Localisation updates from https://translatewiki.net.
translatewiki Jan 9, 2024
982213e
Localisation updates from https://translatewiki.net.
translatewiki Jan 11, 2024
05da34b
Update references to namespaced ConfirmEdit extension classes
Krinkle Jan 16, 2024
fdf3b3f
Localisation updates from https://translatewiki.net.
translatewiki Jan 28, 2024
6012864
Add config options to disable name, email, subject modification
Nov 30, 2022
d0b2fc6
Merge "Add config options to disable name, email, subject modification"
Jan 29, 2024
e0dc4df
Follow-up: Add config options to disable name, email, subject modific…
Dreamy-Jazz Feb 1, 2024
0572f85
build: Updating wdio-mediawiki to 2.5.0
Feb 3, 2024
39bde28
Localisation updates from https://translatewiki.net.
translatewiki Feb 5, 2024
fff0fc2
Merge "Follow-up: Add config options to disable name, email, subject …
Feb 5, 2024
6f9b107
Localisation updates from https://translatewiki.net.
translatewiki Feb 7, 2024
1c90e5c
Localisation updates from https://translatewiki.net.
translatewiki Feb 8, 2024
96e3cf5
build: Updating eslint-config-wikimedia to 0.26.0
Feb 8, 2024
1895c1d
build: Updating mediawiki/mediawiki-phan-config to 0.14.0
Feb 9, 2024
7285e71
Localisation updates from https://translatewiki.net.
translatewiki Feb 14, 2024
0e07661
Use OutputPage::setPageTitleMsg() instead of ::setPageTitle()
MatmaRex Feb 17, 2024
e5422cd
Merge "Use OutputPage::setPageTitleMsg() instead of ::setPageTitle()"
Feb 17, 2024
ba36265
Localisation updates from https://translatewiki.net.
translatewiki Feb 19, 2024
63e2bc9
Localisation updates from https://translatewiki.net.
translatewiki Feb 26, 2024
4b58501
Localisation updates from https://translatewiki.net.
translatewiki Mar 11, 2024
dff675e
build: Updating mediawiki/mediawiki-codesniffer to 43.0.0
Mar 17, 2024
561aadc
Localisation updates from https://translatewiki.net.
translatewiki Mar 18, 2024
56e540c
Add optional parameter to show message if user is blocked.
dbrant Mar 19, 2024
70dc86d
Localisation updates from https://translatewiki.net.
translatewiki Mar 21, 2024
249664c
Localisation updates from https://translatewiki.net.
translatewiki Mar 26, 2024
a26ed41
Localisation updates from https://translatewiki.net.
translatewiki Apr 11, 2024
863ed27
Localisation updates from https://translatewiki.net.
translatewiki Apr 16, 2024
8e3a7b3
build: Updating eslint-config-wikimedia to 0.27.0
Apr 16, 2024
734a795
Replace use of deprecated User::isBlockedFromEmailuser()
supertassu Apr 23, 2024
b623a6a
Localisation updates from https://translatewiki.net.
translatewiki Apr 24, 2024
717bd59
Localisation updates from https://translatewiki.net.
translatewiki Apr 25, 2024
36784de
Localisation updates from https://translatewiki.net.
translatewiki Apr 26, 2024
504e920
Localisation updates from https://translatewiki.net.
translatewiki Apr 29, 2024
3c95fed
build: Updating dependencies
May 2, 2024
6ea312f
Localisation updates from https://translatewiki.net.
translatewiki May 6, 2024
7c8c898
build: Updating dependencies
May 10, 2024
93fcd2a
Localisation updates from https://translatewiki.net.
translatewiki May 13, 2024
8c42a14
Localisation updates from https://translatewiki.net.
translatewiki May 16, 2024
35c85f2
Localisation updates from https://translatewiki.net.
translatewiki May 17, 2024
84afc8b
build: Updating grunt-banana-checker to 0.13.0
May 18, 2024
20bace0
Localisation updates from https://translatewiki.net.
translatewiki May 28, 2024
bafab73
Localisation updates from https://translatewiki.net.
translatewiki Jun 7, 2024
b402ac9
build: Updating eslint-config-wikimedia to 0.28.0
Jun 8, 2024
7a46cff
Use namespaced HTMLForm class
umherirrender Jun 8, 2024
380d060
Merge "build: Updating eslint-config-wikimedia to 0.28.0"
Jun 9, 2024
de92915
Localisation updates from https://translatewiki.net.
translatewiki Jun 10, 2024
af54601
build: Updating braces to 3.0.3
Jun 11, 2024
805f350
Localisation updates from https://translatewiki.net.
translatewiki Jun 11, 2024
be53a16
Localisation updates from https://translatewiki.net.
translatewiki Jun 14, 2024
6bf9d0c
Localisation updates from https://translatewiki.net.
translatewiki Jun 17, 2024
be89dda
Localisation updates from https://translatewiki.net.
translatewiki Jun 19, 2024
c193741
build: Updating eslint-config-wikimedia to 0.28.2
Jun 20, 2024
93b90ba
Localisation updates from https://translatewiki.net.
translatewiki Jun 20, 2024
d2444e9
Localisation updates from https://translatewiki.net.
translatewiki Jul 1, 2024
e2ce45d
Localisation updates from https://translatewiki.net.
translatewiki Jul 4, 2024
ec9420b
Localisation updates from https://translatewiki.net.
translatewiki Jul 5, 2024
a367e9a
Localisation updates from https://translatewiki.net.
translatewiki Jul 8, 2024
f69889f
Localisation updates from https://translatewiki.net.
translatewiki Jul 11, 2024
28c0503
Localisation updates from https://translatewiki.net.
translatewiki Jul 18, 2024
6cfb79e
Localisation updates from https://translatewiki.net.
translatewiki Jul 22, 2024
89fbdee
Localisation updates from https://translatewiki.net.
translatewiki Jul 26, 2024
7114d3b
Localisation updates from https://translatewiki.net.
translatewiki Jul 29, 2024
6ac6aaa
Localisation updates from https://translatewiki.net.
translatewiki Jul 30, 2024
45c3a2a
Localisation updates from https://translatewiki.net.
translatewiki Aug 8, 2024
6cd85a0
build: Updating mediawiki/mediawiki-codesniffer to 44.0.0
Aug 11, 2024
7b499eb
Localisation updates from https://translatewiki.net.
translatewiki Aug 14, 2024
1ba822c
Localisation updates from https://translatewiki.net.
translatewiki Aug 15, 2024
d03fed3
Localisation updates from https://translatewiki.net.
translatewiki Aug 19, 2024
71ef6a4
Add optional redirect parameter.
dbrant Aug 19, 2024
dd73c6b
Merge "Add optional redirect parameter."
Aug 22, 2024
cf6326e
build: Update MediaWiki requirement to 1.43
jdforrester Aug 22, 2024
d25bdb8
build: Updating micromatch to 4.0.8
Aug 25, 2024
531be5c
Localisation updates from https://translatewiki.net.
translatewiki Aug 26, 2024
ca35c16
Localisation updates from https://translatewiki.net.
translatewiki Aug 28, 2024
39aeb33
Localisation updates from https://translatewiki.net.
translatewiki Sep 2, 2024
2767402
Localisation updates from https://translatewiki.net.
translatewiki Sep 3, 2024
d299df6
Localisation updates from https://translatewiki.net.
translatewiki Sep 5, 2024
f9e7446
Localisation updates from https://translatewiki.net.
translatewiki Sep 9, 2024
1a7c5ea
SpecialContact: Move loading of contactpage-pagetext closer to useage
reedy Sep 13, 2024
f6110fc
SpeciaContact: Call getUser() later when actually needed
reedy Sep 13, 2024
03a2581
Localisation updates from https://translatewiki.net.
translatewiki Sep 16, 2024
04bf905
Use ::class for class name resolution
umherirrender Sep 20, 2024
08fc161
Localisation updates from https://translatewiki.net.
translatewiki Sep 23, 2024
5c9294f
Update error message for temp users trying to use special pages
Dreamy-Jazz Sep 24, 2024
a897b6e
Localisation updates from https://translatewiki.net.
translatewiki Sep 26, 2024
5fe5b5e
Localisation updates from https://translatewiki.net.
translatewiki Sep 27, 2024
747bd12
Localisation updates from https://translatewiki.net.
translatewiki Sep 30, 2024
b08ab5c
Localisation updates from https://translatewiki.net.
translatewiki Oct 1, 2024
1e946c2
Replace several deprecated functions
xtexx Oct 5, 2024
41a6db9
Localisation updates from https://translatewiki.net.
translatewiki Oct 7, 2024
2f58b31
selenium: Replace Node.js Assert library with WebdriverIO Expect library
zeljkofilipin Oct 9, 2024
3a9fe11
Allow specifying a recipient email address
jayktaylor Oct 1, 2024
ea01ae6
Localisation updates from https://translatewiki.net.
translatewiki Oct 14, 2024
a8b23c4
Merge "Allow specifying a recipient email address"
Oct 14, 2024
1ebea05
Use namespaced ExtensionRegistry class
umherirrender Oct 19, 2024
f1b21ca
Localisation updates from https://translatewiki.net.
translatewiki Oct 21, 2024
bbf3609
Localisation updates from https://translatewiki.net.
translatewiki Oct 21, 2024
c1fcc12
SpecialContact: Simplify main execution method
Ammarpad Oct 17, 2024
b01aab1
Localisation updates from https://translatewiki.net.
translatewiki Oct 25, 2024
27c8e4b
Localisation updates from https://translatewiki.net.
translatewiki Oct 28, 2024
c618770
Localisation updates from https://translatewiki.net.
translatewiki Oct 30, 2024
9a3dc7c
Include names for temporary accounts as well on the subject line
subbuss Nov 1, 2024
26937dc
build: Updating mediawiki/mediawiki-codesniffer to 45.0.0
Nov 2, 2024
2af2a82
Localisation updates from https://translatewiki.net.
translatewiki Nov 4, 2024
b9a3e6d
Localisation updates from https://translatewiki.net.
translatewiki Nov 11, 2024
9581b3c
Localisation updates from https://translatewiki.net.
translatewiki Nov 12, 2024
78ebad2
Localisation updates from https://translatewiki.net.
translatewiki Nov 13, 2024
165eba1
Localisation updates from https://translatewiki.net.
translatewiki Nov 18, 2024
a3cf5fd
Localisation updates from https://translatewiki.net.
translatewiki Nov 20, 2024
5bd3706
Localisation updates from https://translatewiki.net.
translatewiki Nov 27, 2024
f0c01ff
Localisation updates from https://translatewiki.net.
translatewiki Dec 6, 2024
4abe95e
tests: Start testing SpecialContact page
Ammarpad Dec 7, 2024
cd5c3cd
Add MergeStrategy option for additional form fields
Ammarpad Oct 18, 2024
54057b6
Expand SpecialContactTest
Dreamy-Jazz Dec 9, 2024
b0db81d
build: Updating npm dependencies
Dec 11, 2024
e699481
build: Updating mediawiki/mediawiki-phan-config to 0.15.0
Dec 12, 2024
89a2b63
Localisation updates from https://translatewiki.net.
translatewiki Dec 30, 2024
65b5f1a
Localisation updates from https://translatewiki.net.
translatewiki Jan 1, 2025
b2e1e3b
Localisation updates from https://translatewiki.net.
translatewiki Jan 8, 2025
832340f
selenium: Wait for the page to be fully loaded in Page.openTitle
umherirrender Jan 8, 2025
ac75b21
build: Updating mediawiki/mediawiki-phan-config to 0.15.1
Jan 12, 2025
d23778f
Localisation updates from https://translatewiki.net.
translatewiki Jan 14, 2025
58f65f9
Localisation updates from https://translatewiki.net.
translatewiki Jan 17, 2025
4eaf36f
Merge "selenium: Wait for the page to be fully loaded in Page.openTitle"
Jan 17, 2025
aa164ad
build: Updating wdio-mediawiki to 2.6.0
Jan 19, 2025
89e80d6
Localisation updates from https://translatewiki.net.
translatewiki Jan 21, 2025
6c86709
build: Updating mediawiki/mediawiki-codesniffer to 46.0.0
Jan 31, 2025
ce4c4ff
Localisation updates from https://translatewiki.net.
translatewiki Jan 31, 2025
537fdea
Localisation updates from https://translatewiki.net.
translatewiki Feb 5, 2025
4b6603b
Localisation updates from https://translatewiki.net.
translatewiki Feb 7, 2025
b226233
Localisation updates from https://translatewiki.net.
translatewiki Feb 10, 2025
4ad9491
Localisation updates from https://translatewiki.net.
translatewiki Feb 17, 2025
f30014b
Localisation updates from https://translatewiki.net.
translatewiki Feb 28, 2025
96f5474
Localisation updates from https://translatewiki.net.
translatewiki Mar 3, 2025
dd124aa
Localisation updates from https://translatewiki.net.
translatewiki Mar 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
{
"root": true,
"extends": [
"wikimedia/client",
"wikimedia/jquery",
"wikimedia/mediawiki"
"wikimedia/server"
]
}
4 changes: 1 addition & 3 deletions .phpcs.xml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
<?xml version="1.0"?>
<ruleset>
<rule ref="./vendor/mediawiki/mediawiki-codesniffer/MediaWiki">
<exclude name="MediaWiki.WhiteSpace.SpaceBeforeSingleLineComment.NewLineComment" />
</rule>
<rule ref="./vendor/mediawiki/mediawiki-codesniffer/MediaWiki" />
<file>.</file>
<arg name="extensions" value="php" />
<arg name="encoding" value="UTF-8" />
Expand Down
14 changes: 7 additions & 7 deletions ContactPage.alias.php
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,11 @@
'Contact' => [ 'Контакт' ],
];

/** Serbian (Latin script) (srpski (latinica)‎) */
$specialPageAliases['sr-el'] = [
'Contact' => [ 'Kontakt' ],
];

/** Swedish (svenska) */
$specialPageAliases['sv'] = [
'Contact' => [ 'Kontakt' ],
Expand Down Expand Up @@ -393,17 +398,12 @@
'Contact' => [ '聯絡' ],
];

/** Chinese (中文) */
$specialPageAliases['zh'] = [
'Contact' => [ '联系', '联络', '聯繫', '聯係', '聯絡' ],
];

/** Simplified Chinese (中文(简体)‎) */
$specialPageAliases['zh-hans'] = [
'Contact' => [ '联系' ],
'Contact' => [ '联系', '联络' ],
];

/** Traditional Chinese (中文(繁體)‎) */
$specialPageAliases['zh-hant'] = [
'Contact' => [ '聯絡' ],
'Contact' => [ '聯絡', '聯繫', '聯係' ],
];
7 changes: 3 additions & 4 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,21 @@
*
* @package ContactPage
*/
'use strict';

/* eslint-env node */
module.exports = function ( grunt ) {
var conf = grunt.file.readJSON( 'extension.json' );
const conf = grunt.file.readJSON( 'extension.json' );
grunt.loadNpmTasks( 'grunt-banana-checker' );
grunt.loadNpmTasks( 'grunt-eslint' );

grunt.initConfig( {
banana: conf.MessagesDirs,
eslint: {
options: {
extensions: [ '.js', '.json' ],
cache: true
},
all: [
'**/*.js{,on}',
'**/*.{js,json}',
'!node_modules/**',
'!vendor/**'
]
Expand Down
129 changes: 120 additions & 9 deletions README
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Licenses: GNU General Public Licence (GPL)
GNU Free Documentation License (GFDL)
--------------------------------------------------------------------------

The ContactPage extension implements a contact form for visitors. It
The ContactPage extension implements a contact form for visitors. It
creates a special page Special:Contact, which is similar to
Special:Emailuser, but it has a fixed recipient, and can be used
anonymously.
Expand All @@ -21,7 +21,7 @@ they are mentioned in each file individually.

== Installing ==

Copy the ContactPage directory into the extensions folder of your
Copy the ContactPage directory into the extensions folder of your
MediaWiki installation. Then add the following lines to your
LocalSettings.php file (near the end):

Expand All @@ -38,29 +38,56 @@ $wgContactConfig.
'SenderName' => 'User Email',
'RequireDetails' => true,
'IncludeIP' => true,
'MustBeLoggedIn' => true,
'NameReadonly' => true,
'EmailReadonly' => true,
'SubjectReadonly' => true,
'MustHaveEmail' => true,
'AdditionalFields' => [],
'FieldsMergeStrategy' => null,
'RLModules' => [],
'RLStyleModules' => [],
];

All contact form keys (in this case 'formname') should be in
lowercase.

RecipentUser must be the username of a registered wiki user, who has
The following situations will cause the contact form to be inaccessible:
* Setting EmailReadonly to true if MustBeLoggedIn is false and RequireDetails
is false.
* Setting MustHaveEmail to true if MustBeLoggedIn is false.
* RecipentUser and RecipientEmail being undefined.

One of RecipientUser or RecipientEmail should be defined. If using RecipientUser,
it must be the username of a registered wiki user, who has
supplied an email address, has user-to-user email enabled, and has
confirmed his/her email address if that is required on this wiki
(see $wgEmailAuthentication).
(see $wgEmailAuthentication). If using RecipientEmail, it should be a valid email address.

SenderEmail is used when to send the email when an address isn't
entered on the contact form. It defaults to $wgPasswordSender.

SenderName is the display name used with SenderEmail.

RequireDetails Whether users will be required to supply a name and an
email address on Special:Contact.
RequireDetails is whether the users will be required to supply a name
and an email address on Special:Contact.

IncludeIP is used to decide whether the form will include a checkbox
offering to put the IP address of the submitter in the subject line.

MustBeLoggedIn is whether the contact form is only accessible when
users are logged in.

NameReadonly is used to make the name field readonly.

EmailReadonly is used to make the email field readonly.

SubjectReadonly is used to make the subject field readonly.

IncludeIP Whether the form will include a checkbox offering to put the IP
address of the submitter in the subject line.
MustHaveEmail is used to require that the user loading the form has
a confirmed email address attached to their account. If the user does
not have a confirmed email address, an error will be displayed and the
form will not be shown.

AdditionalFields is used to add any additional fields to the contact form.
These are done using https://www.mediawiki.org/wiki/HTMLForm notation.
Expand All @@ -79,6 +106,90 @@ It should be noted that type 'selectandother' is not currently supported.
],
],

FieldsMergeStrategy defines how fields defined in `AdditionalFields` are
merged with extension-defined fields. It currently accepts only two values
with the following semantic:

1. null (default). In default mode, some fields such as FromName,
and FromAddress are unconditionally defined by the extension and
placed in a fixed location. Configured forms cannot remove them nor
influence their placement locations.
2. The string 'replace'. With this option, the configured form can
redefine some fields already defined by the extension for the
purpose of controlling their placement position in the form or
hiding them completely. Example:

Let's say we want to have a very important field as the first field
of the form.

'AdditionalFields' => [
'ImportantField' => [
'label' => 'This field must be the first field of the form!',
'type' => 'textarea',
],
],

In default mode, this field will appear as the fourth field of the form
(instead of the location we wanted), because the extensions defines 3
other fields unconditionally and placed ours below them.

With `FieldsMergeStrategy` option, it's possibly to make our
'very important' field as the first field in the form.

'AdditionalFields' => [
'ImportantField' => [
'label' => 'This field must be the first field of the form!',
'type' => 'textarea',
],
'FromName' => [
'label-message' => 'contactpage-fromname',
'type' => 'text',
'required' => true,
'default' => null,
'disabled' => false,
],
],

All the these fields will now appear in the order we defined them.
Any non-redefined field will retain their extension-defined order.

Setting any of these fields to null will remove them completely.

Note 1: Field attributes defined in 'AdditionalFields' take precedence
over the following 4 global attributes in form configuration:

$wgContactConfig['formname'] = [
'RequireDetails' => true, // This sets `FromName` and `FromAddress`
// as required fields.
'NameReadonly' => true, // This sets `FromName` as readonly.
'EmailReadonly' => true, // This sets `FromAddress` as readonly.
'SubjectReadonly' => true, // This sets `Subject` as readonly.
];

If FieldsMergeStrategy is 'replace', these will not automatically apply
for any field that's redefined. But you can set any of them explicitly
on the field.

Example:

'FieldsMergeStrategy' => 'replace',
'AdditionalFields' => [
'ImportantField' => [
'label' => 'This field must be the first field of the form!',
'type' => 'textarea',
],
'FromName' => [ // FromName is redefined.
'label-message' => 'contactpage-fromname',
'type' => 'text',
'required' => true, // This takes precedence over 'RequireDetails'
'default' => null, // null means extension should populate it
'disabled' => false // This takes precedence over 'NameReadOnly'
],
],

Note 2: Some special control fields (where applicable) such as the Captcha
form, Email copy and IPAddress checkboxes cannot be redefined or moved.

RLModules can be used to add ResourceLoader modules (custom CSS and
JavaScript) to the page.

Expand All @@ -88,7 +199,7 @@ RLStyleModules can be used to add ResourceLoader CSS modules to the page.

[[Special:Contact]] calls the 'default' form.
Pagetext: [[MediaWiki:contactpage-pagetext]]
Subject: prefilled with text from [[MediaWiki:Contactpage-defsubject]]
Subject: prefilled with text from [[MediaWiki:Contactpage-defsubject]]
E-mail body: empty.

[[Special:Contact/typename]] calls the contact page with a customized pagetext and
Expand Down
21 changes: 14 additions & 7 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"require-dev": {
"mediawiki/mediawiki-codesniffer": "34.0.0",
"mediawiki/mediawiki-phan-config": "0.10.6",
"mediawiki/minus-x": "1.1.0",
"php-parallel-lint/php-console-highlighter": "0.5.0",
"php-parallel-lint/php-parallel-lint": "1.2.0"
"mediawiki/mediawiki-codesniffer": "46.0.0",
"mediawiki/mediawiki-phan-config": "0.15.1",
"mediawiki/minus-x": "1.1.3",
"php-parallel-lint/php-console-highlighter": "1.0.0",
"php-parallel-lint/php-parallel-lint": "1.4.0"
},
"scripts": {
"fix": [
Expand All @@ -13,8 +13,15 @@
],
"test": [
"parallel-lint . --exclude vendor --exclude node_modules",
"phpcs -p -s",
"@phpcs",
"minus-x check ."
]
],
"phan": "phan -d . --long-progress-bar",
"phpcs": "phpcs -sp --cache"
},
"config": {
"allow-plugins": {
"dealerdirect/phpcodesniffer-composer-installer": true
}
}
}
34 changes: 25 additions & 9 deletions extension.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
"descriptionmsg": "contactpage-desc",
"license-name": "GPL-2.0-or-later",
"type": "specialpage",
"requires": {
"MediaWiki": ">= 1.43"
},
"ExtensionMessagesFiles": {
"ContactPageAliases": "ContactPage.alias.php"
},
Expand All @@ -22,11 +25,19 @@
"value": {
"default": {
"RecipientUser": null,
"RecipientEmail": null,
"RecipientName": null,
"SenderEmail": null,
"SenderName": null,
"RequireDetails": false,
"IncludeIP": false,
"MustBeLoggedIn": false,
"MustHaveEmail": false,
"NameReadonly": false,
"EmailReadonly": false,
"SubjectReadonly": false,
"UseCustomBlockMessage": false,
"Redirect": null,
"RLModules": [],
"RLStyleModules": [],
"AdditionalFields": {
Expand All @@ -35,19 +46,24 @@
"type": "textarea",
"required": true
}
}
},
"FieldsMergeStrategy": null
}
}
},
"merge_strategy": "array_plus_2d"
}
},
"SpecialPages": {
"Contact": "SpecialContact"
"Contact": {
"class": "MediaWiki\\Extension\\ContactPage\\SpecialContact",
"services": [
"UserOptionsLookup",
"UserFactory"
]
}
},
"AutoloadClasses": {
"SpecialContact": "includes/SpecialContact.php"
"AutoloadNamespaces": {
"MediaWiki\\Extension\\ContactPage\\": "includes/"
},
"manifest_version": 2,
"requires": {
"MediaWiki": ">= 1.34.0"
}
"manifest_version": 2
}
8 changes: 8 additions & 0 deletions i18n/aae.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"@metadata": {
"authors": [
"Martindimaggio"
]
},
"contactpage": "Kontate"
}
8 changes: 8 additions & 0 deletions i18n/ab.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"@metadata": {
"authors": [
"Fraxinus.cs"
]
},
"contactpage": "Еимадоу адаҟьа"
}
8 changes: 8 additions & 0 deletions i18n/abr.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"@metadata": {
"authors": [
"Alicia Agyeiwaa"
]
},
"contactpage": "Simpie a bɛbɛtumi ne bi adi nkitaho"
}
8 changes: 8 additions & 0 deletions i18n/acf.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"@metadata": {
"authors": [
"Suitcaseshoes"
]
},
"contactpage": "Paj kontakt"
}
Loading