<commit_before>@import 'element'
@import 'functions'

// All button-like elements should extend this to work
// with e.g. button groups
%m-button
  box-sizing: border-box
  display: inline-block
  margin-bottom: 0

  font-size: inherit
  font-weight: inherit
  font-family: inherit
  line-height: inherit
  white-space: nowrap

  text-align: center
  vertical-align: middle
  touch-action: manipulation

  cursor: pointer
  background-image: none
  user-select: none

  border: 1px solid transparent
  border-radius: 2px

  &, &:hover, &:focus, &.focus
    text-decoration: none

  &:active, &.active
    outline: 0
    background-image: none
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .2)

  &[disabled], &.disabled, fieldset[disabled] &
    cursor: default
    pointer-events: none
    opacity: .65
    box-shadow: none

  &::-moz-focus-inner
    border: 0
    padding: 0

@mixin m-button
  @extend %m-button
  @extend %m-element

@mixin m-button-variant($color, $text, $border: rgba(0, 0, 0, .2), $focus: rgba(0, 0, 0, .8), $outline: false)
  color: $text

  @if lightness($text) < 40%
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.3)
  @else
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.3)

  border-color: $border
  background-color: $color
  background-image: linear-gradient(lighten($color, 2%), darken($color, 4%))

  transition: border-color, box-shadow .2s

  &:hover
    color: $text
    text-decoration: none
    border-color: darken($border, 8%)
    background-color: darken($color, 4%)
    background-image: linear-gradient(lighten($color, 2%), darken($color, 8%))

  &:active, &.active
    border-color: darken($border, 8%)
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .2)
    background-image: none
    background-color: $color

  &:focus, &.focus
    @if $outline
      outline: 1px solid $focus
      outline-offset: -2px
    @else
      border-color: $focus
      outline: none

  &[disabled]
    &:hover, &:focus, &:active, &.focus, &.active, &
      background-color: $color
      background-image: none
      border-color: $border
      box-shadow: none
      opacity: .6<commit_msg>Fix issue with short flash of outline on button<commit_after>@import 'element'
@import 'functions'

// All button-like elements should extend this to work
// with e.g. button groups
%m-button
  box-sizing: border-box
  display: inline-block
  margin-bottom: 0

  font-size: inherit
  font-weight: inherit
  font-family: inherit
  line-height: inherit
  white-space: nowrap

  text-align: center
  vertical-align: middle
  touch-action: manipulation

  cursor: pointer
  background-image: none
  user-select: none

  border: 1px solid transparent
  border-radius: 2px

  &, &:hover, &:focus, &.focus
    text-decoration: none

  &:active, &.active
    background-image: none
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .2)

  &[disabled], &.disabled, fieldset[disabled] &
    cursor: default
    pointer-events: none
    opacity: .65
    box-shadow: none

  &::-moz-focus-inner
    border: 0
    padding: 0

@mixin m-button
  @extend %m-button
  @extend %m-element

@mixin m-button-variant($color, $text, $border: rgba(0, 0, 0, .2), $focus: rgba(0, 0, 0, .8), $outline: false)
  color: $text

  @if lightness($text) < 40%
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.3)
  @else
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.3)

  border-color: $border
  background-color: $color
  background-image: linear-gradient(lighten($color, 2%), darken($color, 4%))

  outline: 1px solid transparent
  outline-offset: -2px
  transition: border-color .2s, box-shadow .2s, outline-color .2s

  &:hover
    color: $text
    text-decoration: none
    border-color: darken($border, 8%)
    background-color: darken($color, 4%)
    background-image: linear-gradient(lighten($color, 2%), darken($color, 8%))

  &:active, &.active
    border-color: darken($border, 8%)
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .2)
    background-image: none
    background-color: $color

  &:focus, &.focus
    @if $outline
      outline-width: 1px
      outline-color: $focus
    @else
      border-color: $focus

  &[disabled]
    &:hover, &:focus, &:active, &.focus, &.active, &
      background-color: $color
      background-image: none
      border-color: $border
      box-shadow: none
      opacity: .6
{'fraction_non_alphanumeric': 0.14145658263305322, 'fraction_numerical': 0.03081232492997199, 'mean_word_length': 3.053926206244087, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6161791', 'n_tokens_mistral': 1650, 'n_tokens_neox': 1489, 'n_words': 426}