AgeCommit message (Collapse)AuthorLines
Drop the marker glyph on a targeted line numberBryce Kwon-5/+0
Settle the theme and header before the first paintBryce Kwon-4/+17
Right-align the repo owner to the header edgeBryce Kwon-1/+4
Drop the help tab and its built-in guideBryce Kwon-27/+0
Replace the browser markdown renderer with a filterBryce Kwon-8/+0
The readme is now escaped plain text unless `about-filter` points at the new `about-render.lua`, which renders markdown, man pages and plain text server-side. `enable-markdown` goes away with the renderer.
Redraw the logo and favicon at higher resolutionBryce Kwon-0/+10
Even out font sizes and drop dead stylesBryce Kwon-116/+47
Declutter the interface on small screensBryce Kwon-26/+22
Follow the theme in the external tab iconBryce Kwon-3/+13
Highlight and center fragment-targeted linesBryce Kwon-0/+31
Move syntax highlighting to a Lua source filterBryce Kwon-1/+3
Stat oversized diffs instead of inlining themBryce Kwon-0/+10
Add a help page with common workflowsBryce Kwon-0/+27
Keep line structure in plaintext readmesBryce Kwon-0/+18
Render README markdown in the browserBryce Kwon-0/+90
cgit had no markdown support of its own, so a readme was rendered through an external python filter or not at all. Escaping the source and formatting it in cgit.js keeps the work in the browser like the blob highlighter, and the page stays readable as plain text without scripting.
Add built-in syntax highlightingBryce Kwon-0/+7
Highlighting previously required a source filter shelling out to something like Pygments. A configured source filter still takes precedence, every character is preserved so the line gutter stays aligned, and large files are skipped.
Adapt the layout to small screensBryce Kwon-0/+128
On a phone the description, owner and shortcut columns crowded the index and pushed the age off screen, and tapping the name already opens the repository, so the index collapses to name and age.
Add a light and dark theme toggleBryce Kwon-5/+49
The button is emitted hidden and only revealed by the script, so a browser without JavaScript never shows a control that cannot work and the page keeps tracking the system theme.
Overhaul the stylesheet with tokens and dark modeBryce Kwon-224/+465
The old sheet had no overflow rules, so wide code, diff, blame and stats blocks scrolled the whole page sideways on a phone. The classic layout, badge colours and age shading are kept.
Rebuild the page chrome as semantic HTMLBryce Kwon-42/+85
The masthead, tab bar, breadcrumb, content region and footer were HTML tables, which cannot reflow and forced the page to scroll sideways on small screens. Class and id names are kept so custom themes keep matching, the tabs gain title hints and the form controls accessible names.
Reorganize into source, assets and librariesBryce Kwon-0/+0
The C sources move to source/, the served files to assets/, the bundled Git submodule to libraries/git and the filter scripts to extensions/. Everything the build generates now lands in build/, so a clean is a single remove and the tree stays clean.
css: round border edges for decoChristian Hesse-0/+5
Signed-off-by: Christian Hesse <mail@eworm.de>
css: highlight line in diff...Loïc-0/+5
... specified in the URL, with a curved arrow ahead of the line number. Signed-off-by: Loïc <lagiraudiere+cgit@free.fr> Signed-off-by: Christian Hesse <mail@eworm.de>
css: reset font size for blame oidJohn Keeping-0/+4
In Firefox, the hashes in the blame UI are out of step with the line number and content leading to ever increasing vertical misalignment. This is caused by the .oid class setting font-size to 90%, so override this back to 100% for the blame case, bringing the height of lines in all three columns of the table back into step. Signed-off-by: John Keeping <john@keeping.me.uk> Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
global: replace references to 'sha1' with 'oid'Christian Hesse-1/+1
For some time now sha1 is considered broken and upstream is working to replace it with sha256. Replace all references to 'sha1' with 'oid', just as upstream does. Signed-off-by: Christian Hesse <mail@eworm.de>
css: use correct size in annotated decorationJason A. Donenfeld-0/+1
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
ui-log: highlight annotated tags in different colorChristian Hesse-0/+8
Annotated tags have some extra information... Descriptive text or signature. Highlighting annotated tags in a different color show what tag may be worth clicking for extra information. Signed-off-by: Christian Hesse <mail@eworm.de> Reviewed-by: John Keeping <john@keeping.me.uk>
ui-blame: Allow syntax highlightingJeff Smith-0/+10
Place file contents into a single block so that syntax highlighting can be applied in the usual fashion. Place the alternating color bars behind the file contents. Force the default syntax highlighting background to transparent. Signed-off-by: Jeff Smith <whydoubt@gmail.com> Reviewed-by: John Keeping <john@keeping.me.uk>
ui-blame: Make each column into a single table cellJeff Smith-2/+17
Signed-off-by: Jeff Smith <whydoubt@gmail.com> Reviewed-by: John Keeping <john@keeping.me.uk>
ui-blame: Distinguish hashes column from lines columnJeff Smith-0/+1
Signed-off-by: Jeff Smith <whydoubt@gmail.com> Reviewed-by: John Keeping <john@keeping.me.uk>
ui-blame: add blame UIJeff Smith-0/+8
Implement a page which provides the blame view of a specified file. This feature is controlled by a new config variable, "enable-blame", which is disabled by default. Signed-off-by: Jeff Smith <whydoubt@gmail.com> Reviewed-by: John Keeping <john@keeping.me.uk>
css: highlight even table rows and skip empty rowsChristian Hesse-0/+20
This is stolen from kernel.org css [0]. [0] https://git.kernel.org/cgit-korg-0.10.1.css
css: consistent use of empty linesChristian Hesse-0/+6
Signed-off-by: Christian Hesse <mail@eworm.de>
ui-log: color line changesChristian Hesse-0/+9
Signed-off-by: Christian Hesse <mail@eworm.de>
css: fix indentationJason A. Donenfeld-4/+4
css: use less blurry icon for external linkChristian Hesse-1/+2
Your mileage may vary, but for me the old icon looks blurry. The new one is character 0xf08e from OTF font awsome in size 10. The icon color is black, gray level is adjusted via opacity. Signed-off-by: Christian Hesse <mail@eworm.de>
ui-shared: add homepage to tabsJason A. Donenfeld-0/+5
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Remove no-op link from submodule entriesLukas Fleischer-1/+1
Instead of linking to the current page ("href='#'"), do not add a link to a submodule entry at all if the module-link setting is not used. Signed-off-by: Lukas Fleischer <cgit@cryptocrack.de>
footer: link back to cgit home pageJason A. Donenfeld-0/+7
The footer has always been overrideable using the footer= in cgitrc, so this won't anger anybody who cares about their footer.
Reduce line number bloat, fix hover effectPeter Wu-2/+4
Currently line numbers look like (for blob view and sdiff respectively): <a class='no' id='n68' name='n68' href='#n68'>68</a> <td class='lineno'><a class='no' href='...#n1' id='n1' name='n1'>1</a></td> name=".." is unnecessary if the id attribute is set (this even applies to IE6), so drop it. (aside, in HTML5, the name attribute is gone.) The line number links can be selected through their parent classes, no need for another class "no", so drop it too. For a file with 2000 lines, this yields a saving of 40% (29% gzipped). While at it, fix the hover effect of line numbers: now the line number get a black background as was intended. Signed-off-by: Peter Wu <lekensteyn@gmail.com> Signed-off-by: Lukas Fleischer <cgit@cryptocrack.de>
filters: import more modern scriptsJason A. Donenfeld-14/+0
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Convert pager navigation into a unordered listLukas Fleischer-4/+10
It is common practice and semantically appropriate to use unordered lists for long navigation lists. This also fixes the layout of very long pager navigations in Webkit-based browsers. Signed-off-by: Lukas Fleischer <cgit@cryptocrack.de>
ui-repolist: Bold the currently viewed page.Jamie Couture-0/+4
Signed-off-by: Jamie Couture <jamie.couture@gmail.com>
css: only use div#cgitFerry Huberts-4/+1
Don't bother with 'body' and 'div#cgit form', since everything is wrapped in 'div#cgit' already. Removing these two types makes embedding even easier. Signed-off-by: Ferry Huberts <ferry.huberts@pelagic.nl>
css: force text color to black on decorationsFerry Huberts-0/+4
improves readability when embedding into a page that has the text color set to a different color Signed-off-by: Ferry Huberts <ferry.huberts@pelagic.nl>
css: vertically align the cgit logo imageFerry Huberts-0/+1
When embedding cgit in other pages, the logo alignment needs to be specified to avoid any css rules from the embedding page to make the page look bad. Signed-off-by: Ferry Huberts <ferry.huberts@pelagic.nl>
css: prefix all styles with div#cgitFerry Huberts-169/+169
to facilitate easier embedding Signed-off-by: Ferry Huberts <ferry.huberts@pelagic.nl>
fix css color value and vertical-align valueNorberto Lopes-2/+2
ui-diff.c: create a control panel for diff optionsLars Hjemli-0/+27
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
ssdiff: anchors for ssdiffBernhard Reutner-Fischer-1/+1
Emit anchors to the respective revisions in side-by-side diff view Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Lars Hjemli <hjemli@gmail.com>