Skip to content

Commit 1606001

Browse files
authored
docs(theme): document ANSI color tokens (#59)
1 parent 286a859 commit 1606001

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

docs/THEME.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,24 @@ name = "MyTheme"
8181
If you provide `MyTheme-light.json` and `MyTheme-dark.json`, `oyo` will pick the
8282
variant based on `ui.theme.mode` (and fall back to the other if one is missing).
8383

84+
#### ANSI color names
85+
86+
Theme tokens accept ANSI color names, which use your terminal’s palette:
87+
88+
```json
89+
{
90+
"theme": {
91+
"diffAdded": { "dark": "green" },
92+
"diffRemoved": { "dark": "red" }
93+
}
94+
}
95+
```
96+
97+
Supported names:
98+
`black`, `red`, `green`, `yellow`, `blue`, `magenta`, `cyan`, `gray`,
99+
`dark_gray`, `light_red`, `light_green`, `light_yellow`, `light_blue`,
100+
`light_magenta`, `light_cyan`, `white`, and `default`/`reset`/`transparent`.
101+
84102
## Syntax Themes
85103

86104
Syntax highlighting is tmTheme-based. You can select a built-in syntax theme or provide

0 commit comments

Comments
 (0)