/**
 * @license
 * Copyright Akveo. All Rights Reserved.
 * Licensed under the MIT License. See License.txt in the project root for license information.
 */

@use '../../theme/styles/theming' as *;
@use 'status-buttons';

@mixin b-btn-outline($status) {
  background-color: nb-theme(button-outline-#{$status}-background-color);
  border-style: nb-theme(button-outline-border-style);
  border-width: nb-theme(button-outline-border-width);
  text-transform: nb-theme(button-outline-text-transform);
  border-color: nb-theme(button-outline-#{$status}-border-color);
  color: nb-theme(button-outline-#{$status}-text-color);

  &:focus {
    background-color: nb-theme(button-outline-#{$status}-background-color);
    border-color: nb-theme(button-outline-#{$status}-focus-border-color);
    color: nb-theme(button-outline-#{$status}-focus-text-color);
  }

  &:hover {
    background-color: nb-theme(button-outline-#{$status}-background-color);
    border-color: nb-theme(button-outline-#{$status}-hover-border-color);
    color: nb-theme(button-outline-#{$status}-hover-text-color);
  }

  &:active {
    background-color: nb-theme(button-outline-#{$status}-background-color);
    border-color: nb-theme(button-outline-#{$status}-active-border-color);
    color: nb-theme(button-outline-#{$status}-active-text-color);
  }

  &[disabled] {
    background-color: nb-theme(button-outline-#{$status}-disabled-background-color);
    border-color: nb-theme(button-outline-#{$status}-disabled-border-color);
    color: nb-theme(button-outline-#{$status}-disabled-text-color);
  }
}

@mixin b-btn-outlines() {
  .btn.btn-outline-primary {
    @include b-btn-outline(primary);
  }

  .btn.btn-outline-warning {
    @include b-btn-outline(warning);
  }

  .btn.btn-outline-success {
    @include b-btn-outline(success);
  }

  .btn.btn-outline-info {
    @include b-btn-outline(info);
  }

  .btn.btn-outline-danger {
    @include b-btn-outline(danger);
  }
}
