Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
b31b3f16
Commit
b31b3f16
authored
Apr 03, 2020
by
peterhegman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename `GitLab` variables to `Gitlab`
To better follow Vue naming conventions
parent
5138606b
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
13 deletions
+11
-13
app/assets/javascripts/notes/components/note_header.vue
app/assets/javascripts/notes/components/note_header.vue
+4
-4
app/assets/javascripts/vue_shared/components/user_avatar/badges/gitlab_team_member_badge.vue
...omponents/user_avatar/badges/gitlab_team_member_badge.vue
+5
-7
spec/frontend/notes/components/note_header_spec.js
spec/frontend/notes/components/note_header_spec.js
+2
-2
No files found.
app/assets/javascripts/notes/components/note_header.vue
View file @
b31b3f16
<
script
>
import
{
mapActions
}
from
'
vuex
'
;
import
timeAgoTooltip
from
'
../../vue_shared/components/time_ago_tooltip.vue
'
;
import
Git
L
abTeamMemberBadge
from
'
../../vue_shared/components/user_avatar/badges/gitlab_team_member_badge.vue
'
;
import
Git
l
abTeamMemberBadge
from
'
../../vue_shared/components/user_avatar/badges/gitlab_team_member_badge.vue
'
;
export
default
{
components
:
{
timeAgoTooltip
,
'
gitlab-team-member-badge
'
:
GitL
abTeamMemberBadge
,
Gitl
abTeamMemberBadge
,
},
props
:
{
author
:
{
...
...
@@ -50,7 +50,7 @@ export default {
hasAuthor
()
{
return
this
.
author
&&
Object
.
keys
(
this
.
author
).
length
;
},
showGit
L
abTeamMemberBadge
()
{
showGit
l
abTeamMemberBadge
()
{
return
this
.
author
?.
is_gitlab_employee
;
},
},
...
...
@@ -91,7 +91,7 @@ export default {
<span
v-if=
"author.status_tooltip_html"
v-html=
"author.status_tooltip_html"
></span>
<span
class=
"note-headline-light"
>
@
{{
author
.
username
}}
</span>
</a>
<gitlab-team-member-badge
v-if=
"showGit
L
abTeamMemberBadge"
/>
<gitlab-team-member-badge
v-if=
"showGit
l
abTeamMemberBadge"
/>
</
template
>
<span
v-else
>
{{ __('A deleted user') }}
</span>
<span
class=
"note-headline-light note-headline-meta"
>
...
...
app/assets/javascripts/vue_shared/components/user_avatar/badges/gitlab_team_member_badge.vue
View file @
b31b3f16
...
...
@@ -2,26 +2,24 @@
import
{
GlTooltipDirective
,
GlIcon
}
from
'
@gitlab/ui
'
;
import
{
__
}
from
'
~/locale
'
;
const
GITLAB_TEAM_MEMBER
=
__
(
'
GitLab Team Member
'
);
const
GITLAB_TEAM_MEMBER
_LABEL
=
__
(
'
GitLab Team Member
'
);
export
default
{
name
:
'
Git
L
abTeamMemberBadge
'
,
name
:
'
Git
l
abTeamMemberBadge
'
,
directives
:
{
GlTooltip
:
GlTooltipDirective
,
},
components
:
{
GlIcon
},
created
()
{
this
.
GITLAB_TEAM_MEMBER
=
GITLAB_TEAM_MEMBER
;
},
gitlabTeamMemberLabel
:
GITLAB_TEAM_MEMBER_LABEL
,
};
</
script
>
<
template
>
<span
v-gl-tooltip
.
hover
:title=
"
GITLAB_TEAM_MEMBER
"
:title=
"
$options.gitlabTeamMemberLabel
"
role=
"img"
:aria-label=
"
GITLAB_TEAM_MEMBER
"
:aria-label=
"
$options.gitlabTeamMemberLabel
"
class=
"d-inline-block align-middle"
>
<gl-icon
name=
"tanuki-verified"
class=
"gl-text-purple d-block"
/>
...
...
spec/frontend/notes/components/note_header_spec.js
View file @
b31b3f16
import
{
shallowMount
,
createLocalVue
}
from
'
@vue/test-utils
'
;
import
Vuex
from
'
vuex
'
;
import
NoteHeader
from
'
~/notes/components/note_header.vue
'
;
import
Git
L
abTeamMemberBadge
from
'
~/vue_shared/components/user_avatar/badges/gitlab_team_member_badge.vue
'
;
import
Git
l
abTeamMemberBadge
from
'
~/vue_shared/components/user_avatar/badges/gitlab_team_member_badge.vue
'
;
const
localVue
=
createLocalVue
();
localVue
.
use
(
Vuex
);
...
...
@@ -150,7 +150,7 @@ describe('NoteHeader component', () => {
({
props
,
expected
})
=>
{
createComponent
(
props
);
expect
(
wrapper
.
find
(
Git
L
abTeamMemberBadge
).
exists
()).
toBe
(
expected
);
expect
(
wrapper
.
find
(
Git
l
abTeamMemberBadge
).
exists
()).
toBe
(
expected
);
},
);
});
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment