aboutsummaryrefslogtreecommitdiffstats
path: root/includes/pager/TablePager.php
Commit message (Collapse)AuthorAgeFilesLines
* Use explicit nullable type on parameter argumentsUmherirrender2024-10-161-1/+1
| | | | | | | | | | | Implicitly marking parameter $... as nullable is deprecated in php8.4, the explicit nullable type must be used instead Created with autofix from Ide15839e98a6229c22584d1c1c88c690982e1d7a Break one long line in SpecialPage.php Bug: T376276 Change-Id: I807257b2ba1ab2744ab74d9572c9c3d3ac2a968e
* Add namespace and deprecation alias to Xml and XmlSelectEbrahim Byagowi2024-05-161-1/+1
| | | | | | | | | | This patch introduces a new namespace declaration, MediaWiki\Xml and adds Xml and XmlSelect to it and establishes class aliases marked as deprecated since version 1.43. Bug: T353458 Change-Id: I45cccd540b6e15f267d3ab588a064fbeb719d921
* Drop TablePager::getBody(), deprecated since 1.24James D. Forrester2024-05-021-20/+0
| | | | Change-Id: Id7ee6a55938723dc426ca54c7c37d50415f819da
* Standardise all our class alias deprecation comments for ease of greppingJames D. Forrester2024-03-191-4/+1
| | | | Change-Id: I7f85d931d3b79da23e87b4e5692b2e14be8fcaa0
* [ParserOutput] Rename $mText to $mRawText and ::setText() to ::setRawText()C. Scott Ananian2024-02-201-2/+2
| | | | | | | | | | | | | | | | ParserOutput::getText() is not a simple getter, but does transformations on the "text" of the ParserOutput; the simple getter is named ::getRawText(). To maintain consistency, rename ParserOutput::setText() to ::setRawText() and the property name ParserOutput::$mText to ::$mRawText so future readers are not confused. The JSON property name as it appears in the serialized ParserCache is left as 'Text' so that we don't have any forward- or backward- rollback issues. Change-Id: I3ef34814ab9473cc70d0a6806e8c5a4a02b73491
* Namespace includes/contextJames D. Forrester2024-02-081-1/+1
| | | | | Bug: T353458 Change-Id: I4dbef138fd0110c14c70214282519189d70c94fb
* Replace all the OOUI qualifiers with importsDogu2024-01-071-2/+4
| | | | | | | | | | | List of affected classes: - TablePager - DefaultPreferencesFactory - SignatureValidator - SearchFormWidget - SpecialUndelete Change-Id: I63ba23108adb16ee4f8b0f965b05605c70ff7957
* Namespace ParserOutputJames D. Forrester2023-12-141-1/+1
| | | | | | | Most used non-namespaced class! Bug: T353458 Change-Id: I4c2cbb0a808b3881a4d6ca489eee5d8c8ebf26cf
* Namespace core Pagers under \MediaWiki\PagerJames D. Forrester2023-09-181-0/+12
| | | | | Bug: T166010 Change-Id: Ibe12d1754709d48f71edd4cde1f13a542344a21e
* TablePager: Hard-deprecate getBody(), deprecated in 1.24James D. Forrester2023-08-231-0/+2
| | | | Change-Id: I1a4e706f1c364e5ac41aea3b29bfe08d79911411
* Merge "htmlform: Skip array query parameter on HtmlForm::addHiddenField"jenkins-bot2023-03-101-0/+5
|\
| * htmlform: Skip array query parameter on HtmlForm::addHiddenFieldUmherirrender2023-02-101-0/+5
| | | | | | | | | | | | | | Also exclude them in TablePager::getHiddenFields Bug: T321471 Change-Id: Iedcb9071e6543d08d14336a2e96711675b6f5811
* | Reorg: Move HTML-related classes out of includes/ to Html/Amir Sarabadani2023-02-161-0/+1
|/ | | | | Bug: T321882 Change-Id: I5dc1f7e9c303cd3f5b9dd7010d6bb470d8400a18
* pager: Clean up file headers and `@ingroup`Timo Tijhof2022-09-291-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Follows similar commits to the objectcache, rdbms, filerepo, jobqueue components and other areas [1]. * Remove duplicate descriptions from file blocks in favour of class doc blocks. This reduces needless duplication and was often incorrect or outdated, and helps (ironically) to make the file header more consistently visually ignorable. * Remove `ingroup` from file blocks in class files as otherwise the file is indexed twice (e.g. in Doxygen) which makes navigation more messy. * Fix non-standard `@unstable for implementation` annotations in favour of `@stable to type` as per T257789 and <https://www.mediawiki.org/wiki/Stable_interface_policy>. While at it, fix the only other outstanding uses of `@stable for` in core as well in a handful of context/, logging/ and search/ files. [1] https://gerrit.wikimedia.org/r/q/message:ingroup+owner:Krinkle Bug: T257789 Change-Id: Ided3c5ab69e1b587b1b76a3c97a7cdb88f21e130
* Styles should be added to all IndexPagersJon Robson2022-01-111-1/+0
| | | | | | | | | | | TablePager extends IndexPager to add styles to the page However, these styles need to be added to the history page too which uses the HistoryPager where extends IndexPager. Follow up to I0cba011f0ab8cb8fd59962b5eafb7650deefe841 Bug: T298636 Change-Id: I9648308b1c1eb1a544f138c1fcf5e7cd155d172f
* Deprecate `mediawiki.pager.tablePager` module for more generic modulejdlrobson2022-01-071-7/+4
| | | | | | | All pagers sthould share `mediawiki.pager.styles` module Bug: T298636 Change-Id: Idb0c7017407cee5c6b625d39c12219d6ddc9e2db
* AllMessagesTablePager: Avoid double class mw-datatableFomafix2021-10-091-2/+1
| | | | | | | | | | | | | | | This change replaces in the HTML of Special:AllMessages <table class="mw-datatable mw-datatable" id="mw-allmessagestable"> by <table class="mw-datatable" id="mw-allmessagestable"> Remove unnecessary space at the start of the value of the class attribute in TablePager. Inline the one-time used variable $tableClass = $this->getTableClass() Change-Id: I4353d47bda3136cd3a8341677a0288f59895d5c6
* TablePager: fix param documentation for formatValue()DannyS7122021-09-091-1/+2
| | | | | | Can receive null value if the field isn't in the database result. Change-Id: Id995a384dc58f5d8216a7309490b98558004d071
* Remove redundant class="" related condition from TablePagerThiemo Kreuz2021-08-261-7/+1
| | | | | | | The Html class does this already, since 2009 even: https://phabricator.wikimedia.org/rMWf03c53b8a7a9dac33d3ef9947bf2fe5b6c354c9f Change-Id: Ic002790417b2430fe6fce5cd37634c518eda80a2
* TablePager: don't call getRowClass twice when the result was savedDannyS7122021-08-261-1/+1
| | | | | | We have $class already Change-Id: Ia78d313eb12597757bd9045ba9d1e71587e28d93
* Use some more neutral languageReedy2021-04-181-1/+1
| | | | | Bug: T277987 Change-Id: Ieceb01f7a61693a0f03cc331213cb8f93163b8e9
* Rename some variables to use more neutral languageReedy2021-03-191-4/+4
| | | | | Bug: T254646 Change-Id: I997625b8201dce2c257d20f96d00089e995c2b0d
* Improve docs about @param/@return object $row to stdClassUmherirrender2020-11-131-2/+2
| | | | Change-Id: I743d992db703f2b46b6e3abf80c14d026c6599f4
* pager: Fix PHPDoc tags in TablePagerThiemo Kreuz2020-11-111-1/+2
| | | | Change-Id: Iec69eb7f27c616dad5138b54158cbf955e9d5990
* Merge "Replace "@stable for subclassing" with "@stable to extend""jenkins-bot2020-07-131-1/+1
|\
| * Replace "@stable for subclassing" with "@stable to extend"daniel2020-07-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | For compliance with the new version of the table interface policy (T255803). This patch was created by an automated search & replace operation on the includes/ directory. Bug: T257789 Change-Id: Ie32c1b11b3d16ddfc0c83a757327d449ff80b2e4
* | Merge "Replace "@stable for calling" by "@stable to call""jenkins-bot2020-07-131-1/+1
|\ \
| * | Replace "@stable for calling" by "@stable to call"daniel2020-07-131-1/+1
| |/ | | | | | | | | | | | | | | | | | | | | For compliance with the new version of the table interface policy (T255803). This patch was created by an automated search & replace operation on the includes/ directory. Bug: T257789 Change-Id: If560596f5e1e0a3da91afc36e656e7c27f040968
* / Replace "@stable for overriding" with "@stable to override"daniel2020-07-131-12/+12
|/ | | | | | | | | | | For compliance with the new version of the table interface policy (T255803). This patch was created by an automated search & replace operation on the includes/ directory. Bug: T257789 Change-Id: I5ffbb91882ecce2019ab644839eab5e8fb8a1c5f
* Mark pager base classes as stable for subclassing.daniel2020-07-081-0/+25
| | | | | | | | | This makrs Pager baseclasses as stable for subclassing per the Stable Interface Policy. This also indicates which of the methods defined by the base classes can safely be overwritten by extensions. Bug: T247862 Change-Id: If1e0a35427b55d72c86f8f2530bd47aa4130fa92
* Replace @protected tagdaniel2020-06-261-6/+0
| | | | | | | | | | | This patch replaces all usages of @protected in core. The @protected tag was removed in cases where it was redundant or contradictory. It has been replaced by @internal where usage outside of core is not desired, and with @note for cases where use by extensions is desired, but should be limited. Bug: T247862 Change-Id: I5da208e5cb4504dde4113afb3a44922fd01325a3
* Fix some more Squiz.Scope.MethodScope.MissingReedy2020-05-171-21/+13
| | | | Change-Id: I5560d3d65a31f0922c9518b647be690fdb06e6be
* TablePager: Improve documentation for getDefaultSortThalia2020-02-141-0/+4
| | | | Change-Id: I80ef8794c6c2d66a5a1c7d826d97f95ac25b918e
* TablePager: Fix documentation for getIndexField methodThalia2020-02-131-2/+1
| | | | | | | | | | Documentation is now inherited from the parent, which allows several return types. This allows classes that extend TablePager to paginate on multiple columns, introduced in 6786aa5d8e2e87f00a3b1f81d9684ff4eac676ef. Change-Id: Ic2572bfad9cefe52ffb56cd7acab21251b87ecf9
* Restore some previous constructor callsMatěj Suchánek2019-08-271-1/+5
| | | | | | | | | Follow-up to If07f10075a51fbbe9de24464cb6844faaad94780 and I082152b64141f1a9a4085bba23fe81a99ec8d886. It will make getRequest use the provided context again. Change-Id: I60b2598edcb0daed076876482e1e9d6cbf815eb2
* TablePager: put parent construct call back at endElliott Eggleston2019-08-261-2/+3
| | | | | | | | | | | Restores position of parent constructor call, changed in commit I082152b64141f1a. The parent constructor calls getIndexField(), which depends on the mSort value already being set. Bug: T231261 Change-Id: If07f10075a51fbbe9de24464cb6844faaad94780
* Clean up LinkRenderer usage in IndexPager and extensionsMatěj Suchánek2019-08-251-6/+4
| | | | | | | | | The property needs to be private because pagers in extensions may declare the same property with stronger visibility which would crash. Bug: T149346 Change-Id: I082152b64141f1a9a4085bba23fe81a99ec8d886
* Replace 'TablePager' CSS class exclusively by `mw-datatable`Volker E2019-03-131-2/+3
| | | | | | | | | | `mw-datatable` has already been in use and should be the main class for styling TablePager tables. `mw-datatable` also includes the equivalent padding of former `.TablePager th` & `td`, therefore removing it. Bug: T214218 Change-Id: I2025b2ede87035e15f0280a6fe5efddec174bcca
* Merge "Replace sorting classes with better naming convention"jenkins-bot2019-03-131-2/+2
|\
| * Replace sorting classes with better naming conventionVolker E2019-03-121-2/+2
| | | | | | | | | | | | | | Improving CSS structure by removing code duplications. Bug: T214218 Change-Id: I0501e1ab934aef3af289fee618b99578a1f0285c
* | Add @var to Pager classesUmherirrender2019-03-071-0/+2
|/ | | | | | | | | | | | | | | Some are needed to make better results with phan in extensions For example: File CentralNoticeCampaignLogPager.php line 12: Assigning array{0:20,1:50,2:100} to property but \CentralNoticeCampaignLogPager->mLimitsShown is array{0:20,1:50,2:100,3:250,4:500} [PhanTypeMismatchProperty] With "@var int[]" the type is correct Change-Id: Ic68910bf17344852ad11fcc000a47891e4bf0179
* TablePager: Reduce pagination button in visual strengthVolker E2019-01-171-0/+3
| | | | | | | | Reducing buttons to `frameless` buttons and reposition icons of next and last page button to be symmetrically harmonious. Bug: T214128 Change-Id: I1c0a621d7699b5fadc2559abdf6003a0db0aabae
* Mark protected IndexPager properties also as protected in subclassesThiemo Kreuz2018-12-201-2/+2
| | | | | | | | | | I'm intentionally only touching these protected properties and nothing else, because I believe these are uncontroversial. They should be protected according to modern SOLID standards, and actually are declared as protected in the base class. What this patch effectively does is documenting this fact, but it does not change anything. Change-Id: I625307b58bd419c4a72e9842b2b46c08ed9b4f8e
* Remove unused $links in TablePager::getNavigationBaraddshore2018-07-181-1/+0
| | | | Change-Id: I43ba3390c47e4955704cfd82b16627008f9e6bc8
* Use \u{00A0} instead of &#160; or &nbsp;Fomafix2018-06-241-2/+2
| | | | | | | | | | | | | Directly use the UTF-8 encoding of the 'NO-BREAK SPACE' (U+00A0) instead of the HTML/XML entities &#160; or &#xa0; or &nbsp;. With the UTF-8 character the generated HTML is shorter and better to read. Also change the special value for the label in HTMLForm from &#160; to U+00A0 but also support &#160; for backward compability. Bug: T154300 Change-Id: I882599ac1120789bb4e524c4394870680caca4f4
* Use PHP 7 '??' operator instead of '?:' with 'isset()' where convenientBartosz Dziewoński2018-05-301-1/+1
| | | | | | | | | | | | | | Find: /isset\(\s*([^()]+?)\s*\)\s*\?\s*\1\s*:\s*/ Replace with: '\1 ?? ' (Everywhere except includes/PHPVersionCheck.php) (Then, manually fix some line length and indentation issues) Then manually reviewed the replacements for cases where confusing operator precedence would result in incorrect results (fixing those in I478db046a1cc162c6767003ce45c9b56270f3372). Change-Id: I33b421c8cb11cdd4ce896488c9ff5313f03a38cf
* OOUI-ificiation of TablePager navEd Sanders2017-05-031-29/+30
| | | | | | | Depends on next OOUI release for new icons. Bug: T163715 Change-Id: Ia750131aae52c35181209277c5b951a447db1b5a
* Fix type annotationsMax Semenik2016-12-151-1/+1
| | | | Change-Id: Ib72c98358b2f0b3b73b6f105adea47346373d46d
* Update weblinks in comments from HTTP to HTTPSFomafix2016-11-071-1/+1
| | | | | | | | Use HTTPS instead of HTTP where the HTTP link is a redirect to the HTTPS link. Also update some defect links. Change-Id: Ic3a5eac910d098ed5c2a21e9f47c9b6ee06b2643
* Make some TablePager methods actually protectedRicordisamoa2016-04-091-6/+3
| | | | | | | | * getTableClass * getNavClass * getSortHeaderClass Change-Id: I459ca456149635e3300c7ca7cfed4c1edc1c12b1