mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Linter
synced 2024-09-23 10:21:52 +00:00
Display self-closed tags
Change-Id: I6c084a6c72114b57a21cd367d398c673c5c4d991
This commit is contained in:
parent
7e4bd54edb
commit
958623f0fb
|
@ -55,7 +55,8 @@
|
|||
"obsolete-tag": true,
|
||||
"bogus-image-options": true,
|
||||
"missing-end-tag": true,
|
||||
"stripped-tag": true
|
||||
"stripped-tag": true,
|
||||
"self-closed-tag": true
|
||||
},
|
||||
"LinterSubmitterWhitelist": {
|
||||
"127.0.0.1": true
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
"linter-pager-bogus-image-options-details": "Bogus file option",
|
||||
"linter-pager-missing-end-tag-details": "Missing end tag",
|
||||
"linter-pager-stripped-tag-details": "Stripped tag",
|
||||
"linter-pager-self-closed-tag-details": "Self-closed tag",
|
||||
"linter-category-fostered": "Fostered content",
|
||||
"linter-category-fostered-desc": "These pages have fostered content.",
|
||||
"linter-category-obsolete-tag": "Obsolete HTML tags",
|
||||
|
@ -23,6 +24,8 @@
|
|||
"linter-category-missing-end-tag-desc": "These pages have missing end tags.",
|
||||
"linter-category-stripped-tag": "Stripped tags",
|
||||
"linter-category-stripped-tag-desc": "These pages have stripped tags.",
|
||||
"linter-category-self-closed-tag": "Self-closed tags",
|
||||
"linter-category-self-closed-tag-desc": "These pages have self-closed tags.",
|
||||
"linker-page-title-edit": "$1 ($2)",
|
||||
"linker-page-edit": "edit",
|
||||
"apihelp-query+linterrors-description": "Get a list of lint errors",
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
"linter-pager-bogus-image-options-details": "Table column heading",
|
||||
"linter-pager-missing-end-tag-details": "Table column heading",
|
||||
"linter-pager-stripped-tag-details": "Table column heading",
|
||||
"linter-pager-self-closed-tag-details": "Table column heading",
|
||||
"linter-category-fostered": "Name of lint error category. See [[:mw:Help:Extension:Linter/fostered]]",
|
||||
"linter-category-fostered-desc": "Description of category.",
|
||||
"linter-category-obsolete-tag": "Name of lint error category. See [[:mw:Help:Extension:Linter/obsolete-tag]]",
|
||||
|
@ -23,8 +24,10 @@
|
|||
"linter-category-bogus-image-options-desc": "Description of category",
|
||||
"linter-category-missing-end-tag": "Name of lint error category. See [[:mw:Help:Extension:Linter/missing-end-tag]]",
|
||||
"linter-category-missing-end-tag-desc": "Description of category",
|
||||
"linter-category-stripped-tag": "Name of lint error category",
|
||||
"linter-category-stripped-tag": "Name of lint error category. See [[:mw:Help:Extension:Linter/stripped-tag]]",
|
||||
"linter-category-stripped-tag-desc": "Description of category",
|
||||
"linter-category-self-closed-tag": "Name of lint error category. See [[:mw:Help:Extension:Linter/self-closed-tag]]",
|
||||
"linter-category-self-closed-tag-desc": "Description of category",
|
||||
"linker-page-title-edit": "Used in a table cell. $1 is a link to the page, $2 is a link to edit that page, the link text is {{msg-mw|linker-page-edit}}",
|
||||
"linker-page-edit": "Link text for edit link in {{msg-mw|linker-page-title-edit}} and {{msg-mw|linker-page-title-edit-template}}\n{{Identical|Edit}}",
|
||||
"apihelp-query+linterrors-description": "{{doc-apihelp-description|query+linterrors}}",
|
||||
|
|
|
@ -95,7 +95,7 @@ class LintErrorsPager extends TablePager {
|
|||
|
||||
return $this->msg( 'linker-page-title-edit' )->rawParams( $viewLink, $editLink )->escaped();
|
||||
case 'details':
|
||||
$hasNameCats = [ 'obsolete-tag', 'missing-end-tag' ];
|
||||
$hasNameCats = [ 'obsolete-tag', 'missing-end-tag', 'self-closed-tag' ];
|
||||
if ( in_array( $this->category, $hasNameCats ) && isset( $lintError->params['name'] ) ) {
|
||||
return Html::element( 'code', [], $lintError->params['name'] );
|
||||
} elseif ( $this->category === 'bogus-image-options' && isset( $lintError->params['items'] ) ) {
|
||||
|
|
Loading…
Reference in a new issue