Skip to content

Commit 729fcc1

Browse files
tomasr8hugovk
andauthored
Add missing i18n for copy button titles (#225)
Co-authored-by: Hugo van Kemenade <[email protected]>
1 parent f5d080f commit 729fcc1

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

.babel.cfg

+2
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1+
[javascript: **.js]
2+
13
[jinja2: **.html]

python_docs_theme/static/copybutton.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ const loadCopyButton = () => {
3333
/* Add a [>>>] button in the top-right corner of code samples to hide
3434
* the >>> and ... prompts and the output and thus make the code
3535
* copyable. */
36-
const hide_text = "Hide the prompts and output"
37-
const show_text = "Show the prompts and output"
36+
const hide_text = _("Hide the prompts and output")
37+
const show_text = _("Show the prompts and output")
3838

3939
const button = document.createElement("span")
4040
button.classList.add("copybutton")

0 commit comments

Comments
 (0)