Maven Doxia

APT local anchor / link doesn't work when there is a whitespace in the anchor name

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.0-alpha-11
  • Fix Version/s: 1.1
  • Component/s: Module - Apt
  • Labels:
    None
  • Environment:
    Maven version: 2.0.9
    Java version: 1.5.0_11
    OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"
  • Number of attachments :
    0

Description

An local anchor and link defined in APT doesn't work if it contains white spaces.
The problem come in HTML generated from the APT using a Maven "site:site" goal.

Example APT:
-----------------------------------------------------------

  • {Element group}

    An element group is a set of {{{Element}elements}}

    * {Element}

    An element is a component of an Element group

    -----------------------------------------------------------
    in this example, the {Element} anchor will work, while the {Element group} will not.
    The documentation of APT says "The name of an anchor/link is its text with all non alphanumeric characters stripped."
    It's not the case in the generated HTML, the whitespace is there in the HTML causing the problem.

There are cases (as shown in the example) where it's difficult to find another name for the anchor.
Mainly because (unlike the link) you cannot specify an anchor name different from the anchor displayed text.

Issue Links

Activity

Hide
Lukas Theussl added a comment -

This should be fixed in beta-1 trunk, I have added a testcase in the site renderer [1]. Note that the docs on the published site do not apply to what is in trunk anymore, see [2] for some changes of the apt format in doxia.

[1] http://svn.apache.org/viewvc?view=rev&revision=700732
[2] http://svn.apache.org/viewvc/maven/doxia/site/src/site/apt/references/doxia-apt.apt?view=markup

Show
Lukas Theussl added a comment - This should be fixed in beta-1 trunk, I have added a testcase in the site renderer [1]. Note that the docs on the published site do not apply to what is in trunk anymore, see [2] for some changes of the apt format in doxia. [1] http://svn.apache.org/viewvc?view=rev&revision=700732 [2] http://svn.apache.org/viewvc/maven/doxia/site/src/site/apt/references/doxia-apt.apt?view=markup

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: