This monorepo provides two packages for font optimization in web applications. `fontaine` is a library that automatically generates metric-adjusted CSS `@font-face` fallback rules to reduce Cumulative Layout Shift (CLS). It parses CSS, reads font metrics from files or URLs, and injects override rules with proper `size-adjust`, `ascent-override`, etc. `fontless` is a Vite plugin that builds on top of fontaine and integrates with multiple font providers (Google Fonts, Bunny, FontSource, npm, etc.) to automatically download, subset, and serve optimized fonts with zero runtime JavaScript. It scans CSS for `font-family` declarations, resolves fonts through a provider chain, downloads the actual font files, emits them as build assets, and injects both the primary `@font-face` rules and metric-override fallback families. The codebase is well-structured, has comprehensive test coverage, and follows modern JavaScript/TypeScript practices. It is a hybrid of a library (fontaine) and an application plugin (fontless) but primarily serves as a developer tool for building optimized web fonts.
This repository provides the Nerd Fonts project, a CLI tool and collection of scripts that patch popular developer fonts with a large set of icon glyphs (including Font Awesome, Devicons, Octicons, Material Design Icons, and many more). The core entry point is the `font-patcher` Python script, which uses FontForge to merge icon glyphs into existing monospace fonts. Supporting scripts handle font name parsing, CSS generation, fontconfig configuration, release automation, and testing. The repository also contains pre-patched fonts in `patched-fonts/` and the raw icon sources in `src/glyphs/`. It is a mature, widely-used tool with active maintenance and a large community.
Handwrite is a CLI application that converts a scanned handwriting sample into a TrueType font. The pipeline consists of three stages: SHEETtoPNG uses OpenCV to detect and extract individual character images from a grid-based form; PNGtoSVG uses Potrace to convert the PNG images to SVG vector outlines; and SVGtoTTF uses FontForge to compile the SVGs into a font file with configurable metrics, kerning, and bearings. The architecture is a simple sequential pipeline orchestrated by the CLI entry point. External dependencies include OpenCV, Pillow, Potrace, and FontForge. The codebase is well-structured with unit tests, CI, and modern Python packaging (uv, Python 3.14). The character detection module in `sheettopng.py` demonstrates reusable grid-based contour extraction logic.
This repository contains design assets for the United States Web Design System (USWDS) in various formats (Figma, Sketch, Adobe XD) along with icon sets and fonts. It serves as a resource for designers to access and customize USWDS components, colors, and typography. The repository is primarily a collection of design files rather than executable code, with minimal technical implementation. The Figma file is noted as the most up-to-date format, while Sketch and Adobe XD assets are less actively maintained. The repository includes contribution guidelines and licensing information, but the core value lies in the design assets themselves.