Finish hooking up the frontend from {T377575} to the [[ https://www.mediawiki.org/wiki/Community_Configuration | community configuration ]] backend storage. The configuration variable for backlink symbol set will be a single string.
* [x] Define backlink configuration in `CiteSchema.php`.
* Root schema should be an Object, to leave space for additional features to be configured.
* Backlink configuration is a String naming the current alphabet. The variable name can be something like "BacklinkAlphabet".
* Backlink config defaults to some kind of `undefined`, which is a clear signal to use the legacy value. We allow null or empty string.
* See [[ https://gerrit.wikimedia.org/g/mediawiki/extensions/CommunityConfigurationExample/+/a8f5322f66fc111059863db813ff5c4f69cc83a0/src/Config/Schemas/ExampleSchema.php | example schema ]]
* [x] Implement a new subclass of `AbstractEditorCapability` (see below).
* [x] Needs to show up as a subpage like `Special:CommunityConfiguration/Cite` .
* [x] Configuration page is hidden behind a feature flag, enabled only when `$wgCiteUseNumericBacklinkLabels === false`. Ideally the page does not show at all in that case.
* [ ] Load stored configurations into the UI on page open, save changes back to the store when the submit button is clicked. This is probably simplest to implement by sending the form data to the backend and then calling `$provider->storeValidConfiguration()`.
##Mockup
{F58315300}
{F58315302}
Text:
> Backlinks appear in the reference list and point back to the footnotes in the article. When a reference is used more than once, its backlinks are numbered. Configuration allows a custom alphabet to be used for this purpose.
> Input your custom character set, with a space between each character.
##Implementation
- Implement the page following the basic structure of https://github.com/wikimedia/mediawiki-extensions-CommunityConfiguration/blob/master/src/EditorCapabilities/GenericFormEditorCapability.php and implement a new subclass of AbstractEditorCapability. Register in extension.json using code like this,
- See also https://www.mediawiki.org/wiki/Extension:CommunityConfiguration/Technical_documentation for basic technical documentation
- And an example extension using it in https://gitlab.wikimedia.org/repos/growth/community-configuration-example
```
"attributes": {
"CommunityConfiguration": {
"EditorCapabilities": {
"citeEditor": {
// must be an implementation of IEditorCapability; AbstractEditorCapability is provided as an optional (but recommended) helper
"class": "MediaWiki\\Extension\\Cite\\CiteEditorCapability"
"services": [...]
}
},
"Providers": {
"cite": {
"store": {
"type": "wikipage",
"args": [ "MediaWiki:CiteConfig.json" ]
},
"validator": {
"type": "jsonschema",
"args": [...]
},
"type": "mw-config" // or "data",
"options": {
"editorCapability": "citeEditor" // or whatever the capability was registered as in the above
}
}
}
}
}
```