Skip to content

Commit 612bfa2

Browse files
juliacanzaniclaude
andcommitted
Button: Fix missing hover state on action buttons
The secondary/outline background override pinned the background property with !important, which blocked TUI's variable-driven hover/active states. Set the --tui-button-bg rest-state token instead. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
1 parent 04209eb commit 612bfa2

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

assets/src/components/base/button/index.scss

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,10 +79,12 @@
7979
* Most of the time we expect this background to be the same color as
8080
* fields background in fields
8181
*
82-
* We have to use !important because rule we overwrite is set to important
82+
* Set via TUI's --tui-button-bg token (rest state only) rather than the
83+
* background property: TUI hover/active works by swapping the internal
84+
* --_bg variable, so pinning background directly would disable hover.
8385
*/
8486
button.tui-button.is-theme-secondary.is-style-outline {
85-
background: $field-background !important;
87+
--tui-button-bg: #{$field-background};
8688
}
8789

8890
/* Icons */

0 commit comments

Comments
 (0)