|
4 | 4 |
|
5 | 5 | Author: Akshay Mestry <[email protected]>
|
6 | 6 | Created on: Saturday, February 22 2025
|
7 |
| -Last updated on: Saturday, March 01 2025 |
| 7 | +Last updated on: Wednesday, March 05 2025 |
8 | 8 |
|
9 | 9 | This file contains the configuration settings for building SMART,
|
10 | 10 | Study, Mentorship, And Resourceful Teaching website using Sphinx, a
|
|
25 | 25 | button doesn't seem to work. Hence, relying on external sphinx
|
26 | 26 | extension. This support is added through the `sphinx_copybutton`
|
27 | 27 | extension.
|
| 28 | +
|
| 29 | +.. versionchanged:: 5.3.2025 |
| 30 | +
|
| 31 | + [1] Customized the CSS of the copy button extension and fixed a bug |
| 32 | + caused by default copy button element. |
28 | 33 | """
|
29 | 34 |
|
30 | 35 | from __future__ import annotations
|
|
108 | 113 | ogp_type: t.Final[str] = "website"
|
109 | 114 | ogp_enable_meta_description: bool = True
|
110 | 115 |
|
111 |
| -docsearch_app_id = os.getenv("DOCSEARCH_APP_ID", "") |
112 |
| -docsearch_api_key = os.getenv("DOCSEARCH_API_KEY", "") |
113 |
| -docsearch_index_name = os.getenv("DOCSEARCH_INDEX_NAME", "") |
114 |
| -docsearch_container = "#smart-search" |
115 |
| -docsearch_placeholder = "SMART Search" |
116 |
| -docsearch_missing_results_url = source + "/issues/new?title=${query}" |
| 116 | +docsearch_app_id: str = os.getenv("DOCSEARCH_APP_ID", "") |
| 117 | +docsearch_api_key: str = os.getenv("DOCSEARCH_API_KEY", "") |
| 118 | +docsearch_index_name: str = os.getenv("DOCSEARCH_INDEX_NAME", "") |
| 119 | +docsearch_container: t.Final[str] = "#smart-search" |
| 120 | +docsearch_placeholder: t.Final[str] = "SMART Search" |
| 121 | +docsearch_missing_results_url: str = source + "/issues/new?title=${query}" |
| 122 | + |
| 123 | +copybutton_exclude: str = ".linenos, .gp, .go" |
| 124 | +copybutton_line_continuation_character: str = "\\" |
| 125 | +copybutton_selector: str = "div:not(.no-copybutton) > div.highlight > pre" |
| 126 | +copybutton_image_svg: str = """\ |
| 127 | +<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" |
| 128 | +stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" |
| 129 | +width="24" height="24" stroke-width="2"> |
| 130 | + <path d="M9 5h-2a2 2 0 0 0 -2 2v12a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-12a2 2 0 |
| 131 | + 0 0 -2 -2h-2"></path> |
| 132 | + <path d="M9 3m0 2a2 2 0 0 1 2 -2h2a2 2 0 0 1 2 2v0a2 2 0 0 1 -2 2h-2a2 2 0 0 |
| 133 | + 1 -2 -2z"></path> |
| 134 | + <path d="M9 12l.01 0"></path> |
| 135 | + <path d="M13 12l2 0"></path> |
| 136 | + <path d="M9 16l.01 0"></path> |
| 137 | + <path d="M13 16l2 0"></path> |
| 138 | +</svg> |
| 139 | +""" |
0 commit comments