Commit graph

30 commits

Author SHA1 Message Date
jenkins-bot
436a1b9fb8 Merge "Document mediawiki.widgets.visibleLengthLimit and resources/src/mediawiki.watchstar.widgets" 2024-02-05 16:22:58 +00:00
Jon Robson
c075bde35e Documentation: Add documentation for temporary user code
Bug: T352308
Change-Id: Ifaf73761a8409be063f8c4659719fd3def7ea340
2024-02-05 05:08:45 +00:00
Jon Robson
7a3de16ade Document mediawiki.widgets.visibleLengthLimit and resources/src/mediawiki.watchstar.widgets
Bug: T352308
Change-Id: I651ca7c7955daf1d8fd9adcf6ac1576c08f33816
2024-01-29 22:46:22 +00:00
Jon Robson
5ba3de3964 Documentation: Add documentation for several trivial modules
Bug: T352308
Change-Id: Ib4c27c843362e61f6fd9854f78d7acac213719f3
2024-01-17 21:02:01 +00:00
Jon Robson
2cd018cacd Documentation: Move to exclude list
* Generate documentation for all files in resources/src
* Include all files documented in phase 3 as not having public APIs. Add
@ignore tag to documentation that shows up in published document.

Bug: T352308
Change-Id: I5d643d815ffa2f578d12bb9ca70e26558a442c32
2024-01-16 10:12:15 -08:00
Bartosz Dziewoński
4e59afd37d Update links to OOUI documentation
OOUI uses JSDoc now (T185396). Update links from the JSDuck format.

Remove an unnecessary @see that was pointing to a private method with
no documentation.

Change-Id: I26b0f0d586f4ba23974cadd34662d3ffc7f8ccba
2024-01-13 01:20:28 +01:00
Jon Robson
cf753db224 Documentation: mw.widget
* Add to documentations
* Add full stops to sentences in summaries where missing
* Correct a few instances of "set" with "get"

Bug: T352308
Change-Id: I6cb00167041d6e0936730eea298daf4fc2e485b5
2024-01-09 08:29:05 -08:00
Jon Robson
d10dd8cc4a Document jQuery plugins
Bug: T352308
Change-Id: Id3a0ec3d71e4e2966baf46f43652001c3b00674a
2024-01-08 16:34:41 +00:00
Jon Robson
6d56fb9b8a Document mw.Feedback
Bug: T352308
Change-Id: Ic76c51d43f8bccad9d10bae1078d2f94b221bebe
2024-01-08 02:25:43 +00:00
Jon Robson
b7425fe4b9 Document mediawiki.template
Bug: T352308
Change-Id: I6164c06cad08683295b7af138519979bf058b959
2024-01-03 22:31:03 +00:00
jenkins-bot
45b1adafc8 Merge "Documentation: Document mediawiki.page.ready" 2024-01-03 18:18:31 +00:00
Jon Robson
c8f372646b Documentation: Document mediawiki.page.ready
Bug: T352308
Change-Id: I1947d923a20aff08fabec486dc82b740b12a0e4a
2023-12-22 18:24:11 +00:00
MusikAnimal
420b2026fc mediawiki.page.watch.ajax: document module
Changes:
* Marked public methods as @stable, marked all others as @private
* Fix indentation of example in util.js

Bug: T352308
Change-Id: I051773b87c3009141ded67d506c1fd683bbb1f60
2023-12-22 09:48:06 -08:00
Roan Kattouw
9974f62ce1 documentation: Convert mw.Upload and mw.ForeignUpload to jsdoc
Bug: T352308
Change-Id: I857307b9856a56094600c8fc4d9ffcc825c11f80
2023-12-20 10:29:11 -08:00
jenkins-bot
08ea456a59 Merge "mediawiki.page.preview: document module in JSDoc" 2023-12-19 21:08:48 +00:00
Jon Robson
027a36050f mediawiki.storage: Document in jsdoc
Bug: T352308
Change-Id: I1b1818ea10159e1f27d7f4f16a20484e6aefa3c1
2023-12-19 15:33:12 -05:00
Roan Kattouw
e365e22ab7 documentation: Convert mediawiki.api from jsduck to jsdoc
Bug: T352308
Change-Id: Ia9320213e2208bb45a7f162b5b5c385fbed09599
2023-12-19 05:54:50 +00:00
MusikAnimal
2d42573059 mediawiki.page.preview: document module in JSDoc
Bug: T352308
Change-Id: I2d9558a6a4741fd2348fb79890cc9a5c32f3afb0
2023-12-18 16:04:49 -05:00
lwatson
2017035b0a Documentation: Port mw.user to JSDoc
Bug: T352308
Change-Id: I3b9d3f6409d5a6ea09d3e4aefb773844e99508a4
2023-12-18 10:45:41 -05:00
jenkins-bot
1e83812456 Merge "Documentation: Port mw.Uri to JSDoc" 2023-12-16 01:46:06 +00:00
lwatson
a9f2f2da2d Documentation: Port mw.Uri to JSDoc
Bug: T352308
Change-Id: If780d42c77ac270046ac19a534c758ef2e6f7215
2023-12-15 20:15:46 -05:00
Jon Robson
3e25486412 Cookie: Document in jsdoc
Changes:
* Switch from mixed to string|null since cookies always cast
to a string. For example `mw.cookie.set('foo',6)` results in '6'
and `mw.cookie.set('foo',[1,2,3])` results in '1,2,3'.

Bug: T35230
Change-Id: I4a27abe6b430fef75506df129f3168dcc4bbd565
2023-12-15 12:09:09 -08:00
Jon Robson
8a523b0684 mw.Title: Document in jsdoc
Bug: T352308
Change-Id: I5db0fd4fef027a4d97953079a69c14f64f835f68
2023-12-14 13:28:21 -08:00
Jon Robson
1c680ee4d6 mediawiki:string: Document module
Changes:
* Addresses eslint warnings relating to multiple @return
types
* Adopt ES6 shorthand function for return values

Bug: T352308
Change-Id: I43cb7e8e5f8c9ded46249e5f26a60a314b7d8cb1
2023-12-13 10:57:45 -10:00
jenkins-bot
b49ee0dbf2 Merge "Documentation: Migrate jQuery lengthLimit plugin to JSDoc" 2023-12-13 18:15:48 +00:00
Anne Tomasevich
90954ca1e3 Documentation: Migrate mw.experiments docs to JSDoc
Bug: T352308
Change-Id: I3bccaab232647f2c368758bd6c7e395d9b009bae
2023-12-13 12:42:16 -05:00
Anne Tomasevich
fe74981756 Documentation: Migrate jQuery lengthLimit plugin to JSDoc
Bug: T352308
Change-Id: Ie415603420b818bb3aa20215965d488b538a0931
2023-12-13 11:41:02 -05:00
Roan Kattouw
cdfed92c8b jsdoc: Use the summarize plugin
Bug: T344861
Change-Id: I699cd2a5584e78065594d6debbb6f2a2e6d1f7c4
2023-12-07 18:08:19 +00:00
Jon Robson
9f2e4faea3 Documentation: Expand the documentation in jsdoc
Significant changes:
* The Notification class was marked as private but is returned
by a public mw.notify function so presumably is a public interface
so is no longer marked as @private
* I've documented the mw object under namespaces and reserved the
class section for types that are referenced within that documentation.
* mw.loader methods used by ResourceLoader but not intended as public
APIs are marked as public after talking to Roan. This can be modified
later if necessary.
* Remove jsduck eslint plugin from startup module

Notes about organization:
* ResourceLoader Modules are documented under modules. After discussing
with Roan, Anne and Alex this makes sense for now. We can pivot at the end
of the project if needed. MediaWiki util module acts as an example for modules
that also appear on the global mw object
* We use namespaces for libraries on the mw global
* Global methods are documented on the Window namespace
* All hooks are documented under the mw.hook namespace given the namespace
provided important information for how to use them.

Bug: T352308
Change-Id: Ia709de48cbc0f00ff832eb4666e6abcffdb6f710
2023-12-07 18:07:27 +00:00
Jon Robson
dfea3e8e5a Add jsdoc with jsdoc-wmf-theme
jsduck is preventing us from using ES6 syntax and has not
been supported for some time. It is also difficult to setup
locally due its use of Ruby.

Introduce jsdoc and remove jsduck per T138401#9335987
Link to static copy of jsduck explaining the state

This does the bare minimum - the docs are built to the folder
docs/js/index.html and only one module is ported over to allow
us to provide feedback on the end result.

Bug: T138401
Change-Id: I1a351ac5aec731bb79a877023ac10988ec3ec786
2023-11-28 00:37:48 +00:00