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
9e568113
Commit
9e568113
authored
Apr 03, 2020
by
Mike Greiling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Switch to GlSprintf for dropdown option
parent
a4ed543f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
12 deletions
+10
-12
app/assets/javascripts/clusters/components/knative_domain_editor.vue
...javascripts/clusters/components/knative_domain_editor.vue
+10
-12
No files found.
app/assets/javascripts/clusters/components/knative_domain_editor.vue
View file @
9e568113
<
script
>
<
script
>
import
{
escape
}
from
'
lodash
'
;
import
{
import
{
GlDropdown
,
GlDropdown
,
GlDropdownDivider
,
GlDropdownDivider
,
GlDropdownItem
,
GlDropdownItem
,
GlLoadingIcon
,
GlLoadingIcon
,
GlSearchBoxByType
,
GlSearchBoxByType
,
GlSprintf
,
}
from
'
@gitlab/ui
'
;
}
from
'
@gitlab/ui
'
;
import
LoadingButton
from
'
~/vue_shared/components/loading_button.vue
'
;
import
LoadingButton
from
'
~/vue_shared/components/loading_button.vue
'
;
import
ClipboardButton
from
'
../../vue_shared/components/clipboard_button.vue
'
;
import
ClipboardButton
from
'
../../vue_shared/components/clipboard_button.vue
'
;
import
{
__
,
s__
,
sprintf
}
from
'
~/locale
'
;
import
{
__
,
s__
}
from
'
~/locale
'
;
import
{
APPLICATION_STATUS
}
from
'
~/clusters/constants
'
;
import
{
APPLICATION_STATUS
}
from
'
~/clusters/constants
'
;
...
@@ -24,6 +24,7 @@ export default {
...
@@ -24,6 +24,7 @@ export default {
GlDropdownDivider
,
GlDropdownDivider
,
GlDropdownItem
,
GlDropdownItem
,
GlSearchBoxByType
,
GlSearchBoxByType
,
GlSprintf
,
},
},
props
:
{
props
:
{
knative
:
{
knative
:
{
...
@@ -71,15 +72,6 @@ export default {
...
@@ -71,15 +72,6 @@ export default {
domainDropdownText
()
{
domainDropdownText
()
{
return
this
.
knativeHostname
||
s__
(
'
ClusterIntegration|Select existing domain or use new
'
);
return
this
.
knativeHostname
||
s__
(
'
ClusterIntegration|Select existing domain or use new
'
);
},
},
useQueryText
()
{
return
sprintf
(
s__
(
'
ClusterIntegration|Use %{query}
'
),
{
query
:
`<code>
${
escape
(
this
.
searchQuery
)}
</code>`
,
},
false
,
);
},
availableDomains
()
{
availableDomains
()
{
return
this
.
knative
.
availableDomains
||
[];
return
this
.
knative
.
availableDomains
||
[];
},
},
...
@@ -147,7 +139,13 @@ export default {
...
@@ -147,7 +139,13 @@ export default {
<template
v-if=
"searchQuery"
>
<template
v-if=
"searchQuery"
>
<gl-dropdown-divider
/>
<gl-dropdown-divider
/>
<gl-dropdown-item
key=
"custom-domain"
@
click=
"selectCustomDomain(searchQuery)"
>
<gl-dropdown-item
key=
"custom-domain"
@
click=
"selectCustomDomain(searchQuery)"
>
<span
class=
"ml-1"
v-html=
"useQueryText"
></span>
<span
class=
"ml-1"
>
<gl-sprintf
:message=
"s__('ClusterIntegration|Use %
{query}')">
<template
#query
>
<code>
{{
searchQuery
}}
</code>
</
template
>
</gl-sprintf>
</span>
</gl-dropdown-item>
</gl-dropdown-item>
</template>
</template>
</gl-dropdown>
</gl-dropdown>
...
...
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