Commit ed7ae583 authored by Kushal Pandya's avatar Kushal Pandya

Merge branch '209207-spinner-appears-to-be-broken' into 'master'

Fix spinner in Create MR dropdown

See merge request gitlab-org/gitlab!26679
parents c9c7e7cb 4cfd6d09
...@@ -42,7 +42,7 @@ export default class CreateMergeRequestDropdown { ...@@ -42,7 +42,7 @@ export default class CreateMergeRequestDropdown {
this.refInput = this.wrapperEl.querySelector('.js-ref'); this.refInput = this.wrapperEl.querySelector('.js-ref');
this.refMessage = this.wrapperEl.querySelector('.js-ref-message'); this.refMessage = this.wrapperEl.querySelector('.js-ref-message');
this.unavailableButton = this.wrapperEl.querySelector('.unavailable'); this.unavailableButton = this.wrapperEl.querySelector('.unavailable');
this.unavailableButtonArrow = this.unavailableButton.querySelector('.spinner'); this.unavailableButtonSpinner = this.unavailableButton.querySelector('.spinner');
this.unavailableButtonText = this.unavailableButton.querySelector('.text'); this.unavailableButtonText = this.unavailableButton.querySelector('.text');
this.branchCreated = false; this.branchCreated = false;
...@@ -417,12 +417,10 @@ export default class CreateMergeRequestDropdown { ...@@ -417,12 +417,10 @@ export default class CreateMergeRequestDropdown {
setUnavailableButtonState(isLoading = true) { setUnavailableButtonState(isLoading = true) {
if (isLoading) { if (isLoading) {
this.unavailableButtonArrow.classList.remove('hide'); this.unavailableButtonSpinner.classList.remove('hide');
this.unavailableButtonArrow.classList.remove('fa-exclamation-triangle');
this.unavailableButtonText.textContent = __('Checking branch availability...'); this.unavailableButtonText.textContent = __('Checking branch availability...');
} else { } else {
this.unavailableButtonArrow.classList.add('hide'); this.unavailableButtonSpinner.classList.add('hide');
this.unavailableButtonArrow.classList.add('fa-exclamation-triangle');
this.unavailableButtonText.textContent = __('New branch unavailable'); this.unavailableButtonText.textContent = __('New branch unavailable');
} }
} }
......
---
title: Fix spinner in Create MR dropdown
merge_request: 26679
author:
type: fixed
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment