TEIC / Stylesheets

TEI XSL Stylesheets
231 stars 124 forks source link

links from examples to BIB failing #520

Closed sydb closed 3 years ago

sydb commented 3 years ago

I have not yet investigated what is going on, but at first blush we have a serious problem: @source links from <egXML>s in the GLs to the bibliography are not working. First glance says it is because the ID of each <bibl> is not getting through to the BIB.html file. (Thus I am suspicious of @HelenaSabel’s recent ID fix which, IIRC, I approved just yesterday.)

Mildly more detailed:

sydb commented 3 years ago

Note: working on this locally in restored branch iss516, as I am all but convinced that the corresponding PR is the source of the problem. (File html/html_core.xsl circa line 845, to be precise.)

sydb commented 3 years ago

The problem is different templates are getting fired. For a “regular” TEI file (like the test32.xml @HelenaSabel was working with), the template that handles the <bibl>s of interest is in common/common_core.xsl (circa line 1068). For the Guidelines themselves the template that handles the <bibl>s of interest is in odds/guidelines.xsl (circa line 696).

sydb commented 3 years ago

Have a fix: the problematic template that is being fired for the BIB (odds/guidelines.xsl circa line 696) was using <apply-templates/>. Changing that to <apply-templates select="@xml:id | node()"/> seems to fix the problem. No idea what else it might break. Running tests now.

sydb commented 3 years ago

OK. All tests (Stylesheets/Test/, Stylesheets/Test2/, and TEI/Test/) seem to pass on my local system. Going to check this fix in and see what @HelenaSabel thinks. Fix checked into branch at 4896fb33.

peterstadler commented 3 years ago

Sorry, I fail to see the faulty behaviour in the current dev branch. E.g. the example at https://jenkins.tei-c.org/view/TEI%20dev/job/TEIP5-dev/lastSuccessfulBuild/artifact/P5/release/doc/tei-p5-doc/en/html/ref-div4.html has a proper link to the bibliography. What am I missing?

sydb commented 3 years ago

IIRC the faulty behavior was not in the dev branch, but in the iss516 branch, and has been fixed there.