File tree Expand file tree Collapse file tree 4 files changed +11
-1
lines changed Expand file tree Collapse file tree 4 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ const HeaderBody = ({
21
21
org,
22
22
title,
23
23
username,
24
+ name,
24
25
isAdmin,
25
26
studioBaseUrl,
26
27
logoutUrl,
@@ -100,6 +101,7 @@ const HeaderBody = ({
100
101
< UserMenu
101
102
{ ...{
102
103
username,
104
+ name,
103
105
studioBaseUrl,
104
106
logoutUrl,
105
107
authenticatedUserAvatar,
@@ -125,6 +127,7 @@ HeaderBody.propTypes = {
125
127
logoAltText : PropTypes . string ,
126
128
authenticatedUserAvatar : PropTypes . string ,
127
129
username : PropTypes . string ,
130
+ name : PropTypes . string ,
128
131
isAdmin : PropTypes . bool ,
129
132
isMobile : PropTypes . bool ,
130
133
isHiddenMainMenu : PropTypes . bool ,
@@ -150,6 +153,7 @@ HeaderBody.defaultProps = {
150
153
title : '' ,
151
154
authenticatedUserAvatar : null ,
152
155
username : null ,
156
+ name : null ,
153
157
isAdmin : false ,
154
158
isMobile : false ,
155
159
isHiddenMainMenu : false ,
Original file line number Diff line number Diff line change @@ -45,6 +45,7 @@ MobileHeader.propTypes = {
45
45
logoAltText : PropTypes . string ,
46
46
authenticatedUserAvatar : PropTypes . string ,
47
47
username : PropTypes . string ,
48
+ name : PropTypes . string ,
48
49
isAdmin : PropTypes . bool ,
49
50
mainMenuDropdowns : PropTypes . arrayOf ( PropTypes . shape ( {
50
51
id : PropTypes . string ,
@@ -65,6 +66,7 @@ MobileHeader.defaultProps = {
65
66
title : null ,
66
67
authenticatedUserAvatar : null ,
67
68
username : null ,
69
+ name : null ,
68
70
isAdmin : false ,
69
71
mainMenuDropdowns : [ ] ,
70
72
outlineLink : null ,
Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ const StudioHeader = ({
26
26
org,
27
27
title,
28
28
username : authenticatedUser ?. username ,
29
+ name : authenticatedUser ?. name ,
29
30
isAdmin : authenticatedUser ?. administrator ,
30
31
authenticatedUserAvatar : authenticatedUser ?. avatar ,
31
32
studioBaseUrl : config . STUDIO_BASE_URL ,
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ import getUserMenuItems from './utils';
9
9
10
10
const UserMenu = ( {
11
11
username,
12
+ name,
12
13
studioBaseUrl,
13
14
logoutUrl,
14
15
authenticatedUserAvatar,
@@ -32,7 +33,7 @@ const UserMenu = ({
32
33
data-testid = "avatar-icon"
33
34
/>
34
35
) ;
35
- const title = isMobile ? avatar : < > { avatar } { username } </ > ;
36
+ const title = isMobile ? avatar : < > { avatar } { name || username } </ > ;
36
37
37
38
return (
38
39
< NavDropdownMenu
@@ -50,6 +51,7 @@ const UserMenu = ({
50
51
51
52
UserMenu . propTypes = {
52
53
username : PropTypes . string ,
54
+ name : PropTypes . string ,
53
55
studioBaseUrl : PropTypes . string . isRequired ,
54
56
logoutUrl : PropTypes . string . isRequired ,
55
57
authenticatedUserAvatar : PropTypes . string ,
@@ -64,6 +66,7 @@ UserMenu.defaultProps = {
64
66
isAdmin : false ,
65
67
authenticatedUserAvatar : null ,
66
68
username : null ,
69
+ name : null ,
67
70
} ;
68
71
69
72
export default injectIntl ( UserMenu ) ;
You can’t perform that action at this time.
0 commit comments