diff --git a/CHANGELOG.md b/CHANGELOG.md index 171588a70..716bef6f6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) +## [Unreleased] + +### Fixed + +- Reverted the original focus style of **Button**, as VSCode uses the `:focus` state instead of `focus-active`. + ## [1.16.0] - 2025-05-17 ### Added diff --git a/src/vscode-button/vscode-button.styles.ts b/src/vscode-button/vscode-button.styles.ts index 0a1f98a9c..47f691258 100644 --- a/src/vscode-button/vscode-button.styles.ts +++ b/src/vscode-button/vscode-button.styles.ts @@ -62,7 +62,7 @@ const styles: CSSResultGroup = [ outline: none; } - :host(:focus-visible) { + :host(:focus) { background-color: var(--vscode-button-hoverBackground, #026ec1); outline: 1px solid var(--vscode-focusBorder, #0078d4); outline-offset: 2px; @@ -146,7 +146,7 @@ const styles: CSSResultGroup = [ } :host(:hover) .divider, - :host(:focus-visible) .divider { + :host(:focus) .divider { background-color: var(--vscode-button-hoverBackground, #026ec1); } @@ -155,7 +155,7 @@ const styles: CSSResultGroup = [ } :host([secondary]:hover) .divider, - :host([secondary]:focus-visible) .divider { + :host([secondary]:focus) .divider { background-color: var(--vscode-button-secondaryHoverBackground, #3c3c3c); }