MediaWiki:Gadget-UserRightsManager.js: Difference between revisions
Jump to navigation
Jump to search
MediaWiki:Gadget-UserRightsManager.js (view source)
Revision as of 14:07, 27 February 2024
, 27 Februaryno edit summary
mNo edit summary |
No edit summary Tags: Mobile edit Mobile web edit |
||
(One intermediate revision by one other user not shown) | |||
Line 10: | Line 10: | ||
'bureaucrat': 'Bureaucrat', | 'bureaucrat': 'Bureaucrat', | ||
'interface-admin': 'Interface administrator', | 'interface-admin': 'Interface administrator', | ||
'non- | 'non-stewardsuppress': 'Suppressor', | ||
} | } | ||
var cannedResponses = { | var cannedResponses = { | ||
'sysop': '{{ | 'sysop': '{{administrator granted}} ~~~~', | ||
'bureaucrat': '{{bureaucrat granted}} ~~~~', | 'bureaucrat': '{{bureaucrat granted}} ~~~~', | ||
'interface-admin': '{{interface administrator granted}} ~~~~', | 'interface-admin': '{{interface administrator granted}} ~~~~', | ||
'non- | 'non-stewardsuppress': '{{done}}. ~~~~' | ||
}; | }; | ||
Line 73: | Line 73: | ||
disabled: !mw.config.get('wgUserGroups').includes('steward') | disabled: !mw.config.get('wgUserGroups').includes('steward') | ||
}); | }); | ||
this. | this.groupsNonStewardSuppressInput = new OO.ui.CheckboxInputWidget({ | ||
selected: permissionText.includes('suppress') && mw.config.get('wgUserGroups').includes('steward'), | selected: permissionText.includes('suppress') && mw.config.get('wgUserGroups').includes('steward'), | ||
disabled: !mw.config.get('wgUserGroups').includes('steward') | disabled: !mw.config.get('wgUserGroups').includes('steward') | ||
Line 92: | Line 92: | ||
new OO.ui.FieldLayout(this.groupsBureaucratInput, {label: 'Bureaucrat', align: 'inline'}), | new OO.ui.FieldLayout(this.groupsBureaucratInput, {label: 'Bureaucrat', align: 'inline'}), | ||
new OO.ui.FieldLayout(this.groupsInterfaceAdminInput, {label: 'Interface administrator', align: 'inline'}), | new OO.ui.FieldLayout(this.groupsInterfaceAdminInput, {label: 'Interface administrator', align: 'inline'}), | ||
new OO.ui.FieldLayout(this. | new OO.ui.FieldLayout(this.groupsNonStewardSuppressInput, {label: 'Suppressor', align: 'inline'}), | ||
] | ] | ||
}) | }) | ||
Line 132: | Line 132: | ||
if(this.groupsBureaucratInput.isSelected()) perms.push('bureaucrat'); | if(this.groupsBureaucratInput.isSelected()) perms.push('bureaucrat'); | ||
if(this.groupsInterfaceAdminInput.isSelected()) perms.push('interface-admin'); | if(this.groupsInterfaceAdminInput.isSelected()) perms.push('interface-admin'); | ||
if(this. | if(this.groupsNonStewardSuppressInput.isSelected()) perms.push('non-stewardsuppress'); | ||
var self = this, promiseCount = 2; | var self = this, promiseCount = 2; |