Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sphinx: In-line cross referencing target should not need explicit title #9993

Closed
psunthar opened this issue Dec 19, 2021 · 3 comments
Closed
Labels
domains:std markup type:enhancement enhance or introduce a new feature
Milestone

Comments

@psunthar
Copy link

Is your feature request related to a problem? Please describe.
Yes, in-line targets such as _`this one` cannot be easily referred using role based :ref: cross-referencing, which is needed across RST files of the same document. It needs an explicit title. For example, :ref:`this one` does not insert the target text as the title. It needs an explicit tltle like this :ref:`That one<this one>`. Without explicit link, there is a warning

WARNING: Failed to create a cross reference. A title or caption not found: this one

Describe the solution you'd like
:ref:`this one` must insert the text this one and also link it to the target. This will avoid duplicate typing of the same text, when avoidable.

Describe alternatives you've considered
Duplicating the target text as the title. :ref:`this one<this one>`

@psunthar psunthar added the type:enhancement enhance or introduce a new feature label Dec 19, 2021
@tk0miya tk0miya added this to the 4.4.0 milestone Dec 20, 2021
@tk0miya
Copy link
Member

tk0miya commented Dec 20, 2021

+1: Good idea. Reasonable!

tk0miya added a commit that referenced this issue Dec 22, 2021
Close #9993: std domain: Allow to refer an inline target via ref role
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 22, 2022
@tk0miya
Copy link
Member

tk0miya commented Mar 27, 2022

Unfortunately, this change brings an incompatible change to Sphinx. So I determined to revert this feature during 4.x.
Sorry for the inconvinience.

@tk0miya tk0miya reopened this Mar 27, 2022
@tk0miya tk0miya modified the milestones: 4.4.0, 5.0.0 Mar 27, 2022
@tk0miya
Copy link
Member

tk0miya commented Mar 27, 2022

refs: #10177

tk0miya added a commit that referenced this issue Mar 27, 2022
Revert "Close #9993: std domain: Allow to refer an inline target via ref role"
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
domains:std markup type:enhancement enhance or introduce a new feature
Projects
None yet
Development

No branches or pull requests

2 participants