sphinx-design icon indicating copy to clipboard operation
sphinx-design copied to clipboard

tab-item with replacement directive

Open zerothi opened this issue 10 months ago • 2 comments

Describe the bug

context I have an rst replacement text:

.. |pip| replace:: pip

I then have a tab with this:

.. tab-set::
    .. tab-item:: |pip|
<more tabs etc.>

expectation I expected |pip| to be replaced correctly (note this works with other tab systems, inline-tabs e.g.

bug

It now shows the tab name as:

<substitution_reference refname=”pip”>pip</substitution_reference>

problem This is a problem for people because it might be necessary to globally control some of the tab names. Say OS's, terminals etc.

Reproduce the bug

Context above should give enough instructions. Rather simple IMHO. If you need more details, please let me know!

List your environment

No response

zerothi avatar Aug 18 '23 14:08 zerothi

Thanks for opening your first issue here! Engagement like this is essential for open source projects! :hugs:
If you haven't done so already, check out EBP's Code of Conduct. Also, please try to follow the issue template as it helps other community members to contribute more effectively.
If your issue is a feature request, others may react to it, to raise its prominence (see Feature Voting).
Welcome to the EBP community! :tada:

welcome[bot] avatar Aug 18 '23 14:08 welcome[bot]

I faced a similar problem when trying to place roles in tab-item. I have a pull request (https://github.com/executablebooks/sphinx-design/pull/135) which is currently under review. If the extension is installed as an editable package in python, then I would suggest you just change the code yourself. It is simply two lines of code.

Praecordi avatar Sep 04 '23 10:09 Praecordi