Template talk:Graphical timeline

New graphical timeline
Hi all, I know I've really stuffed it up but I was hoping someone might be able to help me, I have created Template:Timeline Queensland Premiers which is based on Timeline Australian PM. While I can put in the grunt work of inserting the data I have obviously not got the technical knowledge to know why it has not worked. I have tried not to change any of the script other than the info. Any help would be hugely appreciated. Thanks, WikiTownsvillian 12:49, 9 July 2007 (UTC)


 * Looks pretty good to me, to be honest. However, you're not using this template (Graphical timeline), but easyTimeline — that would be a more appropriate place to seek help! I'd have a look myself but am sick of trying to interpret the easyTimeline syntax. Hope you get somewhere - if not, do see how you get on with this template (if you can bear entering the data again!) Verisimilus  T  19:32, 11 July 2007 (UTC)

Lower numbered years at the top?
Can anyone tell me how to make this work with the lower numbered years at the top? See Talk:John Vanbrugh. -- Ferma (talk) 19:23, 16 February 2012 (UTC)

Box cuts off text at the bottom
I have a problem with Permian of Central Europe graphical timeline. The text at the bottom gets cut off by the box. I don't think the documentation explains how to fix this. --Tobias1984 (talk) 09:39, 1 December 2012 (UTC)

How to add more bars
I made two attempts to add bars today without success. Subst isn't working. Any ideas? P.S. I'm using 95 bars on User:Fama Clamosa/Sandbox. --Fama Clamosa (talk) 14:04, 5 January 2014 (UTC)

Correct typography?
Is there any possibility to use correct minus signs (−) instead of hyphens (-) for negative numbers? — Mikhail Ryazanov (talk) 13:00, 4 April 2016 (UTC)


 * Support: I second Mr. Ryazanov's suggestion. —DocWatson42 (talk) 05:56, 5 April 2018 (UTC)


 * Most recent editors: Might one of you make the suggested correction? —DocWatson42 (talk) 01:30, 31 July 2019 (UTC)

This template's typesetting is terrible
This template grossly and conspicuously violates WP:MOSMATH.
 * These are minus signs:
 * 5 − 3
 * −42
 * These are not minus signs, but hyphens:
 * 5 - 3
 * -42

This template uses hyphens where there should be minus signs. If it's used in an article everyone will think the article was written by someone who can't spell. Michael Hardy (talk) 21:40, 14 May 2016 (UTC)


 * It seems the main problem is that this template creates labels using, which produces output in "plain-text" ASCII (perhaps to be reusable as numbers in other templates), hence the disgusting look in Unicode environment with proportional fonts. I suspect that wrapping the output in  should solve the problem, but the current code is too huge and too brainfuck-like to be understood... :–( So the only hope is to summon somebody who participated in its creation (this apparently was ≥5 years ago) and maybe still remembers how it works. Or to rewrite everything in Lua in a more readable and maintainable form. — Mikhail Ryazanov (talk) 03:37, 18 May 2016 (UTC)

Dead wikilinks in graphical timelines discussed at WP:Village pump (technical)
Archived discussion at VPT: Dead wikilinks in graphical timeline templates (in Chrome, Opera and Safari).

The cause of the problem is that arguments to Template:Graphical timeline are put within &lt;span&gt; elements in the template, while templates that call this template, such as for example Template:Life timeline, put &lt;div&gt; elements (now removed from the Life timeline template) in those arguments, leading to invalid nesting. (The effect of this was hidden by HTML Tidy until we switched to RemexHTML on 5 July 2018.)

The problem is resolved by removing  s from arguments to Template:Graphical timeline. --Pipetricker (talk) 09:46, 9 December 2018 (UTC)

Template:Chronological Chart for the historical periods of Afghanistan
This has never worked properly, since it was set up (and used in at least one article) in 2011. At least for me, the dates display in an otherwise empty top section. I know nothing about templates, but I suspect the mistake is quite simple. Can anyone help? Johnbod (talk) 00:00, 28 October 2019 (UTC)


 * . The specified width was far too large, so the boxes wrapped. — hike395 (talk) 09:12, 3 May 2021 (UTC)

Minus signs... again
There were two threads about this back in '16, but just chiming in 4 years later to say it's still a bother that the template uses hyphens instead of proper unicode minus signs. I ignorantly tried updating a downstream template and came here after realizing it wasn't changing. Opencooper (talk) 05:08, 6 April 2020 (UTC)
 * Seconded again. —DocWatson42 (talk) 04:00, 10 April 2020 (UTC)
 * A relatively simple change now that the template is in Lua. — hike395 (talk) 09:53, 3 May 2021 (UTC)

Proposal for a new feature for this template
I propose there be a graphical timeline feature that allows you to collapse a timeline if you want it hidden. I'm already working on it right now. This could allow long, unwieldy timelines to be collapsed into a more manageable size. Benniboi01 (talk) 18:58, 20 May 2020 (UTC)


 * ✅ collapsible and state have been added to the Lua module. — hike395 (talk) 05:34, 11 May 2021 (UTC)

Margins in module implementation
User:Hike395, there seems to be a bug (?) with how margins are implemented, at least how Template:Human timeline interacts with them. I noticed this at the article Cerutti Mastodon site (the text gets too close to the box, should be more like an infobox margin). — Goszei (talk) 20:09, 5 May 2021 (UTC)
 * Good catch! I implemented the margins backwards. Now fixed in the live template. — hike395 (talk) 04:21, 6 May 2021 (UTC)

Various abnormalities and issues
I've noticed some abnormalities with Template:Triassic graphical timeline. Several of the links are not clickable when they are intended to be (for example, Jurassic and Mesozoic). Also if you look at the Triassic article, and other articles where the timeline is transcluded, the "arrow pointers" on the right side are mostly missing, and cause an overlap problem at the bottom of the template.

I am not sure how recent these problems are/how connected they are to the new module, but posting them here anyway. — Goszei (talk) 05:59, 8 May 2021 (UTC)


 * I found that these issues are affecting a majority of the geologic timelines, after looking into this further. — Goszei (talk) 06:14, 8 May 2021 (UTC)

Unrelated question: was this template always visible on mobile? I seem to remember it not being so, but I am not active in this area, and maybe my memory is wrong. — Goszei (talk) 06:04, 8 May 2021 (UTC)

On Template:Triassic graphical timeline, the #Container element has a computed width of 305px, while this edit only allows 300px. Changing it to 305px fixes the overflow issue on Triassic, but the last annotation is still not clickable and this seems like a hack. I haven't looked more carefully. —&#8239; The Earwig (talk) 06:08, 8 May 2021 (UTC)


 * I fixed the issue of the arrows wrapping. The original template used divs to hold the content, and assumed that the layout would work like text. This went horribly wrong when you squeezed the template horizontally. I've fixed the arrow wrapping issue by doing the layout as a single table. There is still a remaining issue of a vertical line squirting out, so I can't yet remove the 300px/305px hack. Will look into this later today.
 * When used in an infobox, the positioning of the annotations was messed up. Now fixed.
 * Template visibility on mobile: Graphical timeline/regression is a comparison between the new module and the old template. When I look at it in mobile mode, the old template still displayed, so I suspect you may be misremembering. Looking at it in mobile mode reveals some positioning errors that I will look at later today.
 * The last label on Triassic is clickable right now, although it's a little tricky, you have to hover on the lower half. I think I know how to fix that.
 * Keep up the bug reports! So far, everything seems quite fixable. — hike395 (talk) 16:20, 8 May 2021 (UTC)
 * User:Hike395 It looks like a new problem has emerged in mobile infoboxes. See Jurassic and Triassic ) for examples, where a large blank space and a floating black line beneath the timeline has emerged.
 * Also: several links in both templates (like "Mesozoic") remain unclickable (which ones are unclickable remains consistent between mobile and desktop), but only in some of the set, so I think that might require tweaking at the local level to fix instead of a module change. — Goszei (talk) 05:29, 9 May 2021 (UTC)
 * Also: several links in both templates (like "Mesozoic") remain unclickable (which ones are unclickable remains consistent between mobile and desktop), but only in some of the set, so I think that might require tweaking at the local level to fix instead of a module change. — Goszei (talk) 05:29, 9 May 2021 (UTC)


 * Fundamentally, the old HTML/CSS was fragile: small changes would cause things to break. I've had to redo how most of the timeline is laid out (e.g., using Transform CSS)
 * The blank space was due to old CSS in the title and navbox.
 * The floating black line was because the vertical bar in the timeline was implemented in a fragile way. Now a border of a table cell.
 * The positioning of the annotations are implemented in a more robust way, so the links in them are easy to click on
 * The inability to click on labels in boxes is still puzzling. Like other problems, it's probably due to fragile old CSS. I'll work on that next.
 * — hike395 (talk) 15:57, 9 May 2021 (UTC)
 * Perhaps the VPT thread linked above in the section beginning with "Dead wikilinks" will help. — Goszei (talk) 21:56, 9 May 2021 (UTC)
 * Thanks! I fixed that div/span issue a few days ago, so I don't think it's that. I have a prototype version in the Template:Graphical timeline/sandbox which cleans up the CSS for the timeline boxes and seems to fix the clicking issue. Sadly, on Chrome, it has a funny overlap of the border that I haven't yet figured out. (see Triassic graphical timeline/sandbox). I don't want to make the code live to fix one problem and cause another, so I've held off. I hope I can figure it out in the next couple of days. — hike395 (talk) 05:26, 10 May 2021 (UTC)

✅ I believe that all reported bugs are now. if you see any further issues, please let me know here on the Talk page. Thanks for the feedback! — hike395 (talk) 03:52, 11 May 2021 (UTC)

Not clickable links (again)
Village_pump_(technical) MarMi wiki (talk) 21:06, 4 June 2021 (UTC)


 * I think that making the containers not overlap and/or introduce some structure/order would solve this problem (for all the links) . MarMi wiki (talk) 16:20, 5 June 2021 (UTC)

Dates axis
Could this module parse dates, not just numbers? — Guarapiranga ☎ 01:32, 25 April 2022 (UTC)

When embedded, top part of chronology chart is cut of
See for example the timeline in the infobox in Pleistocene. Below the heading Chronology, only a small bottom part of ↓Holocene is visible. --Lambiam 10:22, 7 August 2022 (UTC)