Skip to content

Commit

Permalink
fix: color select disappeared unexpectedly on simulator (#1976)
Browse files Browse the repository at this point in the history
  • Loading branch information
binyellow committed Dec 7, 2023
1 parent ef4835a commit 1c2a6fb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .dumi/theme/slots/HeaderExtra/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ const HeaderExtra: FC = () => {
window.open('https://v1.d.umijs.org/', '_blank');
}
}}
onClick={(e) => {
e.stopPropagation();
}}
>
<option value={process.env.DUMI_VERSION}>
{process.env.DUMI_VERSION}
Expand Down
1 change: 1 addition & 0 deletions src/client/theme-default/slots/ColorSwitch/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ const ColorSwitch: FC = () => {
<select
onChange={(ev) => setPrefersColor(ev.target.value as any)}
value={prefersColor}
onClick={(e) => e.stopPropagation()}
>
{['light', 'dark', 'auto'].map((c) => (
<option value={c} key={c}>
Expand Down

0 comments on commit 1c2a6fb

Please sign in to comment.