Open jpmckinney opened 1 year ago
The code uses backticks, which substitutes resultCount. The new string is then passed to gettext() (_()).
resultCount
gettext()
_()
https://github.com/sphinx-doc/sphinx/blob/b1ca6b3e120d83c9bb64fdea310574afb9897c1a/sphinx/themes/basic/static/searchtools.js#L111-L113
However, the new string doesn't match any translatable string:
https://github.com/sphinx-doc/sphinx/blob/b1ca6b3e120d83c9bb64fdea310574afb9897c1a/sphinx/locale/es/LC_MESSAGES/sphinx.js#L40
Platform: darwin; (macOS-13.0.1-arm64-arm-64bit) Python version: 3.8.12 (default, Dec 8 2021, 19:03:58) [Clang 13.0.0 (clang-1300.0.29.3)]) Python implementation: CPython Sphinx version: 5.3.0 Docutils version: 0.18 Jinja2 version: 3.1.2
No response
Hello there, I created a fix which works for me: https://github.com/hajs/sphinx/commit/8e6a9cb7ddbfbb24c5057946d15248648dd4f3d5
Should I submit a pull request?
Please!
A
Describe the bug
The code uses backticks, which substitutes
resultCount
. The new string is then passed togettext()
(_()
).https://github.com/sphinx-doc/sphinx/blob/b1ca6b3e120d83c9bb64fdea310574afb9897c1a/sphinx/themes/basic/static/searchtools.js#L111-L113
However, the new string doesn't match any translatable string:
https://github.com/sphinx-doc/sphinx/blob/b1ca6b3e120d83c9bb64fdea310574afb9897c1a/sphinx/locale/es/LC_MESSAGES/sphinx.js#L40
How to Reproduce
Environment Information
Sphinx extensions
No response
Additional context
No response