charmbracelet / lipgloss

Style definitions for nice terminal layouts 👄
MIT License
8.22k stars 231 forks source link

(v2) refactor: remove error return from HasDarkBackground #438

Closed aymanbagabas closed 1 week ago

aymanbagabas commented 1 week ago

This defaults to true if an error is encountered or if the background color is nil. This is a simplification that makes the function easier to use in practice.

Users can still check for errors by calling BackgroundColor directly.