Python3 docs have this great button that is on the top right corner of doctest blocks. (Example https://docs.python.org/3/library/inspect.html#inspect.signature)
This new button would trigger Javascript that show/hide the element with CSS classes py-prompt , py-more and py-output.
In the the theme, we currently, do not colorize the .. code:: directive and other code like blocks, so that could be changed as well.