Seperate different maps of maps-object into different panels that
contains text-area to edit the map, delete button to delete the map, and
can be navigated through using a side-bar, that also have "Add new map"
button at the top to add a new map.
Bug: T258820
Change-Id: Ib53a73203f6010b3fd8a5cd78c74c904be2340f2
Adding maps object to TemplateData GUI. By adding mapPanelButton to the
main panel and creating the map panel which contains multiline input
widget to show and insert the map info.
Bug: T254478
Change-Id: Iacff86812cbc448fcdbae24e7eeffb0384781dd5
* I've moved the one remaining file in resources/ to modules/.
The repo had both resources/ and modules/.
* Class files are named after their class.
* Files with init logic on a page are named init.js.
* Files that only export re-usable classes for another module,
are named index.js.
Bug: T193826
Depends-On: If661c68bea069e99cfff35711efdde7805a12851
Change-Id: Ic8975d7ba349ba50f9039545d2eb8d912ccdce26
* This hook supports functionality that Parsoid/JS used the MW API for.
Parsoid's html2wt code requests templatedata for titles one
at a time currently and so this hook also supports lookups one
title at a time.
This initial implementation is good enough for initial Parsoid/PHP
deployment.
* As part of later performance optimization, we should figure out if
we want to fetch templatedata for all templates in batch mode and
work out the details (selser doesn't touch all templates, for one).
The hook does accept an array of titles, but it looks them up
serially in a simple for-loop.
Separately, we need to resolve if this is better architected as
a lookup service vs. a hook as it is now (see discussion on gerrit).
* Tested locally on my local wiki.
Bug: T238954
Change-Id: I01fb6a9f334ca37a703be497524180f87fb8bbf7
Only ever used together as dependencies for module
'ext.templateDataGenerator.editTemplatePage'.
In the UI, they provide icons for the same dialog.
The 'ext.templateData.images' module is also used in one other place,
via addModuleStyles() on NS_TEMPLATE pages that use <templatedata>.
The 'template-format-block' and 'template-format-inline' icons
are used by the Parser output HTML for the documentation block.
Having one unused icon there, preloaded for editing templatedata,
seems acceptable given it's so tiny and basically was already being
paid for on page views with the mere existence of the module taking
up about as much space as the icon itself.
Change-Id: If839100feca51d67bba7151878dfddd1bcbc372b
This change avoids the flash of missing sorting buttons while loading,
but only with I0b446d18f47428d8c0c4aed78b75de16fe106218 in MediaWiki
core included in MediaWiki 1.33 or higher.
Depends-On: I0b446d18f47428d8c0c4aed78b75de16fe106218
Change-Id: I2c3eeb3a83822798ae0c46fcfea071df706798d7
VisualEditorPluginModules loads whenever VE loads, so create a minimal
loader page to check if we are in the template namespace before loading
the rest of the TemplateData init code.
Bug: T208765
Change-Id: Id127eb4a2472a6ce9da7672f9237b182cf6be2eb
SPDX released version 3 of their license list (<https://spdx.org/licenses/>),
which changed the FSF licenses to explicitly end in -only or -or-later
instead of relying on an easy to miss + symbol.
Bug: T183858
Change-Id: Idae56d8787c5843790c1ecd1b1b64ef58702b823
Previous behavior was to silently append a number to the name, which was hard
to notice. New parameters with duplicate names were already blocked.
Also, fix the disabling of the done button when there are errors.
Bug: T166520
Change-Id: I1d0c51a2aa8b8158874c98ac48fe257baeb1aee1
This avoids the exclusion of the rule
MediaWiki.Files.ClassMatchesFilename.NotMatch in .phpcs.xml.
Change-Id: Ifd7f5f59097c6dedc19f031baaef538023a33336
modules/widgets/ext.templateDataGenerator.paramWidget.js
* Add 'layout' as it uses 'menu'
modules/ext.templateDataGenerator.ui.tdDialog.js
* Add 'interactions' as it uses 'advanced'
Bug: T166730
Change-Id: I5b09f629ec274a89f96030de8af64cfe5d659143
Only contains a stylesheet and has a dependency. Module is only
loaded via addModuleStyles, which means the dependency is ignored.
It triggers the warning because it has a dependency, which means
it's not a pure styles-only module (despite being used as such)
> Unexpected general module "ext.templateData" in styles queue.
Aside from the addModuleStyles() load, it is also specified as
a dependency for "ext.templateDataGenerator.ui".
Dependencies on style modules from JS modules are supported since
T87871 was resolved, however the indirect dependency still doens't
make sense.
Move the dependency on ext.templateData.images, which wasn't needed
or triggered by "ext.templateData" styles anyway, to the UI module
directly.
This also fixes the fact that the "ext.templateData" css is loaded
twice (once as blocking stylesheet without dependency, and then
again as async module via "ext.templateDataGenerator.ui" with dependency).
Bug: T92459
Change-Id: I4c3bb44c135fccb85a26ad901ec9660d647dfe86
Create target classes with get/setWikitext methods.
Also refactor some of the window manager code.
Bug: T152230
Change-Id: I7dcc137d79e029b69467ca282d8c52683e022598
Thanks to Thiemo Mättig for the suggestion and specification at
Wikimania 2016 in Esino Lario.
This is an extended version of Thiemo's original specification. This
version also allows specification of "own line" properties for
templates; that is, whether the template should be preceded/followed
by a newline, as requested by James Forrester.
Bug: T138492
Bug: T135667
Change-Id: Idc6b2680330e6bf5caec2bf6fc86a705d25bc649
Reuses some messages, renaming them in the process.
Changes undefined on the client to unknown.
Bug: T61745
Change-Id: I2cf5c25acbe1c854c33b2eb3f23dc74393a456d4
Don't enforce 'inline' as the default format if none is specified.
Instead preserve the unspecified value as 'null'. This allows
third-party tools to provide a better default experience when changing
existing content (e.g. by using smart detection to follow the format
already used).
Bug: T128337
Change-Id: I911c7999e3731c0125fc058118f8d7287d8f88f4