Skip to content

Commit d76a0f9

Browse files
committed
update styling for version picker to match toolbar
1 parent be8d50a commit d76a0f9

File tree

3 files changed

+17
-4
lines changed

3 files changed

+17
-4
lines changed

client/modules/IDE/components/VersionIndicator.jsx

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,21 @@ import { useDispatch } from 'react-redux';
55
import { openPreferences } from '../actions/ide';
66
import { setPreferencesTab } from '../actions/preferences';
77
import { prop } from '../../../theme';
8-
import EditIcon from '../../../images/preferences.svg';
98

109
import { useP5Version } from '../hooks/useP5Version';
1110

1211
const VersionPickerButton = styled.button`
13-
color: ${prop('Button.primary.default.foreground')};
12+
color: ${prop('toolbarTextColor')} !important;
1413
margin-left: 1rem;
1514
15+
background-color: ${prop('toolbarBackgroundColor')};
16+
margin-right: 1.2rem;
17+
padding: 0.5rem 0.7rem;
18+
border-radius: 10rem;
19+
1620
&:hover {
17-
color: ${prop('Button.primary.hover.background')} !important;
21+
background-color: ${prop('Button.primary.hover.background')} !important;
22+
color: ${prop('toolbarTextHoverColor')} !important;
1823
}
1924
2025
& svg {
@@ -75,7 +80,6 @@ const VersionIndicator = () => {
7580
return (
7681
<VersionPickerButton onClick={openVersionSettings} ariaLabel={ariaLabel}>
7782
{currentVersion}
78-
<EditIcon focusable="false" aria-hidden="true" />
7983
{showNotificationDot && <NotificationDot />}
8084
</VersionPickerButton>
8185
);

client/styles/components/_version-indicator.scss

Whitespace-only changes.

client/theme.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ const baseThemes = {
8080
searchBackgroundColor: grays.lightest,
8181
tableRowStripeColor: grays.mediumLight,
8282
notification: colors.dodgerblue,
83+
toolbarTextColor: grays.dark,
84+
toolbarBackgroundColor: grays.mediumLight,
85+
toolbarTextHoverColor: grays.lightest,
8386

8487
Button: {
8588
primary: {
@@ -172,6 +175,9 @@ const baseThemes = {
172175
searchBackgroundColor: grays.darker,
173176
tableRowStripeColor: grays.dark,
174177
notification: colors.processingBlueLight,
178+
toolbarTextColor: grays.lightest,
179+
toolbarBackgroundColor: grays.mediumDark,
180+
toolbarTextHoverColor: grays.lightest,
175181

176182
Button: {
177183
primary: {
@@ -260,6 +266,9 @@ export default {
260266
inactiveTextColor: grays.light,
261267
logoColor: colors.yellow,
262268
notification: colors.p5ContrastYellow,
269+
toolbarTextColor: grays.dark,
270+
toolbarBackgroundColor: grays.light,
271+
toolbarTextHoverColor: grays.dark,
263272

264273
Button: {
265274
primary: {

0 commit comments

Comments
 (0)