diff options
| author | netop://ウィビ <paul@webb.page> | 2026-04-25 12:29:59 -0700 |
|---|---|---|
| committer | netop://ウィビ <paul@webb.page> | 2026-04-25 12:29:59 -0700 |
| commit | dc5fff0c0afdf832b9b000e13ddc633f72749e01 (patch) | |
| tree | 5730bd4ea089dadbc9c7f057a3988104fb662827 /README.md | |
| parent | a2118aa39a00e02cdf3f6c306e17fd04676ea518 (diff) | |
| download | uchu-dc5fff0c0afdf832b9b000e13ddc633f72749e01.tar.gz uchu-dc5fff0c0afdf832b9b000e13ddc633f72749e01.zip | |
fantastic update
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 55 |
1 files changed, 55 insertions, 0 deletions
@@ -6,6 +6,61 @@ No, [I will not add other color spaces](./documentation/FAQ.md#normal-colors). +## Install + +```sh +bun add uchu +# or: npm install uchu / pnpm add uchu / yarn add uchu +``` + + + +## Usage + +### JavaScript / TypeScript + +```ts +import { color, palette, reduced, yang } from "uchu"; + +palette.blue[5]; // "oklch(54.87% 0.222 260.33)" +color("red", 7); // "oklch(49.95% 0.195 18.34)" +reduced.green[2]; // mid-shade green from the reduced palette +yang; // off-white background constant +``` + +Types `Hue` and `Shade` are exported for narrowing palette keys. + +### CSS + +Drop the stylesheet in and use the CSS custom properties: + +```ts +import "uchu/css"; +``` + +```css +body { + background-color: var(--uchu-yang); + border: 1px solid var(--uchu-blue-5); + color: var(--uchu-yin-9); +} +``` + +### Sass / SCSS + +```scss +@use "uchu/scss" as *; + +body { + background-color: $uchu-yang; + color: $uchu-yin-9; +} +``` + +Prefer URL imports? See the [URL-based usage guide](./documentation/USAGE.md). + + + ## Table of Contents - [Expanded Palette](./documentation/EXPANDED.md) |