tofuness/Toshocat

View on GitHub
src/styles/notification.scss

Summary

Maintainability
Test Coverage
@import '/modular-scale/modular-scale';
@import '/utils/colors';
@import '/utils/reset';
@import '/utils/extend';

* {
    box-sizing: border-box;
}
html, body {
    @extend .roboto;
    @extend .ns;
    cursor: default;
    overflow: hidden;
    width: 100%;
    height: 100%;
    background: transparent;
}
#mount {
    width: 100%;
    height: 100%;
    font-size: 13px;
}
.notification {
    @extend .ts-out;
    opacity: 0;
    color: #000;
    margin: 20px 0 0 20px;
    width: calc(100% - 60px);
    background: transparentize(#8d9fb1, 0.02);
    transform: scale(0.9) translateY(160px);
    border-radius: 4px;
    box-shadow: 0 6px 12px transparentize($winter-black, 0.8);
    &.visible {
        @extend .ts;
        opacity: 1;
        transform: translateY(0);
    }
}
.notification-image {
    overflow: hidden;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 33px;
    opacity: 0.8;
    background-size: cover!important;
    background-position: center center!important;
    border-top-left-radius: 100px;
    border-top-right-radius: 100px;
    z-index: -1;
    -webkit-filter: blur(10px) brightness(90%) contrast(110%);
}
.notification-content {
    @extend .mask;
    overflow: hidden;
    padding: 15px;
}
.notification-legend {
    padding-bottom: 5px;
    color: #fff;
    font-size: ms(0);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.65px;
    line-height: 1;
}
.notification-message {
    color: #fff;
    font-weight: bold;
    letter-spacing: 0.3px;
}
.notification-actions {
    @extend .cf;
}
.notification-action {
    @extend .ts;
    float: left;
    padding: 10px;
    width: 50%;
    font-size: ms(0);
    font-weight: 500;
    letter-spacing: 0.65px;
    text-align: center;
    text-transform: uppercase;
    background: #fff;
    &:hover {
        cursor: pointer;
        background: $dover-gray;
    }
    &:active {
        padding: 11px 10px 9px 10px;
        background: $hoverable-white-hover;
    }
}
.notification-update {
    color: $lapis-blue;
    border-right: 1px solid $border-on-white;
    border-bottom-left-radius: 4px;
}
.notification-cancel {
    color: $cran-red;
    border-bottom-right-radius: 4px;
}