Skip to content
Snippets Groups Projects
_button.scss 5.4 KiB
Newer Older
  • Learn to ignore specific revisions
  • .button {
        padding: 0;
        background-color: transparent;
        background-image: none;
        border: 0;
        box-shadow: none;
    
    
        &--primary {
            @include button($color--light-blue, $color--dark-blue);
            display: inline-block;
    
            .form--filters & {
    
                text-align: center;
    
        &:hover {
            cursor: pointer;
        }
    
        &--contains-icons {
            display: flex;
            align-items: center;
    
            .header & {
                margin-right: 20px;
            }
        }
    
        &--transparent {
            @include button(transparent, $color--black);
            @include button--narrow;
            color: $color--black;
            border: 1px solid $color--black;
    
    
            &:focus {
                color: $color--black;
            }
    
    
            &:hover {
                color: $color--white;
            }
        }
    
        &--white {
            @include button($color--white, $color--light-blue);
            display: inline-block;
            color: $color--light-blue;
            border: 1px solid $color--mid-grey;
    
    
            &:focus {
                color: $color--light-blue;
            }
    
    
            &:hover {
                color: $color--white;
            }
        }
    
    
        &--warning {
            @include button($color--error, $color--error);
    
            &:focus {
                background-color: $color--pastel-red;
            }
        }
    
    
        &--filters {
            display: flex;
            justify-content: space-between;
            max-width: 300px;
    
            padding: 15px 20px;
    
            font-weight: $weight--normal;
            color: $color--default;
    
            background: url('./../../images/filters.svg') $color--white no-repeat 93% center;
    
            border: 1px solid $color--light-mid-grey;
    
            @include media-query(tablet-landscape) {
                &::before {
                    content: '';
                    background-image: url('./../../images/filters.svg');
                    transform: rotate(90deg);
                }
    
    
        &--filters-header {
            display: flex;
        }
    
    
        &--search {
            position: absolute;
    
            top: .65em;
    
            right: 10px;
    
            svg {
                fill: $color--primary;
            }
        }
    
    
        &--full-width {
            width: 100%;
            text-align: center;
        }
    
        &--half-width {
            width: 50%;
            padding: 10px 0;
            text-align: center;
    
            &:first-child {
                margin-right: 20px;
            }
        }
    
        &--bottom-space {
            margin-bottom: 10px;
    
            &:last-child {
                margin-bottom: 0;
            }
        }
    
    
        &--actions {
            position: relative;
            display: block;
            background-color: $color--white;
    
            &:active {
                background: $color--light-blue-90;
            }
    
            &::after {
                position: absolute;
                top: 0;
                right: 15px;
                font-size: 30px;
                content: '+';
            }
    
            &.is-active {
                color: $color--dark-blue;
                background: $color--light-blue-90;
    
                &::after {
                    top: -12px;
                    content: '_';
                }
            }
    
            @include media-query(tablet-portrait) {
                display: none;
            }
        }
    
    
        &--top-space {
            margin-top: 20px;
        }
    
    Chris Lawton's avatar
    Chris Lawton committed
            margin-right: 10px;
    
        &--compare {
            width: 75px;
            padding: 3px;
            margin-top: 10px;
            font-size: 12px;
            font-weight: $weight--bold;
            text-align: center;
            text-transform: uppercase;
            border: 1px solid currentColor;
            transition: background-color, color, border, $quick-transition;
    
            @include media-query(tablet-portrait) {
                margin-top: 0;
            }
    
            &:focus,
            &:hover {
                color: $color--white;
                background-color: $color--light-blue;
                border: 1px solid $color--light-blue;
            }
        }
    
    
        &--arrow-pixels-white {
            display: flex;
            align-items: center;
    
            svg {
                width: 10px;
                height: 14px;
                margin-left: 10px;
                fill: $color--white;
            }
        }
    
    
        &--action {
            display: flex;
            font-weight: $weight--normal;
            color: $color--default;
            transition: none;
    
            @include media-query(tablet-landscape) {
                background: none;
    
                border: 0;
                align-items: center;
                justify-content: flex-start;
                width: auto;
                transition: opacity $transition;
    
    Chris Lawton's avatar
    Chris Lawton committed
                opacity: .7;
    
                font-weight: $weight--semibold;
    
                &:hover {
                    opacity: 1;
                }
    
                &::before {
                    content: '';
                    background-image: url('./../../images/filters.svg');
                    background-color: transparent;
                    background-position: left center;
                    background-size: 20px;
                    width: 20px;
                    height: 20px;
                    display: inline-block;
                    margin-right: 10px;
                }
            }
        }
    
    
        &--batch-status {
    
            &::before {
                background-image: url('./../../images/arrow-split.svg');
                transform: rotate(90deg);
            }
        }
    
        &--reviewers {
            &::before {
                background-image: url('./../../images/add-person.svg');
            }
        }