metanorma / metanorma-iso

Metanorma processor for ISO standards
BSD 2-Clause "Simplified" License
14 stars 5 forks source link

(URGENT) ModSpec rendering with `xref:...` broken, regardless of whether`[style=id%]` or `[]` #846

Closed ronaldtse closed 1 year ago

ronaldtse commented 1 year ago

With style=id

Source:

. If `//characterEncoding` is provided

** Requirement: xref:https://standards.isotc211.org/19115/-1/1/req/metadata-xml/multilingual/character-set-code[style=id%]

** Conformance test: xref:https://standards.isotc211.org/19115/-1/1/conf/metadata-xml/multilingual/character-set-code[style=id%]

There are 2 problems:

  1. The resulting cross-reference is not linked properly
  2. The rendering of the ID is broken

Word:

Screen Shot 2022-11-09 at 9 33 16 AM

In Word, these are links, but they don't link to anywhere:

Screen Shot 2022-11-09 at 9 34 36 AM

HTML:

Screen Shot 2022-11-09 at 9 35 21 AM

These are links but the HREF is clearly wrong.

PDF:

Screen Shot 2022-11-09 at 9 31 22 AM

In PDF, these links are not even links (i.e. they cannot be clicked on).

Without style=id

Source:

. If `//characterEncoding` is provided

** Requirement: xref:https://standards.isotc211.org/19115/-1/1/req/metadata-xml/multilingual/character-set-code[]

** Conformance test: xref:https://standards.isotc211.org/19115/-1/1/conf/metadata-xml/multilingual/character-set-code[]

PDF:

Screen Shot 2022-11-09 at 9 44 44 AM

HTML:

Screen Shot 2022-11-09 at 9 45 04 AM

Proof that the identifiers exist

In case you wanted to verify that the ModSpec instance with that identifier exists, here they are rendered:

Requirement:

Screen Shot 2022-11-09 at 9 38 47 AM

Conformance test:

Screen Shot 2022-11-09 at 9 44 08 AM

Reference

See https://github.com/metanorma/iso-19115-3/pull/23

ronaldtse commented 1 year ago

Just tried this with the Git gems, still doesn't work:

gem "metanorma-cli"
gem "metanorma-standoc", git: "https://github.com/metanorma/metanorma-standoc"
#gem "mn-requirements", git: "https://github.com/metanorma/mn-requirements"
gem "isodoc", git: "https://github.com/metanorma/isodoc"
gem "metanorma-iso", git: "https://github.com/metanorma/metanorma-iso"
gem "sassc"
opoudjis commented 1 year ago

My local compilation works, will revisit when release is done.

opoudjis commented 1 year ago

@ronaldtse Please confirm it works now.

ronaldtse commented 1 year ago

Confirmed works, closing.