Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
P
ptd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Quan Nguyen
ptd
Commits
ddabc481
Commit
ddabc481
authored
May 08, 2020
by
root
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://gitlab.invigroup.com/quan.nguyen/ptd
parents
9df995cb
e0076f8b
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
153 additions
and
42 deletions
+153
-42
menu.html.twig
themes/contrib/bootstrap/templates/menu/menu.html.twig
+15
-8
styles.css
themes/contrib/estore/css/styles.css
+135
-34
custom.js
themes/contrib/estore/js/custom.js
+3
-0
No files found.
themes/contrib/bootstrap/templates/menu/menu.html.twig
View file @
ddabc481
...
...
@@ -21,11 +21,17 @@
#}
{%
macro
menu_links
(
items
,
attributes
,
menu_level
,
classes
,
dropdown_classes
)
%}
{%
if
items
%}
<ul
{{
attributes.addClass
(
menu_level
==
0
?
classes
:
dropdown_classes
)
}}
>
{%
set
menu_classes
=
[
'sidebar'
~
menu_name
|
clean_class
]
%}
{%
set
submenu_classes
=
[
'sidebar'
~
menu_name
|
clean_class
~
'-submenu'
,
'sidebar-submenu-'
~
(
menu_level
+
1
),]
%}
{%
if
menu_level
==
0
%}
<ul
{{
attributes.addClass
(
classes
)
}}
>
{%
else
%}
<ul
{{
attributes.removeClass
(
menu_classes
,
'sidebar-submenu-'
~
(
menu_level
))
.
addClass
(
submenu_classes
,
"dropdown-menu"
)
}}
>
{%
endif
%}
{%
for
item
in
items
%}
{%
set
item_classes
=
item.url.getOption
(
'container_attributes'
)
.
class
|
split
(
" "
)
%}
{%
set
item_classes
=
item.url.getOption
(
'container_attributes'
)
.
class
|
split
(
" "
)
%}
{%
set
item_classes
=
[
item.is_expanded
and
item.below
?
'expanded dropdown'
,
...
...
@@ -38,7 +44,8 @@
{%
set
link_title
=
item.title
%}
{%
set
link_attributes
=
item.link_attributes
%}
{%
if
menu_level
==
0
and
item.is_expanded
and
item.below
%}
{%
set
link_title
%}{{
link_title
}}
<i
class=
"fa fa-chevron-right"
aria-hidden=
"true"
></i>
{%
endset
%}
{%
set
link_title
%}{{
link_title
}}
<i
class=
"fa fa-chevron-right"
aria-hidden=
"true"
></i>
{%
endset
%}
{%
set
link_attributes
=
link_attributes.addClass
(
'dropdown-toggle'
)
.
setAttribute
(
'data-toggle'
,
'dropdown'
)
%}
{%
endif
%}
{# Must use link() here so it triggers hook_link_alter(). #}
...
...
@@ -50,11 +57,11 @@
{%
endfor
%}
</ul>
{%
endif
%}
{%
endmacro
%}
{%
endmacro
%}
{#
{#
Invoke the custom macro defined above. If classes were provided, use them.
This allows the template to be extended without having to also duplicate the
code above. @see http://twig.sensiolabs.org/doc/tags/macro.html
#}
{{
_self.menu_links
(
items
,
attributes
,
0
,
classes
?:
[
'menu'
,
'menu--'
~
menu_name
|
clean_class
,
'nav'
],
dropdown_classes
?:
[
'dropdown-menu'
])
}}
{{
_self.menu_links
(
items
,
attributes
,
0
,
classes
?:
[
'menu'
,
'menu--'
~
menu_name
|
clean_class
,
'nav'
],
dropdown_classes
?:
[
'dropdown-menu'
])
}}
themes/contrib/estore/css/styles.css
View file @
ddabc481
...
...
@@ -21,20 +21,105 @@ body {
}
/* invi custom */
.region-footer-fourth
.view-content
{
.menu--main
.open
ul
.sidebar-submenu-2
li
:hover
{
background
:
white
!important
;
}
.menu--main
.open
ul
.sidebar-submenu-2
li
{
border-bottom
:
none
!important
;
width
:
170px
!important
}
.menu--main
.open
ul
.sidebar-submenu-2.three-level
{
flex-direction
:
row
!important
;
}
.menu--main
.open
ul
.sidebar-submenu-2
li
a
{
white-space
:
normal
;
padding
:
0
5px
;
line-height
:
normal
!important
;
text-align
:
left
!important
;
text-transform
:
none
!important
;
}
.menu--main
.open
ul
.sidebar-submenu-2
{
padding
:
26px
20px
!important
;
}
.menu--main
.open
ul
.sidebar-submenu-2.sidebar-submenu-3
li
{
padding
:
7px
0
}
/* .menu--main .open ul.sidebar-submenu-2 ul.slidebar-submenu-3 {
display: flex;
flex-direction: column !important;
} */
.menu--main
.open
.dropdown-menu
{
/* menu lv2 */
display
:
flex
;
flex-direction
:
column
;
justify-content
:
flex-start
;
top
:
98%
;
left
:
-2px
;
/* width: 73%; */
/* text-align: center; */
background
:
white
!important
;
/* height: 169%; */
}
.region-footer-fourth
.view-content
.img-responsive
{
width
:
42px
;
height
:
42px
;
margin-right
:
5px
;
border-radius
:
9px
;
.menu--main
.open
.dropdown-menu
li
{
width
:
100%
;
}
header
.navbar
.category-menu
ul
.menu
ul
.dropdown-menu
li
{
/* border: none; */
font-weight
:
200
!important
;
padding
:
5px
0px
;
.menu--main
.open
.dropdown-menu.three-level
li
a
{
font-weight
:
600
!important
;
}
.menu--main
.open
.dropdown-menu.three-level
.sidebar-submenu-3
li
a
{
font-weight
:
normal
!important
;
padding
:
6px
0
;
}
.menu--main
.open
.dropdown-menu
li
a
{
font-weight
:
normal
;
}
.menu--main
.open
.dropdown-menu
.dropdown-menu.sidebar-submenu-3
{
margin-top
:
10px
}
.menu--main
.open
.dropdown-menu
.dropdown-menu
{
/* menulv 3 */
display
:
flex
;
flex-direction
:
column
;
justify-content
:
flex-start
;
top
:
5px
;
/* height: 102%; */
border
:
none
;
left
:
0
;
position
:
relative
;
}
.menu--main
.open
.dropdown-menu
.dropdown-menu
li
{
/* menulv 3 */
/* padding: 5px 10px; */
font-weight
:
200
;
}
.menu--main
.open
.dropdown-menu
.dropdown-menu
li
a
{
/* menulv 3 */
font-weight
:
500
;
}
.menu--main
.open
.dropdown-menu
li
{
color
:
red
}
/* end custom */
.menu--category-menu
.open
ul
.sidebar-submenu-2
li
:hover
{
background
:
white
!important
;
}
.menu--category-menu
.open
ul
.sidebar-submenu-2
li
{
border-bottom
:
none
!important
;
width
:
170px
!important
}
.menu--category-menu
.open
ul
.sidebar-submenu-2.three-level
{
flex-direction
:
row
!important
;
}
.menu--category-menu
.open
ul
.sidebar-submenu-2
li
a
{
white-space
:
normal
;
padding
:
0
5px
;
}
.menu--category-menu
.open
ul
.sidebar-submenu-2
{
padding
:
10px
5px
20px
!important
;
}
/* .menu--category-menu .open ul.sidebar-submenu-2 ul.slidebar-submenu-3 {
display: flex;
flex-direction: column !important;
} */
.menu--category-menu
.open
.dropdown-menu
{
/* menu lv2 */
display
:
flex
;
flex-direction
:
column
;
...
...
@@ -49,9 +134,14 @@ header.navbar .category-menu ul.menu ul.dropdown-menu li{
.menu--category-menu
.open
.dropdown-menu
li
{
width
:
100%
;
}
.menu--category-menu
.open
.dropdown-menu.three-level
li
a
{
font-weight
:
600
!important
;
}
.menu--category-menu
.open
.dropdown-menu.three-level
.sidebar-submenu-3
li
a
{
font-weight
:
normal
!important
;
}
.menu--category-menu
.open
.dropdown-menu
li
a
{
font-weight
:
600
;
font-weight
:
normal
;
}
.menu--category-menu
.open
.dropdown-menu
.dropdown-menu
{
/* menulv 3 */
display
:
flex
;
...
...
@@ -75,6 +165,33 @@ header.navbar .category-menu ul.menu ul.dropdown-menu li{
color
:
red
}
.menu--category-menu
.dropdown-toggle
i
{
font-size
:
14px
;
font-weight
:
300
;
top
:
15px
;
position
:
absolute
;
right
:
15px
;
}
.region-footer-fourth
.view-content
{
display
:
flex
;
}
.contact_text
{
margin-top
:
12px
}
.region-footer-fourth
.view-content
.img-responsive
{
width
:
35px
;
height
:
35px
;
margin-right
:
7px
;
margin-top
:
14px
;
border-radius
:
9px
;
}
header
.navbar
.category-menu
ul
.menu
ul
.dropdown-menu
li
{
/* border: none; */
font-weight
:
200
!important
;
padding
:
5px
0px
;
}
.pin_be
.navbar-nav
>
li
.open
>
.dropdown-menu
{
display
:
flex
;
flex-direction
:
column
;
...
...
@@ -85,13 +202,7 @@ header.navbar .category-menu ul.menu ul.dropdown-menu li{
.pin_be
.navbar-nav
>
li
>
.dropdown-menu
li
{
margin-left
:
0
!important
}
header
.navbar
.main-menu
ul
.menu
li
.open
ul
a
{
font-weight
:
400
;
display
:
block
;
line-height
:
32px
;
text-transform
:
capitalize
;
font-size
:
13px
;
}
.middle-header-wrapper
.container-fluid.fixed-top.no-toolbar
{
top
:
0
}
...
...
@@ -165,15 +276,7 @@ header.navbar .category-menu ul.menu.litte-menu {
}
}
.menu--category-menu
.dropdown-toggle
i
{
font-size
:
14px
;
font-weight
:
300
;
/* color: blue; */
/* float: right; */
top
:
15px
;
position
:
absolute
;
right
:
15px
;
}
/* .top-region{
background: white;
}
...
...
@@ -506,7 +609,7 @@ header.navbar .category-menu .block-title i {
header
.navbar
.block-search-navigation
.search-icon
{
display
:
none
;
}
}
.region-footer-fourth
.view-content
.img-responsive
@media
(
min-width
:
768px
)
and
(
max-width
:
991px
)
{
header
.navbar
div
.block-search-navigation
{
...
...
@@ -10300,8 +10403,8 @@ header.navbar .main-menu ul.menu li a {
padding
:
0
;
text-transform
:
uppercase
;
color
:
#333
;
line-height
:
inherit
;
text-align
:
right
;
line-height
:
inherit
;
white-space
:
nowrap
;
}
header
.navbar
.main-menu
ul
.menu
li
a
i
{
...
...
@@ -10364,9 +10467,7 @@ header.navbar .block-search-navigation .search-icon.active {
}
.header-region
{
margin-bottom
:
70px
;
padding
:
20px
0
10px
;
background-color
:
#f6f7f7
;
padding
:
10px
0
10px
;
}
.header-region
h1
{
...
...
@@ -10391,7 +10492,7 @@ header.navbar .block-search-navigation .search-icon.active {
}
.header-region
.breadcrumb
>
li
.active
{
color
:
#
66
6
;
color
:
#
c4031
6
;
}
.region-sidebar-first
.block-title
,
...
...
themes/contrib/estore/js/custom.js
View file @
ddabc481
...
...
@@ -72,5 +72,8 @@
$
(
".dropdown-toggle"
).
mouseleave
(
function
(){
$
(
this
).
parent
(
"li.expanded.dropdown"
).
removeClass
(
"open"
);
})
console
.
log
(
$
(
".sidebar-submenu-2"
).
find
(
".sidebar-submenu-3"
).
parents
(
".sidebar-submenu-2"
));
$
(
".sidebar-submenu-2"
).
find
(
".sidebar-submenu-3"
).
parents
(
".sidebar-submenu-2"
).
addClass
(
"three-level"
);
})(
window
.
jQuery
,
window
.
Drupal
);
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