layout

notifications   

Copy
Edit
<!-- components/layout/notifications.html --> <div class="help-center help-center--notifications"> <div class="dropdown"> <span data-toggle="popover" data-placement="bottom" title="Notifications"> <span class="help-center__icon theme-tooltip theme-tooltip-dark" id="dropdownMenu1" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true"> <span class="icomoon-bell dropdown-toggle"></span> </span> </span> <div class="dropdown-menu dropdown-menu--right" aria-labelledby="dropdownMenu1"> <div class="dropdown-menu__header"> <span>Notifications</span> <span class="icomoon-x"></span> </div> <div class="help-center__body"> <div class="help-center__body__resources"> <div class="resources__links"> <a href="#"> <div class="resources__links__container"> <span class="resources__links__icon"> <span class="icomoon-bell"></span> </span> <div class="links__captions"> <h4>Robert Fox</h4> <p>Removing all users has unpublished this project. Add users to republish.</p> <span class="links__captions__time">2m ago</span> </div> </div> </a> <a href="#"> <div class="resources__links__container"> <span class="resources__links__icon"> <span class="icomoon-bell"></span> </span> <div class="links__captions"> <h4>Robert Fox</h4> <p>Removing all users has unpublished this project. Add users to republish.</p> <span class="links__captions__time">2m ago</span> </div> </div> </a> </div> </div> </div> </div> </div> </div>
Copy
Copy
Edit
/* scss/layout/_notifications.scss */

help-center   

Note: if you remove blogs section add class (help-center__body--without-blogs) to the (help-center__body)

Copy
Edit
<!-- components/layout/help-center.html --> <div class="help-center"> <div class="dropdown"> <button class="help-center__icon" id="help_center_dropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true"> <i class="icomoon-help-circle dropdown-toggle" ></i> </button> <div class="dropdown-menu dropdown-menu--right" aria-labelledby="help_center_dropdown"> <div class="dropdown-menu__header"> <span>Help center</span> <span class="icomoon-x"></span> </div> <div class="help-center__body"> <div class="help-center__body__resources"> <span class="body__header">Resources</span> <div class="resources__links"> <a href="#"> <div class="resources__links__container"> <span class="resources__links__icon"> <span class="icomoon-file"></span> </span> <div class="links__captions"> <h4>Documentation</h4> <p>Need assistance? Explore our features</p> </div> </div> </a> <a href="#"> <div class="resources__links__container"> <span class="resources__links__icon"> <span class="icomoon-video"></span> </span> <div class="links__captions"> <h4>Webinars</h4> <p>Save your spots at a live trainig events</p> </div> </div> </a> <a href="#"> <div class="resources__links__container"> <span class="resources__links__icon"> <span class="icomoon-send"></span> </span> <div class="links__captions"> <h4>Suggest features </h4> <p>add what help your business growth</p> </div> </div> </a> <a href="#"> <div class="resources__links__container"> <span class="resources__links__icon"> <span class="icomoon-message-circle"></span> </span> <div class="links__captions"> <h4>Report a bug</h4> <p>Have problem? Send us please!</p> </div> </div> </a> </div> </div> <div class="help-center__body__blogs"> <span class="body__header">Latest blog posts</span> <a href="#"> <div class="resources__links__container"> <div class="blogs__thumbnail"> </div> <div class="links__captions"> <h4>Auto-layout explained</h4> <p>Jump right in — get an overview of the basics and...</p> </div> </div> </a> <a href="#"> <div class="resources__links__container"> <div class="blogs__thumbnail"> </div> <div class="links__captions"> <h4>Top techniques to level up your product design</h4> <p>The latest best practices and techniques to level up...</p> </div> </div> </a> <a href="#"> <div class="resources__links__container"> <div class="blogs__thumbnail"> </div> <div class="links__captions"> <h4>Sythesize data like a pro through affinity diagramming</h4> <p>Synthesis is the mysterious...</p> </div> </div> </a> <a href="#" class="help-center__body__blogs__link">All blogs posts <span class="icomoon-arrow-right"></span></a> </div> </div> </div> </div> </div>
Copy
Copy
Edit
/* scss/layout/_help-center.scss */ .help-center{ text-align: $end; .dropdown{ display: inline-block; &.open .help-center__icon { color: $primary-700 !important; background-color: $primary-50; &:hover:not(:focus) { background: $primary-100; } } .help-center__icon { padding: 0; background-color: transparent; line-height: 40px; height: 40px; width: 40px; display: flex; align-items: center; justify-content: center; border-radius: 6px; color: $gray-500; border: 4px solid transparent; position: relative; transition: .3s; font-size: 24px; cursor: pointer; &:hover:not(:focus) { color: $primary-700; background: $primary-50; } &:focus { color: $gray-500; border: 4px solid $primary-100; } &.active { &::before { content: ""; display: block; position: absolute; top: 1px; right: 5px; width: 13px; height: 13px; border-radius: 50%; border: 2px solid #fff; background-color: $error-500; } } i { font-size: 24px; } } } .dropdown-menu{ width: 769px; padding: 20px; padding-bottom: 10px; border-radius: 8px; box-shadow: 0px 12px 16px -4px #1018281a, 0px 4px 6px -2px #1018280d; border: 1px solid $gray-200; .dropdown-menu__header{ font-size: 18px; font-weight: 500; color: $gray-900; text-transform: capitalize; padding-bottom: 15px; margin-bottom: 20px; border-bottom: 1px solid $gray-100; .icomoon-x{ display: none; } } &.dropdown-menu--right{ #{$end}: 0; #{$start}: auto; overflow-y: hidden; } .help-center__body{ display: flex; .body__header{ font-size: 14px; color: $primary-600; font-weight: 500; margin-bottom: 16px; display: inline-block; } a{ color: unset; display: block; margin-bottom: 23px; .resources__links__container { display: flex; .resources__links__icon{ font-size: 20px; color: $primary-600; margin-#{$end}: 16px; span{ } } .blogs__thumbnail{ width: 144px; height: 80px; background: #E4E7EC; border-radius: 6px; } } .links__captions{ h4{ color: $gray-900; font-weight: 500; font-size: 16px; text-transform: capitalize; line-height: 24px; text-align: $start; } p{ color: $gray-500; font-size: 14px; line-height: 20px; text-align: $start; } } } .help-center__body__resources{ padding: 0 15px; .resources__links{ } } .help-center__body__blogs{ padding-#{$start}: 24px; position: relative; a{ margin-bottom: 8px; } &::before{ content: ''; width: 1px; height: calc(100% + 30px); #{$start}: 0; background-color: $gray-100; position: absolute; top: -20px; } .resources__links__container{ padding: 12px; padding-#{$end}: 0; } .body__header{ padding-#{$start}: 12px; } .links__captions{ margin-#{$start}: 20px; width: 55%; } .help-center__body__blogs__link{ padding-#{$start}: 12px; color: $primary-500; display: flex; align-items: center; font-weight: 500; font-size: 14px; .icomoon-arrow-right{ margin-#{$start}: 12px; @if $start != 'left'{ transform: rotateY(180deg); } } } } &:not(.help-center__body--without-blogs){ .help-center__body__resources{ width: 68%; } } &.help-center__body--without-blogs{ flex-direction: column; } } } &.help-center--notifications{ .dropdown-menu{ width: 448px; padding-top: 15px; max-height: 695px; overflow-y: auto; .help-center__body { .help-center__body__resources{ width: 100%; padding: 0; } a{ padding: 15px; transition: .3s; margin-bottom: 8px; border-radius: 7px; &:hover{ background: #F1F5FE; } .resources__links__container { .resources__links__icon{ > span { font-size: 13px; width: 32px; cursor: pointer; height: 32px; display: inline-flex; align-items: center; background: #E3EBFC; justify-content: center; border-radius: 50%; color: inherit; } } } .links__captions{ h4{ margin-bottom: 3px; } p{ font-size: 16px; line-height: 24px; padding-bottom: 11px; } .links__captions__time{ font-size: 14px; color: #98A2B3; } } } } } } } @include smScreen { .help-center{ .dropdown{ position: static; .dropdown-menu{ position: fixed; top: 0; left: 0; width: 100%; padding: 0; border-radius: 0; border: none; box-shadow: none; overflow-y: scroll; height: 100%; .dropdown-menu__header{ display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; .icomoon-x{ display: block; } } .help-center__body{ flex-direction: column; .help-center__body__resources{ width: 100%; .resources__links{ padding-bottom: 12px; } } .help-center__body__blogs{ .body__header{ margin-top: 24px; margin-bottom: 10px; } &::before{ width: 100%; height: 1px; top: 0; } padding-#{$start}: 0; .resources__links__container{ padding-#{$end}: 12px; flex-direction: column; .blogs__thumbnail{ height: 118px; width: 100%; margin-bottom: 20px; } .links__captions{ width: 100%; margin-#{$start}: 0; } } } } } } .dropdown-backdrop{ display: none; } .help-center--notifications { .dropdown-menu { .help-center__body { a{ border-radius: 0; } } } } } .hidden-scroll{ overflow: hidden; } aside.atoms-side{ display:none !important; } }
Copy
Edit
/* js/help-center.js */ $(document).ready(function (){ $('.dropdown-menu').on('click', function (event) { event.stopPropagation(); }); $('.icomoon-help-circle , .icomoon-bell').on('click', function (event) { $('body').addClass('hidden-scroll'); }); $('.icomoon-x').on('click', function (event) { $('.help-center__icon').removeClass('open'); $('body').removeClass('hidden-scroll'); }); });