@@ -5,12 +5,13 @@ import { useDispatch } from 'react-redux';
5
5
import { openPreferences } from '../actions/ide' ;
6
6
import { setPreferencesTab } from '../actions/preferences' ;
7
7
import { prop } from '../../../theme' ;
8
- import EditIcon from '../../../images/preferences .svg' ;
8
+ import EditIcon from '../../../images/pencil .svg' ;
9
9
10
10
import { useP5Version } from '../hooks/useP5Version' ;
11
11
12
12
const VersionPickerButton = styled . button `
13
13
color: ${ prop ( 'Button.primary.default.foreground' ) } ;
14
+ margin-right: 1rem;
14
15
15
16
&:hover {
16
17
color: ${ prop ( 'Button.primary.hover.background' ) } !important;
@@ -19,9 +20,8 @@ const VersionPickerButton = styled.button`
19
20
& svg {
20
21
vertical-align: middle;
21
22
margin-bottom: 2px;
22
- margin-left: 0.5rem;
23
- width: 1rem;
24
- height: 1rem;
23
+ width: 1.5rem;
24
+ height: 1.5rem;
25
25
}
26
26
27
27
&:hover path {
@@ -61,22 +61,21 @@ const VersionIndicator = () => {
61
61
window . localStorage . setItem ( CLICKED_LIBRARY_VERSION_KEY , true ) ;
62
62
} , [ ] ) ;
63
63
64
- const label = t ( 'Toolbar.LibraryVersion' ) ;
65
- const currentVersion =
66
- versionInfo ?. version || t ( 'Toolbar.CustomLibraryVersion' ) ;
64
+ const currentVersion = versionInfo ?. version
65
+ ? `p5.js ${ versionInfo . version } `
66
+ : t ( 'Toolbar.CustomLibraryVersion' ) ;
67
67
const description = t (
68
68
showNotificationDot
69
69
? 'Toolbar.NewVersionPickerARIA'
70
70
: 'Toolbar.VersionPickerARIA'
71
71
) ;
72
- const ariaLabel = `${ label } : ${ currentVersion } - ${ description } ` ;
72
+ const ariaLabel = `${ currentVersion } - ${ description } ` ;
73
73
74
74
return (
75
75
< VersionPickerButton onClick = { openVersionSettings } ariaLabel = { ariaLabel } >
76
- { label } :
77
76
{ currentVersion }
78
- { showNotificationDot && < NotificationDot /> }
79
77
< EditIcon focusable = "false" aria-hidden = "true" />
78
+ { showNotificationDot && < NotificationDot /> }
80
79
</ VersionPickerButton >
81
80
) ;
82
81
} ;
0 commit comments