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
dbc6cfb6
Commit
dbc6cfb6
authored
Jul 25, 2018
by
Winnie Hellmann
Committed by
Phil Hughes
Jul 25, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Replace clipboard icon in Service Desk settings
parent
6ac88596
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
29 additions
and
14 deletions
+29
-14
ee/app/assets/javascripts/projects/settings_service_desk/components/service_desk_setting.vue
...settings_service_desk/components/service_desk_setting.vue
+11
-12
ee/changelogs/unreleased/winh-service-desk-clipboard.yml
ee/changelogs/unreleased/winh-service-desk-clipboard.yml
+5
-0
ee/spec/javascripts/projects/settings_service_desk/components/service_desk_setting_spec.js
...ings_service_desk/components/service_desk_setting_spec.js
+10
-2
locale/gitlab.pot
locale/gitlab.pot
+3
-0
No files found.
ee/app/assets/javascripts/projects/settings_service_desk/components/service_desk_setting.vue
View file @
dbc6cfb6
<
script
>
import
tooltip
from
'
~/vue_shared/directives/tooltip
'
;
import
ClipboardButton
from
'
~/vue_shared/components/clipboard_button.vue
'
;
import
eventHub
from
'
../event_hub
'
;
export
default
{
...
...
@@ -7,6 +8,11 @@
directives
:
{
tooltip
,
},
components
:
{
ClipboardButton
,
},
props
:
{
isEnabled
:
{
type
:
Boolean
,
...
...
@@ -59,18 +65,11 @@
>
{{
incomingEmail
}}
</span>
<button
v-tooltip
:data-clipboard-text=
"incomingEmail"
type=
"button"
class=
"btn btn-clipboard btn-transparent"
title=
"Copy incoming email address to clipboard"
>
<i
class=
"fa fa-clipboard"
aria-hidden=
"true"
>
</i>
</button>
<clipboard-button
:title=
"__('Copy incoming email address to clipboard')"
:text=
"incomingEmail"
css-class=
"btn btn-clipboard btn-transparent"
/>
</
template
>
<
template
v-else
>
<i
...
...
ee/changelogs/unreleased/winh-service-desk-clipboard.yml
0 → 100644
View file @
dbc6cfb6
---
title
:
Replace clipboard icon in Service Desk settings
merge_request
:
6643
author
:
type
:
changed
ee/spec/javascripts/projects/settings_service_desk/components/service_desk_setting_spec.js
View file @
dbc6cfb6
...
...
@@ -44,20 +44,28 @@ describe('ServiceDeskSetting', () => {
});
describe
(
'
with incomingEmail
'
,
()
=>
{
const
incomingEmail
=
'
foo@bar.com
'
;
beforeEach
(()
=>
{
vm
=
new
ServiceDeskSetting
({
propsData
:
{
isEnabled
:
true
,
incomingEmail
:
'
foo@bar.com
'
,
incomingEmail
,
},
}).
$mount
();
});
it
(
'
should see email
'
,
()
=>
{
expect
(
vm
.
$refs
[
'
service-desk-incoming-email
'
].
textContent
.
trim
()).
toEqual
(
'
foo@bar.com
'
);
expect
(
vm
.
$refs
[
'
service-desk-incoming-email
'
].
textContent
.
trim
()).
toEqual
(
incomingEmail
);
expect
(
vm
.
$el
.
querySelector
(
'
.fa-spinner
'
)).
toBeNull
();
expect
(
vm
.
$el
.
querySelector
(
'
.fa-exclamation-circle
'
)).
toBeNull
();
});
it
(
'
renders a copy to clipboard button
'
,
()
=>
{
const
button
=
vm
.
$el
.
querySelector
(
'
.btn-clipboard
'
);
expect
(
button
).
not
.
toBe
(
null
);
expect
(
button
.
dataset
.
clipboardText
).
toBe
(
incomingEmail
);
});
});
});
...
...
locale/gitlab.pot
View file @
dbc6cfb6
...
...
@@ -2054,6 +2054,9 @@ msgstr ""
msgid "Copy file path to clipboard"
msgstr ""
msgid "Copy incoming email address to clipboard"
msgstr ""
msgid "Copy reference to clipboard"
msgstr ""
...
...
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