<commit_before>@import 'component';

:host {
  display: inline-block;
}

.dropdown {
  position: relative;
}

.dropdown__trigger {
  display: block;
}

.dropdown__positioner {
  position: absolute;
  z-index: var(--sl-z-index-dropdown);
}

.dropdown__panel {
  max-height: 50vh;
  font-family: var(--sl-font-sans);
  font-size: var(--sl-font-size-medium);
  font-weight: var(--sl-font-weight-normal);
  color: var(--color);
  background-color: var(--sl-panel-background-color);
  border: solid 1px var(--sl-panel-border-color);
  border-radius: var(--sl-border-radius-medium);
  box-shadow: var(--sl-shadow-large);
  opacity: 0;
  overflow: auto;
  overscroll-behavior: none;
  transform: scale(0.9);
  transition: var(--sl-transition-fast) opacity, var(--sl-transition-fast) transform;
}

.dropdown__positioner {
  &[data-popper-placement^='top'] .dropdown__panel {
    transform-origin: bottom;
  }

  &[data-popper-placement^='bottom'] .dropdown__panel {
    transform-origin: top;
  }

  &[data-popper-placement^='left'] .dropdown__panel {
    transform-origin: right;
  }

  &[data-popper-placement^='right'] .dropdown__panel {
    transform-origin: left;
  }

  &.popover-visible .dropdown__panel {
    opacity: 1;
    transform: none;
  }
}<commit_msg>Prevent dropdown trigger from losing focus<commit_after>@import 'component';

:host {
  display: inline-block;
}

.dropdown {
  position: relative;
}

.dropdown__trigger {
  display: block;
}

.dropdown__positioner {
  position: absolute;
  z-index: var(--sl-z-index-dropdown);
}

.dropdown__panel {
  max-height: 50vh;
  font-family: var(--sl-font-sans);
  font-size: var(--sl-font-size-medium);
  font-weight: var(--sl-font-weight-normal);
  color: var(--color);
  background-color: var(--sl-panel-background-color);
  border: solid 1px var(--sl-panel-border-color);
  border-radius: var(--sl-border-radius-medium);
  box-shadow: var(--sl-shadow-large);
  opacity: 0;
  overflow: auto;
  overscroll-behavior: none;
  pointer-events: none;
  transform: scale(0.9);
  transition: var(--sl-transition-fast) opacity, var(--sl-transition-fast) transform;
}

.dropdown__positioner {
  &[data-popper-placement^='top'] .dropdown__panel {
    transform-origin: bottom;
  }

  &[data-popper-placement^='bottom'] .dropdown__panel {
    transform-origin: top;
  }

  &[data-popper-placement^='left'] .dropdown__panel {
    transform-origin: right;
  }

  &[data-popper-placement^='right'] .dropdown__panel {
    transform-origin: left;
  }

  &.popover-visible .dropdown__panel {
    opacity: 1;
    transform: none;
    pointer-events: all;
  }
}
{'fraction_non_alphanumeric': 0.1694915254237288, 'fraction_numerical': 0.00539291217257319, 'mean_word_length': 3.670863309352518, 'pattern_counts': {'":': 0, '<': 3, '<?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': '4610460', 'n_tokens_mistral': 942, 'n_tokens_neox': 919, 'n_words': 155}