Commit 7b45f779 authored by Martin Leblanc's avatar Martin Leblanc
Browse files

additional css for the sub-menu alignment, removed the menu-item count as...

additional css for the sub-menu alignment, removed the menu-item count as logic no longer needed, refined css for phone view of menu items
parent 22c4848c
......@@ -8299,6 +8299,9 @@ fieldset .fieldset-wrapper .webform-container-inline .fieldset-invisible,
text-transform: none;
width: 100%;
}
.uw-horizontal-nav--menu .menu .submenu-active[aria-expanded="true"] > a::after {
transform: scale(0.75, 0.75) rotate(-90deg);
}
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav {
background: #f7f7f7;
display: block;
......@@ -8338,12 +8341,12 @@ fieldset .fieldset-wrapper .webform-container-inline .fieldset-invisible,
column-count: 2;
-moz-column-fill: balance;
column-fill: balance;
-moz-column-gap: 20px;
column-gap: 20px;
-moz-column-gap: 2rem;
column-gap: 2rem;
height: auto;
left: 3rem;
overflow-y: inherit;
padding: 1.5rem 0.75rem;
padding: 0 16px 24px 16px;
top: 100%;
width: calc(100% - 6rem);
z-index: 7;
......@@ -8376,7 +8379,7 @@ fieldset .fieldset-wrapper .webform-container-inline .fieldset-invisible,
}
@media (min-width: 48.06rem) {
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item a {
padding: 8px;
padding: 8px 8px 8px 0;
} }
.no-scroll .uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item__parent {
border-bottom: 1px solid #e6e6e6;
......@@ -8393,17 +8396,14 @@ fieldset .fieldset-wrapper .webform-container-inline .fieldset-invisible,
.no-scroll .uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item .menu--item .menu--item a {
font-family: Typ1451-Regular,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Oxygen-Sans", Ubuntu, Cantarell, "Fira Sans", Droid Sans, sans-serif;
font-weight: 200;
padding-left: 32px;
}
.no-scroll .uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item .menu--item .menu--item .menu--item a {
font-family: Typ1451-Regular,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Oxygen-Sans", Ubuntu, Cantarell, "Fira Sans", Droid Sans, sans-serif;
font-weight: 200;
padding-left: 56px;
}
@media (min-width: 48.06rem) {
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item {
height: auto;
padding-left: 8px;
width: 100%;
}
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item .menu--item {
......@@ -8411,7 +8411,7 @@ fieldset .fieldset-wrapper .webform-container-inline .fieldset-invisible,
font-weight: 200;
margin-top: inherit;
max-width: inherit;
padding-left: 16px;
padding-left: 0.5rem;
}
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item .menu--item a {
font-family: Typ1451-Regular,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Oxygen-Sans", Ubuntu, Cantarell, "Fira Sans", Droid Sans, sans-serif;
......@@ -8419,7 +8419,7 @@ fieldset .fieldset-wrapper .webform-container-inline .fieldset-invisible,
}
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item .menu--item .menu--item {
margin-top: inherit;
padding-left: 16px;
padding-left: 0.5rem;
}
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item .menu--item .menu--item a {
font-family: Typ1451-Regular,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Oxygen-Sans", Ubuntu, Cantarell, "Fira Sans", Droid Sans, sans-serif;
......@@ -8427,18 +8427,13 @@ fieldset .fieldset-wrapper .webform-container-inline .fieldset-invisible,
}
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item .menu--item .menu--item .menu--item {
margin-top: inherit;
padding-left: 16px;
}
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item .menu--item .menu--item .menu--item a {
font-family: Typ1451-Regular,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Oxygen-Sans", Ubuntu, Cantarell, "Fira Sans", Droid Sans, sans-serif;
font-weight: 200;
} }
@media (min-width: 63.1875rem) {
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item {
padding-left: 16px;
} }
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item__parent {
padding: 4px 0 4px 8px;
padding: 4px 0 4px 0;
top: 0;
width: 100%;
}
......@@ -8462,8 +8457,7 @@ fieldset .fieldset-wrapper .webform-container-inline .fieldset-invisible,
-moz-column-span: all;
column-span: all;
max-width: inherit !important;
padding: 8px 0 8px 16px;
width: 100%;
padding: 8px 0 8px 0;
}
.uw-horizontal-nav--menu .menu .submenu-active .menu--subnav .menu--item__parent .menu--link-parent {
font-size: 0.88889rem;
......
This source diff could not be displayed because it is too large. You can view the blob instead.
/**
* @file
* Ckeditor Modal.
*/
(function ($, Drupal) {
if ($.ui && $.ui.dialog) {
orig_allowInteraction = $.ui.dialog.prototype._allowInteraction;
$.ui.dialog.prototype._allowInteraction = function (event) {
if ($(event.target).closest('.cke_dialog').length) {
return true;
}
return orig_allowInteraction.apply(this, arguments);
};
}
})(jQuery, Drupal);
/**
* @file
*/
......@@ -373,23 +390,6 @@ else {
};
})(jQuery);
/**
* @file
* Ckeditor Modal.
*/
(function ($, Drupal) {
if ($.ui && $.ui.dialog) {
orig_allowInteraction = $.ui.dialog.prototype._allowInteraction;
$.ui.dialog.prototype._allowInteraction = function (event) {
if ($(event.target).closest('.cke_dialog').length) {
return true;
}
return orig_allowInteraction.apply(this, arguments);
};
}
})(jQuery, Drupal);
/**
* @file
*/
......
......@@ -511,4 +511,4 @@ $gesso: (
xxl: 96px,
),
gutter-width: 40px,
);
\ No newline at end of file
);
......@@ -328,9 +328,14 @@ $faculties: 'org-default', 'org-ahs', 'org-art', 'org-eng', 'org-env', 'org-mat'
text-transform: none;
width:100%;
}
.submenu-active {
&[aria-expanded="true"]{
> a{
&::after {
transform: scale(0.75, 0.75) rotate(-90deg);
}
}
}
.menu--subnav{
background: $menu-horizontal-drop-bg;
display:block;
......@@ -365,11 +370,11 @@ $faculties: 'org-default', 'org-ahs', 'org-art', 'org-eng', 'org-env', 'org-mat'
break-inside:avoid;
column-count: 2;
column-fill: balance;
column-gap: 20px;
column-gap: $grid-gap;
height: auto;
left: 3rem;
overflow-y:inherit;
padding:1.5rem 0.75rem;
padding: 0 gesso-spacing(sm) gesso-spacing(md) gesso-spacing(sm);
top: 100%;
width:calc(100% - 6rem);
// Puts the dropdown at z-index 7
......@@ -397,8 +402,7 @@ $faculties: 'org-default', 'org-ahs', 'org-art', 'org-eng', 'org-env', 'org-mat'
border-bottom:1px solid #e6e6e6;
}
@include medium{
padding:gesso-spacing(xs);
padding:gesso-spacing(xs) gesso-spacing(xs) gesso-spacing(xs) 0;
}
}
.no-scroll & {
......@@ -422,13 +426,11 @@ $faculties: 'org-default', 'org-ahs', 'org-art', 'org-eng', 'org-env', 'org-mat'
a {
font-family:$menu-horizontal-sub-font;
font-weight:200;
padding-left: gesso-spacing(lg);
}
.menu--item {
a {
font-family:$menu-horizontal-sub-font;
font-weight:200;
padding-left: gesso-spacing(xl);
}
}
}
......@@ -436,23 +438,23 @@ $faculties: 'org-default', 'org-ahs', 'org-art', 'org-eng', 'org-env', 'org-mat'
}
@include medium {
height:auto;
padding-left: gesso-spacing(xs);
width:100%;
.menu--item{
font-family:$menu-horizontal-sub-font;
font-weight:200;
margin-top:inherit;
max-width:inherit;
padding-left: gesso-spacing(sm);
padding-left: 0.5rem;
a{
font-family:$menu-horizontal-sub-font;
padding:gesso-spacing(xxs);
}
.menu--item{
margin-top:inherit;
padding-left: gesso-spacing(sm);
padding-left: 0.5rem;
a{
font-family:$menu-horizontal-sub-font;
font-weight:200;
......@@ -460,7 +462,7 @@ $faculties: 'org-default', 'org-ahs', 'org-art', 'org-eng', 'org-env', 'org-mat'
.menu--item{
margin-top:inherit;
padding-left: gesso-spacing(sm);
a{
font-family:$menu-horizontal-sub-font;
font-weight:200;
......@@ -468,14 +470,14 @@ $faculties: 'org-default', 'org-ahs', 'org-art', 'org-eng', 'org-env', 'org-mat'
}
}
}
}
@include large {
padding-left: gesso-spacing(sm);
}
&__parent{
padding:gesso-spacing(xxs) 0 gesso-spacing(xxs) gesso-spacing(xs);
padding:gesso-spacing(xxs) 0 gesso-spacing(xxs) 0;
top:0;
width:100%;
.menu--link-parent {
display:inline-block;
position:relative;
......@@ -489,15 +491,12 @@ $faculties: 'org-default', 'org-ahs', 'org-art', 'org-eng', 'org-env', 'org-mat'
right:0;
text-align: center;
top:gesso-spacing(xs);
}
}
@include medium {
column-span: all;
max-width:inherit !important;
padding:gesso-spacing(xs) 0 gesso-spacing(xs) gesso-spacing(sm);
width:100%;
padding:gesso-spacing(xs) 0 gesso-spacing(xs) 0;
.menu--link-parent {
font-size:rem(gesso-font-size(-1));
margin:0 0 gesso-spacing(xxs) 0;
......@@ -507,11 +506,7 @@ $faculties: 'org-default', 'org-ahs', 'org-art', 'org-eng', 'org-env', 'org-mat'
}
}
top:0;
width:100%;
}
}
}
}
......
......@@ -61,33 +61,9 @@
{# Check if we are in parent menu_level #}
{% if menu_level == 0 %}
{# Look to see if the menu_items_count is set so and use for menu dropdown class #}
{% if item.menu_items_count %}
{% if item.menu_items_count >= 40 %}
{% set item_classes = item_classes|merge(['has-submenu--xlarge']) %}
{% elseif item.menu_items_count >= 25 %}
{% set item_classes = item_classes|merge(['has-submenu--large']) %}
{% elseif item.menu_items_count >= 9 %}
{% set item_classes = item_classes|merge(['has-submenu--medium']) %}
{% elseif item.menu_items_count > 0 %}
{% set item_classes = item_classes|merge(['has-submenu--small']) %}
{% endif %}
{# Add the link class #}
{% set link_classes = link_classes|merge(['menu--link__sub']) %}
{% endif %}
{% endif %}
{% if menu_level == 1 %}
{% set item_classes = item_classes|merge(['sub-1']) %}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment