xslTNG icon indicating copy to clipboard operation
xslTNG copied to clipboard

Issue 487 add support for titleabbrev in bibliography entries.

Open fsteimke opened this issue 11 months ago • 1 comments

fsteimke avatar Mar 16 '24 08:03 fsteimke

Can you add a test that demonstrates this change? Abbreviated titles aren't generally presented inline; they're used for things like the table of contents. I'm not sure what you have in mind here.

ndw avatar Sep 21 '24 15:09 ndw

I was thinking of German legal texts. They usually have a very long title and an official abbreviation. An example would be:

  • title: "Gesetz zur Einführung und Verwendung einer Identifikationsnummer in der öffentlichen Verwaltung"
  • titleabbrev: "Identifikationsnummerngesetz" or even "IdNrG"

Since both the full title and the abbreviation are part of the official name, you would expect a reference to this law as: "Gesetz zur Einführung und Verwendung einer Identifikationsnummer in der öffentlichen Verwaltung (Identifikationsnummerngesetz)" or "Gesetz zur Einführung und Verwendung einer Identifikationsnummer in der öffentlichen Verwaltung (IdNrG)".

I admit that this seems to be a very specific use case. On the other hand, it is about the use of titleabbrev within the bibliography only. I don't see the risk of unwanted effects with normal use of titleabbrev for ToC.

I will add test cases (biblioentry and bibliomixed).

fsteimke avatar Oct 11 '24 07:10 fsteimke

Yes, I see your point.

ndw avatar Oct 11 '24 07:10 ndw

The PR should support titleabbrev in biblioentry as well as in bibliomixed.

It was difficult to add parenthesis around abbreviated title in the same font-style as the abbreviated title itself. The best way i found was to hard-code them in CSS. Maybe you find a better way?

I had to change the expected HTML for bibliography.001 and bibliography.002, but i think in a very natural way.

fsteimke avatar Oct 12 '24 17:10 fsteimke