Umherirrender has uploaded a new change for review.
https://gerrit.wikimedia.org/r/229654
Change subject: API: Use message-per-value for apihelp-query+search-param-prop
......................................................................
API: Use message-per-value for apihelp-query+search-param-prop
Use message-per-value for message
apihelp-query+search-param-prop to allow smaller strings
for translation.
Each prop in a message also will show up a new parameter on the help
page without the adjust of the translation (but than in english instead
of fully skip it).
Change-Id: Id2088213f4577c8cb88e479e8fca0e6bd3d619f4
---
M includes/api/ApiQuerySearch.php
M includes/api/i18n/en.json
M includes/api/i18n/qqq.json
3 files changed, 31 insertions(+), 4 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/54/229654/1
diff --git a/includes/api/ApiQuerySearch.php b/includes/api/ApiQuerySearch.php
index 349e7fa..65fd727 100644
--- a/includes/api/ApiQuerySearch.php
+++ b/includes/api/ApiQuerySearch.php
@@ -316,18 +316,19 @@
'size',
'wordcount',
'timestamp',
- 'score',
'snippet',
'titlesnippet',
'redirecttitle',
'redirectsnippet',
'sectiontitle',
'sectionsnippet',
- 'hasrelated',
'isfilematch',
'categorysnippet',
+ 'score', // deprecated
+ 'hasrelated', // deprecated
),
ApiBase::PARAM_ISMULTI => true,
+ ApiBase::PARAM_HELP_MSG_PER_VALUE => array(),
),
'offset' => array(
ApiBase::PARAM_DFLT => 0,
diff --git a/includes/api/i18n/en.json b/includes/api/i18n/en.json
index ae7a9c6..a510af3 100644
--- a/includes/api/i18n/en.json
+++ b/includes/api/i18n/en.json
@@ -914,7 +914,20 @@
"apihelp-query+search-param-namespace": "Search only within these
namespaces.",
"apihelp-query+search-param-what": "Which type of search to perform.",
"apihelp-query+search-param-info": "Which metadata to return.",
- "apihelp-query+search-param-prop": "Which properties to
return:\n;size:Adds the size of the page in bytes.\n;wordcount:Adds the word
count of the page.\n;timestamp:Adds the timestamp of when the page was last
edited.\n;snippet:Adds a parsed snippet of the page.\n;titlesnippet:Adds a
parsed snippet of the page title.\n;redirectsnippet:Adds a parsed snippet of
the redirect title.\n;redirecttitle:Adds the title of the matching
redirect.\n;sectionsnippet:Adds a parsed snippet of the matching section
title.\n;sectiontitle:Adds the title of the matching
section.\n;categorysnippet:Adds a parsed snippet of the matching
category.\n;isfilematch:Adds a boolean indicating if the search matched file
content.\n;score:<span class=\"apihelp-deprecated\">Deprecated and
ignored.</span>\n;hasrelated:<span class=\"apihelp-deprecated\">Deprecated and
ignored.</span>",
+ "apihelp-query+search-param-prop": "Which properties to return:",
+ "apihelp-query+search-paramvalue-prop-size": "Adds the size of the page
in bytes.",
+ "apihelp-query+search-paramvalue-prop-wordcount": "Adds the word count
of the page.",
+ "apihelp-query+search-paramvalue-prop-timestamp": "Adds the timestamp
of when the page was last edited.",
+ "apihelp-query+search-paramvalue-prop-snippet": "Adds a parsed snippet
of the page.",
+ "apihelp-query+search-paramvalue-prop-titlesnippet": "Adds a parsed
snippet of the page title.",
+ "apihelp-query+search-paramvalue-prop-redirectsnippet": "Adds a parsed
snippet of the redirect title.",
+ "apihelp-query+search-paramvalue-prop-redirecttitle": "Adds the title
of the matching redirect.",
+ "apihelp-query+search-paramvalue-prop-sectionsnippet": "Adds a parsed
snippet of the matching section title.",
+ "apihelp-query+search-paramvalue-prop-sectiontitle": "Adds the title of
the matching section.",
+ "apihelp-query+search-paramvalue-prop-categorysnippet": "Adds a parsed
snippet of the matching category.",
+ "apihelp-query+search-paramvalue-prop-isfilematch": "Adds a boolean
indicating if the search matched file content.",
+ "apihelp-query+search-paramvalue-prop-score": "<span
class=\"apihelp-deprecated\">Deprecated and ignored.</span>",
+ "apihelp-query+search-paramvalue-prop-hasrelated": "<span
class=\"apihelp-deprecated\">Deprecated and ignored.</span>",
"apihelp-query+search-param-limit": "How many total pages to return.",
"apihelp-query+search-param-interwiki": "Include interwiki results in
the search, if available.",
"apihelp-query+search-param-backend": "Which search backend to use, if
not the default.",
diff --git a/includes/api/i18n/qqq.json b/includes/api/i18n/qqq.json
index 95562d8..63d6564 100644
--- a/includes/api/i18n/qqq.json
+++ b/includes/api/i18n/qqq.json
@@ -845,7 +845,20 @@
"apihelp-query+search-param-namespace":
"{{doc-apihelp-param|query+search|namespace}}",
"apihelp-query+search-param-what":
"{{doc-apihelp-param|query+search|what}}",
"apihelp-query+search-param-info":
"{{doc-apihelp-param|query+search|info}}",
- "apihelp-query+search-param-prop":
"{{doc-apihelp-param|query+search|prop}}",
+ "apihelp-query+search-param-prop":
"{{doc-apihelp-param|query+search|prop|paramvalues=1}}",
+ "apihelp-query+search-paramvalue-prop-size":
"{{doc-apihelp-paramvalue|query+search|prop|size}}",
+ "apihelp-query+search-paramvalue-prop-wordcount":
"{{doc-apihelp-paramvalue|query+search|prop|wordcount}}",
+ "apihelp-query+search-paramvalue-prop-timestamp":
"{{doc-apihelp-paramvalue|query+search|prop|timestamp}}",
+ "apihelp-query+search-paramvalue-prop-snippet":
"{{doc-apihelp-paramvalue|query+search|prop|snippet}}",
+ "apihelp-query+search-paramvalue-prop-titlesnippet":
"{{doc-apihelp-paramvalue|query+search|prop|titlesnippet}}",
+ "apihelp-query+search-paramvalue-prop-redirectsnippet":
"{{doc-apihelp-paramvalue|query+search|prop|redirectsnippet}}",
+ "apihelp-query+search-paramvalue-prop-redirecttitle":
"{{doc-apihelp-paramvalue|query+search|prop|redirecttitle}}",
+ "apihelp-query+search-paramvalue-prop-sectionsnippet":
"{{doc-apihelp-paramvalue|query+search|prop|sectionsnippet}}",
+ "apihelp-query+search-paramvalue-prop-sectiontitle":
"{{doc-apihelp-paramvalue|query+search|prop|sectiontitle}}",
+ "apihelp-query+search-paramvalue-prop-categorysnippet":
"{{doc-apihelp-paramvalue|query+search|prop|categorysnippet}}",
+ "apihelp-query+search-paramvalue-prop-isfilematch":
"{{doc-apihelp-paramvalue|query+search|prop|isfilematch}}",
+ "apihelp-query+search-paramvalue-prop-score":
"{{doc-apihelp-paramvalue|query+search|prop|score}}",
+ "apihelp-query+search-paramvalue-prop-hasrelated":
"{{doc-apihelp-paramvalue|query+search|prop|hasrelated}}",
"apihelp-query+search-param-limit":
"{{doc-apihelp-param|query+search|limit}}",
"apihelp-query+search-param-interwiki":
"{{doc-apihelp-param|query+search|interwiki}}",
"apihelp-query+search-param-backend":
"{{doc-apihelp-param|query+search|backend}}",
--
To view, visit https://gerrit.wikimedia.org/r/229654
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Id2088213f4577c8cb88e479e8fca0e6bd3d619f4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Umherirrender <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits