Documentation
¶
Overview ¶
Package assets owns the Githome web front's built static assets: the content-hashed CSS and JS bundles, the manifest that maps a logical name to its hashed file, and the Octicon icon registry the render layer inlines. The bundles are produced by the build command in ./build and embedded here; nothing in this package imports the web front or the persistence layer. See implementation/01 and implementation/04.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var Icons = map[string]Icon{}/* 376 elements not displayed */
Icons is the 16-grid set: the natural size for inline UI chrome. The render layer's octicon helper wraps a lookup in the outer <svg> with the size and accessibility attributes; an unknown name renders a visible placeholder, never the input, so a typo is caught in review rather than shipped (see implementation/04 section 8 and implementation/03 section 4).
var Icons24 = map[string]Icon{}/* 346 elements not displayed */
Icons24 is the 24-grid set. The octicon helper prefers it when an icon renders at 24px or larger (the header logo, blankslate heroes), so big renders get the heavier 24-grid drawing instead of an upscaled 16-grid one (spec 2005 doc 16 section 8.2). Icons that only exist on the 16 grid fall back to it at any size.
Functions ¶
Types ¶
type Icon ¶ added in v0.1.3
Icon is one registered glyph: the grid its viewBox was drawn on and the inner SVG markup. Width equals Height for every icon except the handful of wordmark glyphs (logo-github, lockup-github), so the render helper derives the viewBox and the scaled pixel width from these instead of assuming a square 16-grid.