(theme: ThemeDefinition, path: string)
| 210 | } |
| 211 | |
| 212 | export function tryResolveColorToken(theme: ThemeDefinition, path: string): ResolveColorResult { |
| 213 | const result = resolveColorToken(theme, path); |
| 214 | if (result === null) { |
| 215 | return { ok: false, error: `Invalid color path: ${path}` }; |
| 216 | } |
| 217 | return { ok: true, value: result }; |
| 218 | } |
| 219 | |
| 220 | export function resolveColorOrRgb( |
| 221 | theme: ThemeDefinition, |
no test coverage detected