Skip to content

Commit

Permalink
Fix: Colors() with no args
Browse files Browse the repository at this point in the history
  • Loading branch information
s-cork committed Nov 27, 2024
1 parent d4431b1 commit 63d7da8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
https://github.com/anvilistas/anvil-extras/pull/577
* popover - fix bug with popovers not handling dom nodes correctly
https://github.com/anvilistas/anvil-extras/pull/580
* theme - fix Colors() without a variant argument
https://github.com/anvilistas/anvil-extras/pull/581

## Enhancements
* tabs - tab color can now be a css var and better support for css colors in general
Expand Down
2 changes: 1 addition & 1 deletion client_code/theme.py
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ class Colors:
def __init__(self, schemes=None, scheme=None, variant=None):
self.schemes = schemes or M3_DEFAULT_SCHEMES
self._scheme = scheme or tuple(self.schemes.keys())[0]
self._variant = variant or tuple(self.variants[0])
self._variant = variant or self.variants[0]
self._set_scheme(self.scheme, self.variant)

def _set_scheme(self, scheme, variant):
Expand Down

0 comments on commit 63d7da8

Please sign in to comment.