Adam Turner
866881583a
Shorten the `suppress_warnings` changes list
2025-01-30 01:38:35 +00:00
Tiger3018
af3bb3687c
Use warning types and sub-types in more places ( #11677 )
...
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
2025-01-29 19:22:44 +00:00
Chris Sewell
134bd7f1fb
Add `collapsible` option to admonition directives ( #12507 )
...
This PR adds the `collapsible` and option to the core admonition type directives, which are propagated to the nodes, e.g.
```restructuredtext
.. admonition:: title
:collapsible:
content
.. note:: content
:collapsible: closed
```
For the HTML5 writer, this replaces the outer `div` with a `details` tag, and the title `p` with a `summary` tag (with an `open` attribute if set), e.g.
```html
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>hallo</p>
</div>
```
changes to
```html
<details class="admonition note" open="open">
<summary class="admonition-title">Note</summary>
<p>hallo</p>
</details>
```
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
2025-01-29 18:06:57 +01:00
Adam Turner
5667050dd2
Improve the displayed signature for abstract methods ( #13271 )
2025-01-29 02:34:46 +00:00
Tim Hoffmann
5871ce266a
Add support for short signatures in autosummary ( #13172 )
...
This introduces a new ``:signatures:`` option to ``sphinx.ext.autosummary``.
Possible values are:
"long" (*default*):
same as the current default
"short":
format functions and classes as ``func()`` if they do not
have arguments and ``func(…)`` if they do have arguments.
"none":
replaces the pre-existing ``:nosignatures:`` (which becomes deprecated)
The new functionality here is the "short" option.
This allows to distinguish properties and attributes
from functions and classes without costing a lot of space
for a long signature.
2025-01-29 00:44:09 +00:00
Victor Wheeler
3bc10dd90f
Note that `:term:` supports custom link text ( #13120 )
2025-01-29 00:07:08 +00:00
Jonny Saunders
18bb8bcef5
Implement :no-index-entry: for autodoc ( #12233 )
...
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
2025-01-28 02:01:31 +00:00
Adam Turner
7801540c08
Support `:no-index-entry: in .. {js,py}:module::` ( #13272 )
2025-01-28 01:33:28 +00:00
Simão Afonso @ Powertools Tech
60f88cc16e
Add `ref.any` as a warning sub-type ( #12739 )
...
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
2025-01-27 19:33:22 +00:00
Adam Turner
bde37bec27
Add the `autodoc_use_type_comments` option ( #13269 )
2025-01-26 05:47:28 +00:00
Adam Turner
44891a4eef
Update the 'Python Signatures' section
2025-01-26 04:54:34 +00:00
Adam Turner
4d4123bbce
Reference 'Python' instead of 'Python 3'
2025-01-26 04:52:46 +00:00
Adam Turner
9a8eeac865
Use granular syntax highlighting for the Napoleon extension
2025-01-26 04:45:49 +00:00
Adam Turner
a1c77f1725
Improve wording for the `:type:`directive option warning ( #13256 )
2025-01-23 14:11:57 +00:00
Adam Turner
42f300ee83
Rename the `:nowrap and :nosignatures:` directive options ( #13264 )
...
Rename the ``:nowrap`` and ``:nosignatures:`` directive options to
``:no-wrap`` and ``:no-signatures:``, for readability.
This mirrors changes already made to `:no-index`, `:no-index-entry`,
`:no-contents-entry`, and `:no-search` in Sphinx 7.2 and 7.3.
2025-01-23 04:30:46 +00:00
Adam Turner
1b607502d5
Remove top-level modules from the no-any-generics whitelist
2025-01-22 02:24:55 +00:00
Thomas Louf
1418339eb9
Allow configuration of trailing commas in multi-line signatures ( #12975 )
...
Stop outputting trailing commas for C and C++, as it is invalid syntax.
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com >
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
Co-authored-by: Jakob Lykke Andersen <jakobandersen@users.noreply.github.com >
2025-01-21 20:08:18 +00:00
Adam Turner
e18155fa10
Note when `.. confval::` was added
2025-01-21 08:08:29 +00:00
Adam Turner
5b3f98ed80
Sort the `suppress_warnings` list and add missing entries
2025-01-21 08:06:19 +00:00
Bénédikt Tran
5b9fb9e060
autodoc: fix ordering of class and static methods for groupwise order ( #13201 )
...
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com >
2025-01-20 15:19:05 +00:00
CyrilRoelandteNovance
34037aa4ad
Allow users to suppress `autodoc.mocked_object` warnings ( #9732 )
...
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
2025-01-19 23:12:40 +00:00
Slawomir Figiel
67f6154be3
Allow suppressing warnings for non-matching `toctree` glob patterns ( #13230 )
...
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
2025-01-16 18:17:21 +00:00
Adam Turner
182c831c7d
Disambiguate `:type:` as a directive option or info-field-list item ( #13242 )
2025-01-15 00:20:42 +00:00
Adam Turner
d102e62bc7
Format code blocks in docstrings
2025-01-14 12:17:46 +00:00
Adam Turner
72ce43619c
Remove unneeded runtime typing imports ( #13233 )
2025-01-12 01:04:14 +00:00
Adam Turner
fdb1b0cdad
Update documentation for the `:no-search:` file-wide metadata option
2025-01-10 16:56:21 +00:00
Adam Turner
d42cfa702f
Further minor copyediting of the 'extension metadata' section
2025-01-10 01:26:17 +00:00
Adam Turner
daade2715a
Rewrite the 'extension metadata' section
2025-01-10 01:09:49 +00:00
Adam Turner
44aced1ab7
Add types and defaults to confval directives ( #13218 )
2025-01-07 03:55:27 +00:00
Adam Turner
a69d79bf67
Add .gitattributes
2025-01-06 21:55:29 +00:00
Firefly
717dcc531a
Napoleon: Define confval types and defaults ( #13094 )
...
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com >
2025-01-05 11:05:12 +00:00
Adam Turner
83bf866059
Avoid attribute indirection with `env` ( #13212 )
2025-01-05 09:10:55 +00:00
James Addison
872d270f10
linkcheck: support ignored-URIs for redirects ( #13127 )
...
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
2025-01-05 01:20:15 +00:00
Tim Hoffmann
432bc5e50b
Add a class option to the autosummary directive ( #13144 )
...
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com >
2025-01-04 00:28:59 +00:00
Adam Turner
e65bbb96ae
Create a new type for the current document's environment state ( #13151 )
2025-01-04 00:28:03 +00:00
Nicolas Peugnet
0fbf88a59f
Allow extensions to define the keys returned by linkcode ( #11824 )
...
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
2025-01-03 21:28:34 +00:00
Julien Lecomte
fddbd7d151
Add new `duplicate_declaration.{c,cpp}` warning types ( #13173 )
...
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com >
2025-01-03 02:48:07 +00:00
Adam Turner
ff2693242d
Run Ruff on `doc/usage/extensions/`
2025-01-02 23:59:48 +00:00
Adam Turner
b5f9ac8afc
Enable the RUF100 lint in Ruff
2025-01-02 23:49:43 +00:00
Jean-François B.
df3d94ffda
Close #13130 (LaTeX docs about index creation) ( #13139 )
2024-12-02 11:12:22 +01:00
Rubén de Celis Hernández
6a8d70a2fd
Fix incorrect reference to `--config-dir` in the documentation ( #13148 )
...
The correct argument name is ``--conf-dir``.
2024-11-22 17:03:18 +00:00
Adam Turner
58b2a94770
Set 'persist-credentials' to false
2024-11-16 18:30:17 +00:00
James Addison
c93723b803
singlehtml: deprecate the 'fix_refuris' helper function ( #13037 )
...
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com >
2024-11-13 23:15:00 +00:00
Tim Hoffmann
20b53bcc1a
Add a graph illustrating the build phases to the docs ( #13108 )
2024-11-13 22:22:47 +00:00
Tim Hoffmann
a2db696777
Format options for doctest directives ( #13107 )
...
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com >
2024-11-13 22:20:56 +00:00
Santos Gallegos
2320c46b9e
Document `Sphinx.set_html_assets_policy` ( #13123 )
2024-11-13 22:10:03 +00:00
Tim Hoffmann
8117bcaae8
Format autosummary options in docs ( #13106 )
...
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com >
2024-11-07 16:25:40 +00:00
Adam Turner
1266c421be
Use pathlib in `sys.path` manipulation examples
2024-11-03 22:58:19 +00:00
Adam Turner
801c60a873
Consistently calculate the current file's directory
2024-11-03 17:28:02 +00:00
Adam Turner
a6559d496b
Use pathlib in examples
2024-11-03 17:26:39 +00:00