Commit a19a999a3bc50eb62c9f96416702d2538674695e

Authored by Alexey Boroda
2 parents 0ad01ee0 d4a25759

Merge remote-tracking branch 'origin/master'

Showing 2 changed files with 99 additions and 0 deletions   Show diff stats
frontend/web/css/custom.css
... ... @@ -364,4 +364,92 @@ figure.reviews_gallery {
364 364 figure.reviews_gallery{
365 365 width:100%;
366 366 }
  367 +}
  368 +._dropdown-wr{
  369 + cursor:pointer;
  370 +}
  371 +._dropdown-wr.opened>a{
  372 + color: #555555;
  373 + background-color: #9adacd;
  374 + border-top: solid 5px #4fbfa8;
  375 +}
  376 +._dropdown-wr.opened ._dropdown{
  377 + display:block;
  378 +}
  379 +._dropdown{
  380 + display:none;
  381 + padding: 0;
  382 + list-style: none;
  383 + margin: 0;
  384 + position: absolute;
  385 + background-color: #fff;
  386 + z-index: 1;
  387 + left: 0;
  388 + float: left;
  389 + box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.3);
  390 +}
  391 +._dropdown>li{
  392 + min-width: 160px;
  393 + width: max-content;
  394 + max-width: 300px;
  395 + padding: 10px 15px;
  396 + position: relative;
  397 +}
  398 +._dropdown>li ul{
  399 + display: none;
  400 + position: absolute;
  401 + background-color: #fff;
  402 + padding: 0;
  403 + list-style: none;
  404 + float: left;
  405 + left: 100%;
  406 + width: 100%;
  407 + min-width: 160px;
  408 + max-width: max-content;
  409 + top: 0;
  410 + box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.4);
  411 +}
  412 +._dropdown>li ul>li{
  413 + min-width: 160px;
  414 + padding: 10px 15px;
  415 + position:relative;
  416 +}
  417 +._dropdown>li:hover ul{
  418 + display: block;
  419 +}
  420 +._dropdown>li:hover{
  421 + background-color: #70cebb;
  422 + color: #fff;
  423 +}
  424 +._dropdown>li:hover>a{
  425 + color:#fff;
  426 +}
  427 +
  428 +@media (max-width: 767px) {
  429 + ._dropdown-wr ._dropdown{
  430 + float: none;
  431 + position: relative;
  432 + box-shadow: none;
  433 + padding: 0;
  434 + width: 100%;
  435 + }
  436 + ._dropdown-wr ._dropdown>li{
  437 + width: 100%;
  438 + min-width: 100%;
  439 + background: none;
  440 + }
  441 + ._dropdown>li:hover>a{
  442 + color: #4fbfa8;
  443 + }
  444 + ._dropdown>li ul{
  445 + display:block;
  446 + position: relative;
  447 + float: none;
  448 + left: 0;
  449 + width: 100%;
  450 + min-width: 100%;
  451 + background: none;
  452 + box-shadow: none;
  453 + margin-top: 7px;
  454 + }
367 455 }
368 456 \ No newline at end of file
... ...
frontend/web/js/script.js
... ... @@ -161,5 +161,16 @@ $(
161 161 var modaltitle = $(this).data('modalname');
162 162 $(".modal-title").html(modaltitle);
163 163 });
  164 + $("._dropdown-wr .dropdown-toggle")
  165 + .on('click', function(){
  166 + $(this).parent().toggleClass('opened');
  167 + return false;
  168 + });
  169 + $(document).mouseup(function (e) {
  170 + var container = $("._dropdown-wr");
  171 + if (container.has(e.target).length === 0){
  172 + container.removeClass('opened');
  173 + }
  174 + });
164 175 }
165 176 );
166 177 \ No newline at end of file
... ...