mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Linter
synced 2024-11-12 01:09:49 +00:00
Add multi-colon-escape linter medium-priority category
Change-Id: I9f21f3128b78e7b2459c18a9121605dffd5a1bc4
This commit is contained in:
parent
ab1b9e325e
commit
875e0f84a0
|
@ -107,6 +107,10 @@
|
|||
"enabled": true,
|
||||
"priority": "high",
|
||||
"parser-migration": true
|
||||
},
|
||||
"multi-colon-escape": {
|
||||
"enabled": true,
|
||||
"priority": "medium"
|
||||
}
|
||||
},
|
||||
"LinterSubmitterWhitelist": {
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
"linter-pager-obsolete-tag-details": "Obsolete HTML tag",
|
||||
"linter-pager-bogus-image-options-details": "Bogus file option",
|
||||
"linter-pager-missing-end-tag-details": "Missing end tag",
|
||||
"linter-pager-multi-colon-escape-details": "Multi colon escape",
|
||||
"linter-pager-stripped-tag-details": "Stripped tag",
|
||||
"linter-pager-self-closed-tag-details": "Self-closed tag",
|
||||
"linter-pager-deletable-table-tag-details": "Table tag that should be deleted",
|
||||
|
@ -27,6 +28,8 @@
|
|||
"linter-category-bogus-image-options-desc": "These pages have files with bogus options.",
|
||||
"linter-category-missing-end-tag": "Missing end tag",
|
||||
"linter-category-missing-end-tag-desc": "These pages have missing end tags.",
|
||||
"linter-category-multi-colon-escape": "Multi colon escape",
|
||||
"linter-category-multi-colon-escape-desc": "These pages have links prefixed with multiple colons.",
|
||||
"linter-category-stripped-tag": "Stripped tags",
|
||||
"linter-category-stripped-tag-desc": "These pages have stripped tags.",
|
||||
"linter-category-self-closed-tag": "Self-closed tags",
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
"linter-pager-obsolete-tag-details": "Table column heading",
|
||||
"linter-pager-bogus-image-options-details": "Table column heading",
|
||||
"linter-pager-missing-end-tag-details": "Table column heading",
|
||||
"linter-pager-multi-colon-escape-details": "Table column heading",
|
||||
"linter-pager-stripped-tag-details": "Table column heading",
|
||||
"linter-pager-self-closed-tag-details": "Table column heading",
|
||||
"linter-pager-deletable-table-tag-details": "Table column heading",
|
||||
|
@ -31,6 +32,8 @@
|
|||
"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-multi-colon-escape": "Name of lint error category. See [[:mw:Help:Extension:Linter/multi-colon-escape]]",
|
||||
"linter-category-multi-colon-escape-desc": "Description of 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]]",
|
||||
|
|
|
@ -45,7 +45,8 @@ class CategoryManager {
|
|||
'deletable-table-tag' => 7,
|
||||
'misnested-tag' => 8,
|
||||
'pwrap-bug-workaround' => 9,
|
||||
'tidy-whitespace-bug' => 10
|
||||
'tidy-whitespace-bug' => 10,
|
||||
'multi-colon-escape' => 11,
|
||||
];
|
||||
|
||||
/**
|
||||
|
|
|
@ -160,6 +160,9 @@ class LintErrorsPager extends TablePager {
|
|||
isset( $lintError->params['sibling'] ) ) {
|
||||
return Html::element( 'code', [],
|
||||
$lintError->params['node'] . " + " . $lintError->params['sibling'] );
|
||||
} elseif ( $this->category === 'multi-colon-escape' &&
|
||||
isset( $lintError->params['href'] ) ) {
|
||||
return Html::element( 'code', [], $lintError->params['href'] );
|
||||
}
|
||||
return '';
|
||||
case 'template':
|
||||
|
|
Loading…
Reference in a new issue