AgeCommit message (Collapse)AuthorLines
Add the shared config writers and cgit_rcBryce Kwon-43/+31
The helpers are named by kind. cgitrc_repo and cgitrc_copy write the config file named first, and cgit_url, cgit_query and cgit_rc run cgit, each named after what it is handed first. A repository copies its defaults from the globals read before its repo.url, so cgitrc_repo places every setting itself, and a global can no longer land where it silently stops applying. The t00xx and t01xx files move to them here.
Leave the escape hook check to the tree testsBryce Kwon-11/+4
t0104 checks the same span, and what it holds, on the tree and blame pages, and t0502 checks it on a highlighted page.
Skip the shared fixtures where nothing reads themBryce Kwon-0/+1
t0004 reads only the documents, and t0005 builds its own repository and configs, so each run of either built five repositories for none.
Scroll a line range to where a single line landsBryce Kwon-0/+8
The anchors' scroll margin of half the window already centres a line scrolled to the top of the view, which is where the browser puts a single line. Asking to centre a range as well centred the margin with it, and in Chromium, WebKit and Firefox the first line of a range landed 73% of the way down the window against 49% for a single line.
Stop skipping ages as they change unitBryce Kwon-0/+6
getElementsByClassName returns a live collection, so an age moved to the next unit dropped out of it mid-loop and the age after it was skipped until the next pass, which can be a day away. On a cached page that has crossed a unit boundary every second age stayed stale. querySelectorAll returns a static list of the same elements.
Offer the versions as an optionBryce Kwon-0/+22
enable-version-info brings back the cgit and git versions that 3a00e19 took off the footer and the generator tag, for a site that wants them, and the version 2a6726a put on the signature of patches now follows it too. It stays off by default for the reason 3a00e19 gave.
Name the page first in every titleBryce Kwon-0/+15
Summary, about, log, refs, tag and stats pages shared one title, so tabs, history and search results could not tell them apart. Titles now read page, repository and site, with root-title as the site, and the description stays in the meta description, where search engines read it.
Load the scripts with deferBryce Kwon-0/+5
A plain script in the head held up parsing until it had downloaded and run, though cgit.js only acts once the document is ready. Deferred scripts still run in the order given and before DOMContentLoaded, so a site script after cgit.js can still call window.cgit.
Tidy the diff and stat options panelBryce Kwon-2/+2
Its caption sat above the box, each select took its own width, and the reload button hung indented under them. The caption is now the panel's header strip, the selects and the button share one column at the width of the widest select, and the labels lose their colons to match the commit details.
Test that every copy of the background matchesBryce Kwon-0/+16
Stop folding a tag's signature awayBryce Kwon-21/+0
The fold put a click between the reader and the signature, and the browser's own disclosure marker and summary did not take the theme. The signature prints as part of the message again, as it did up to v2.9.1.
Fold a tag's signature away under its messageBryce Kwon-0/+21
The armour ran on for more lines than most tag messages, as part of the message itself. git finds the signature for every kind it can sign with, so PGP, SSH and X.509 all fold the same way.
Set every monospace element in the theme fontBryce Kwon-0/+8
Only some pre elements named --font-mono, so code in a readme took the browser's own font, Courier in Chrome and Safari, rather than a theme's.
Show characters a browser breaks at as escapesBryce Kwon-4/+11
The HTML parser turns a carriage return with no line feed after it into a line feed, and WebKit starts a new line at U+2028 and U+2029, while git and the line numbers count line feeds alone, so each one set every later line of the tree and blame pages a line below its number. CSS Text makes vertical tab, form feed and next line forced breaks as well, though no engine honours that yet. The escapes follow gitweb, which shows control characters the same way.
Give an empty repository's clone table its hooksBryce Kwon-3/+13
It was a bare table.list with no name, section or label, the one listing that broke what the README promises a theme.
Check every markup hook the README namesBryce Kwon-0/+73
The README promised that t0005 checked them all, while fourteen went unchecked, and three of its claims were too broad. A date shown in full carries no age hooks, line anchors follow enable-tree-linenumbers and cgit.css also styles html.cgit-standalone.
Add stable markup hooks for site themesBryce Kwon-0/+99