Make view loading state prettier

Fixes: #113
This commit is contained in:
Teemu Patja 2017-11-01 10:08:13 +02:00
parent a8796f5fb2
commit dcde2a9772
No known key found for this signature in database
GPG Key ID: F5B7035E6580FD4C
3 changed files with 21 additions and 4 deletions

View File

@ -80,9 +80,9 @@
(let [repos-loading? (rf/subscribe [:repos-loading?])]
(fn []
(if @repos-loading?
[:div
[:div.view-loading-container
[:div.ui.active.inverted.dimmer
[:div.ui.text.loader "Loading"]]]
[:div.ui.text.loader.view-loading-label "Loading"]]]
[repos-list]))))
(defn repos-page []

View File

@ -45,9 +45,9 @@
(let [metrics-loading? (rf/subscribe [:metrics-loading?])]
(fn []
(if @metrics-loading?
[:div
[:div.view-loading-container
[:div.ui.active.inverted.dimmer
[:div.ui.text.loader "Loading"]]]
[:div.ui.text.loader.view-loading-label "Loading"]]]
[:div
[:h2 "Usage metrics for the past 30 days"]
[chartjs-component]]))))

View File

@ -291,6 +291,23 @@
}
}
.view-loading-container {
padding: 64px;
display: flex;
flex-direction: column;
justify-content: center;
height: auto;
border-radius: 10px;
.ui.inverted.dimmer {
background-color: transparent;
}
}
.view-loading-label {
font-size: 18px !important;
}
.repo-label {
color: #42505c;
font-family: "PostGrotesk-Medium";