Added spinner for loading manually created subscription

This commit is contained in:
Peter Zimon 2021-05-19 20:56:29 +02:00
parent f3e7cf6128
commit 70e57ae7c8
2 changed files with 9 additions and 1 deletions

View File

@ -107,11 +107,14 @@
{{#unless this.products}} {{#unless this.products}}
<div class="gh-main-section-content bordered"> <div class="gh-main-section-content bordered">
<div class="gh-cp-memberproduct-noproduct"> <div class="gh-cp-memberproduct-noproduct">
{{#unless this.isCreatingComplimentary}}
<div class="mb2">This member doesn't have subscriptions.</div> <div class="mb2">This member doesn't have subscriptions.</div>
{{/unless}}
{{#unless this.member.isNew}} {{#unless this.member.isNew}}
{{#if this.isAddComplimentaryAllowed}} {{#if this.isAddComplimentaryAllowed}}
{{#if this.isCreatingComplimentary}} {{#if this.isCreatingComplimentary}}
Loading... <GhLoadingSpinner />
{{else}} {{else}}
<button type="button" class="gh-btn gh-btn-text green gh-btn-icon gh-btn-addproduct" {{action "addCompedSubscription"}}> <button type="button" class="gh-btn gh-btn-text green gh-btn-icon gh-btn-addproduct" {{action "addCompedSubscription"}}>
<span>{{svg-jar "add"}} Add complimentary subscription</span> <span>{{svg-jar "add"}} Add complimentary subscription</span>

View File

@ -1648,6 +1648,7 @@ p.gh-members-import-errordetail:first-of-type {
} }
.gh-cp-memberproduct-noproduct { .gh-cp-memberproduct-noproduct {
position: relative;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
@ -1656,6 +1657,10 @@ p.gh-members-import-errordetail:first-of-type {
padding: 48px 0; padding: 48px 0;
} }
.gh-cp-memberproduct-noproduct .gh-loading-content {
padding-bottom: unset;
}
.gh-btn-add-memberproduct[disabled], .gh-btn-add-memberproduct[disabled],
.gh-btn-add-memberproduct[disabled]:hover { .gh-btn-add-memberproduct[disabled]:hover {
background: var(--lightgrey-l1) !important; background: var(--lightgrey-l1) !important;