sphinx-autodoc-typehints icon indicating copy to clipboard operation
sphinx-autodoc-typehints copied to clipboard

`typehints_defaults = "braces-after"` doesn't work correctly with multiline docstrings

Open KareemMAX opened this issue 2 years ago • 1 comments

Currently we have this docstring

        Parameters
        ----------
        self
            input array.
        approximate
            whether to use the approximate version of the gelu function.
        complex_mode
            optional specifier for how to handle complex data types. See
            ``ivy.func_wrapper.handle_complex_input`` for more detail.
        out
            optional output array, for writing the result to. It must have a shape
            that the inputs broadcast to.

When we use typehints_defaults = "braces-after" it renders incorrectly for complex_mode: image

The (default: 'jax') should be places at the end of line 2 (after "more details."), while it's currently places after line 1 (See).

KareemMAX avatar Sep 04 '23 17:09 KareemMAX

PR welcome 👍

gaborbernat avatar Sep 06 '23 15:09 gaborbernat