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
b445dba8
Commit
b445dba8
authored
Feb 08, 2022
by
sstern
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rm enableLabelPermalinks from components
parent
18c74afe
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
3 additions
and
29 deletions
+3
-29
app/assets/javascripts/vue_shared/issuable/list/components/issuable_item.vue
...pts/vue_shared/issuable/list/components/issuable_item.vue
+2
-9
app/assets/javascripts/vue_shared/issuable/list/components/issuable_list_root.vue
...ue_shared/issuable/list/components/issuable_list_root.vue
+0
-6
ee/spec/frontend/external_issues_list/components/__snapshots__/external_issues_list_root_spec.js.snap
...ents/__snapshots__/external_issues_list_root_spec.js.snap
+0
-1
spec/frontend/vue_shared/issuable/list/components/issuable_item_spec.js
...vue_shared/issuable/list/components/issuable_item_spec.js
+1
-13
No files found.
app/assets/javascripts/vue_shared/issuable/list/components/issuable_item.vue
View file @
b445dba8
...
...
@@ -31,10 +31,6 @@ export default {
type
:
Object
,
required
:
true
,
},
enableLabelPermalinks
:
{
type
:
Boolean
,
required
:
true
,
},
labelFilterParam
:
{
type
:
String
,
required
:
false
,
...
...
@@ -142,11 +138,8 @@ export default {
return
label
.
title
||
label
.
name
;
},
labelTarget
(
label
)
{
if
(
this
.
enableLabelPermalinks
)
{
const
value
=
encodeURIComponent
(
this
.
labelTitle
(
label
));
return
`?
${
this
.
labelFilterParam
}
[]=
${
value
}
`
;
}
return
'
#
'
;
const
value
=
encodeURIComponent
(
this
.
labelTitle
(
label
));
return
`?
${
this
.
labelFilterParam
}
[]=
${
value
}
`
;
},
/**
* This is needed as an independent method since
...
...
app/assets/javascripts/vue_shared/issuable/list/components/issuable_list_root.vue
View file @
b445dba8
...
...
@@ -132,11 +132,6 @@ export default {
required
:
false
,
default
:
2
,
},
enableLabelPermalinks
:
{
type
:
Boolean
,
required
:
false
,
default
:
true
,
},
labelFilterParam
:
{
type
:
String
,
required
:
false
,
...
...
@@ -320,7 +315,6 @@ export default {
:data-qa-issuable-title="issuable.title"
:issuable-symbol="issuableSymbol"
:issuable="issuable"
:enable-label-permalinks="enableLabelPermalinks"
:label-filter-param="labelFilterParam"
:show-checkbox="showBulkEditSidebar"
:checked="issuableChecked(issuable)"
...
...
ee/spec/frontend/external_issues_list/components/__snapshots__/external_issues_list_root_spec.js.snap
View file @
b445dba8
...
...
@@ -13,7 +13,6 @@ Object {
"currentPage": 1,
"currentTab": "opened",
"defaultPageSize": 2,
"enableLabelPermalinks": true,
"error": "",
"hasNextPage": false,
"hasPreviousPage": false,
...
...
spec/frontend/vue_shared/issuable/list/components/issuable_item_spec.js
View file @
b445dba8
...
...
@@ -10,7 +10,6 @@ import { mockIssuable, mockRegularLabel, mockScopedLabel } from '../mock_data';
const
createComponent
=
({
issuableSymbol
=
'
#
'
,
issuable
=
mockIssuable
,
enableLabelPermalinks
=
true
,
showCheckbox
=
true
,
slots
=
{},
}
=
{})
=>
...
...
@@ -18,7 +17,6 @@ const createComponent = ({
propsData
:
{
issuableSymbol
,
issuable
,
enableLabelPermalinks
,
showDiscussions
:
true
,
showCheckbox
,
},
...
...
@@ -212,23 +210,13 @@ describe('IssuableItem', () => {
});
describe
(
'
labelTarget
'
,
()
=>
{
it
(
'
returns target string for a provided label param
when `enableLabelPermalinks` is true
'
,
()
=>
{
it
(
'
returns target string for a provided label param
'
,
()
=>
{
wrapper
=
createComponent
();
expect
(
wrapper
.
vm
.
labelTarget
(
mockRegularLabel
)).
toBe
(
'
?label_name[]=Documentation%20Update
'
,
);
});
it
(
'
returns string "#" for a provided label param when `enableLabelPermalinks` is false
'
,
async
()
=>
{
wrapper
=
createComponent
({
enableLabelPermalinks
:
false
,
});
await
nextTick
();
expect
(
wrapper
.
vm
.
labelTarget
(
mockRegularLabel
)).
toBe
(
'
#
'
);
});
});
});
...
...
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