typst/biblatex

Support for access time in bibliography

Opened this issue · 3 comments

Description

I want to show what time I accessed a resource.

As hayagriva does not support the use of a time, I have switched to the BibTeX format.
Using this entry compiles without errors:

@online{online-source,
    author    = "Donald Knuth",
    title     = "Knuth: Computers and Typesetting",
    url       = "http://www-cs-faculty.stanford.edu/~uno/abcde.html",
    urldate   = {2024-05-09T14:30:00},
}

But the bibliography only renders the date:
Bildschirmfoto vom 2024-05-09 17-58-20

I have used the IEEE style and tried several others and none of them rendered the time, so I suspect it is not a matter of the style used.

I have already added an issue in the hayagriva repo to add support for the access time: typst/hayagriva#160

Use Case

To be able to use a more detailed access timestamp for online ressources

This should probably be transferred to https://github.com/typst/biblatex

If I understand well:

  1. The field urldate is parsed for year, month and day; no information about the time is parsed
  2. Parsing a Datetime is already implemented in date.rs
  3. In biblatex, options dateusetime and seconds must be set to true in order to print the full timestamp.

[1] https://github.com/typst/biblatex/blob/main/src/macros.rs#L58
[2]

pub struct Datetime {

Is there a workaround to enable those options in a typst project or does it have to be hard-coded?

@wnhrt Only the date fields are parsed in the biblatex crate, hence there are no options to enable this.
If you have the time, don't hesitate to draft a PR implementing this!