Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
menu_link_attributes
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
menu_link_attributes
Merge requests
!25
Issue
#3472203
: menu_link_attributes_update_8002 adds container_class attribute if disabled
Code
Review changes
Check out branch
Open in Workspace
Download
Patches
Plain diff
Expand sidebar
Open
Issue
#3472203
: menu_link_attributes_update_8002 adds container_class attribute if disabled
issue/menu_link_attributes-3472203:3472203-menulinkattributesupdate8002-adds-containerclass
into
8.x-1.x
Overview
0
Commits
1
Pipelines
1
Changes
1
Open
Issue #3472203: menu_link_attributes_update_8002 adds container_class attribute if disabled
Adam Bramley
requested to merge
issue/menu_link_attributes-3472203:3472203-menulinkattributesupdate8002-adds-containerclass
into
8.x-1.x
11 months ago
Overview
0
Commits
1
Pipelines
1
Changes
1
Closes
#3472203
0
0
Merge request reports
Compare
8.x-1.x
8.x-1.x (HEAD)
and
latest version
latest version
18dc652f
1 commit,
11 months ago
1 file
+
7
−
5
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
menu_link_attributes.install
+
7
−
5
View file @ 2203b25c
Edit in single-file editor
Open in Web IDE
Show full file
@@ -89,11 +89,13 @@ function menu_link_attributes_update_8002(): void {
->
get
(
'attributes'
);
// Only set if not yet existing in custom config:
if
(
!
isset
(
$attributes
[
'container_class'
]))
{
$attributes
[
'container_class'
]
=
[
'label'
=>
'Container class(es)'
,
'description'
=>
'CSS class for the menu list item (<li>). Separate multiple classes by space.'
,
];
if
(
isset
(
$attributes
[
'container_class'
]))
{
if
(
empty
(
$attributes
[
'container_class'
][
'label'
]))
{
$attributes
[
'container_class'
][
'label'
]
=
'Container class(es)'
;
}
if
(
empty
(
$attributes
[
'container_class'
][
'description'
]))
{
$attributes
[
'container_class'
][
'description'
]
=
'CSS class for the menu list item (<li>). Separate multiple classes by space.'
;
}
}
// Only set if still existing in custom config:
Loading