diff --git a/includes/TemplateDataHtmlFormatter.php b/includes/TemplateDataHtmlFormatter.php
index 16d6785a..759c65fd 100644
--- a/includes/TemplateDataHtmlFormatter.php
+++ b/includes/TemplateDataHtmlFormatter.php
@@ -72,16 +72,16 @@ class TemplateDataHtmlFormatter {
. ''
. '
'
. Html::rawElement( 'caption', [],
- // Edit interface is only loaded in the template namespace (see Hooks::onEditPage)
- ( $showEditLink && $frameTitle->inNamespace( NS_TEMPLATE ) ?
- Html::element( 'mw:edittemplatedata', [
- 'page' => $frameTitle->getPrefixedText()
- ] ) :
- ''
- ) .
- Html::element( 'p',
+ Html::rawElement( 'p',
[ 'class' => 'mw-templatedata-caption' ],
- $this->localizer->msg( 'templatedata-doc-params' )->text()
+ $this->localizer->msg( 'templatedata-doc-params' )->escaped() .
+ // Edit interface is only loaded in the template namespace (see Hooks::onEditPage)
+ ( $showEditLink && $frameTitle->inNamespace( NS_TEMPLATE ) ?
+ Html::element( 'mw:edittemplatedata', [
+ 'page' => $frameTitle->getPrefixedText()
+ ] ) :
+ ''
+ )
)
. ( $formatMsg ?
Html::rawElement( 'p', [],
diff --git a/modules/ext.templateData/templateData.less b/modules/ext.templateData/templateData.less
index 5911b673..215779c6 100644
--- a/modules/ext.templateData/templateData.less
+++ b/modules/ext.templateData/templateData.less
@@ -1,16 +1,15 @@
.mw-templatedata-doc-params {
- tbody > tr > th {
+ caption {
text-align: left;
- font-weight: normal;
}
.mw-templatedata-caption {
- margin: 0.5em 10em;
+ font-size: 1.2em;
}
- .mw-editsection-like {
- float: right;
- line-height: 2.5em;
+ tbody > tr > th {
+ text-align: left;
+ font-weight: normal;
}
}
diff --git a/tests/phpunit/TemplateDataBlobTest.php b/tests/phpunit/TemplateDataBlobTest.php
index 1348e1be..456d8a8c 100644
--- a/tests/phpunit/TemplateDataBlobTest.php
+++ b/tests/phpunit/TemplateDataBlobTest.php
@@ -1447,8 +1447,7 @@ class TemplateDataBlobTest extends MediaWikiIntegrationTestCase {
-
- (templatedata-doc-params)
+ (templatedata-doc-params)
(templatedata-doc-param-name) | (templatedata-doc-param-desc) | (templatedata-doc-param-type) | (templatedata-doc-param-status) |
@@ -1467,8 +1466,7 @@ HTML
-
- (templatedata-doc-params)
+ (templatedata-doc-params)
(templatedata-doc-param-name) | (templatedata-doc-param-desc) | (templatedata-doc-param-type) | (templatedata-doc-param-status) |
@@ -1510,8 +1508,7 @@ HTML
-
- (templatedata-doc-params)
+ (templatedata-doc-params)
(templatedata-doc-param-name) | (templatedata-doc-param-desc) | (templatedata-doc-param-type) | (templatedata-doc-param-status) |