summaryrefslogtreecommitdiff
path: root/app/assets/stylesheets
diff options
context:
space:
mode:
authorSimon Knox <simon@gitlab.com>2018-04-16 09:52:33 +0000
committerPhil Hughes <me@iamphill.com>2018-04-16 09:52:33 +0000
commit0e1c5ed399ccfa9a08a666c2152e7b4d3dab4406 (patch)
tree11205bb6d0210f6e19082baa139c55ddcd38fe09 /app/assets/stylesheets
parentd182f6d16064940803d91c4fe82295766531e8f1 (diff)
downloadgitlab-ce-0e1c5ed399ccfa9a08a666c2152e7b4d3dab4406.tar.gz
Resolve "skeleton placeholder on diff has white background"
Diffstat (limited to 'app/assets/stylesheets')
-rw-r--r--app/assets/stylesheets/framework/animations.scss80
-rw-r--r--app/assets/stylesheets/framework/variables.scss14
2 files changed, 30 insertions, 64 deletions
diff --git a/app/assets/stylesheets/framework/animations.scss b/app/assets/stylesheets/framework/animations.scss
index 728f9a27aca..14cd32da9eb 100644
--- a/app/assets/stylesheets/framework/animations.scss
+++ b/app/assets/stylesheets/framework/animations.scss
@@ -187,12 +187,9 @@ a {
animation: fadeInFull $fade-in-duration 1;
}
-
.animation-container {
- background: $repo-editor-grey;
height: 40px;
overflow: hidden;
- position: relative;
&.animation-container-small {
height: 12px;
@@ -205,60 +202,43 @@ a {
}
}
- &::before {
- animation-duration: 1s;
- animation-fill-mode: forwards;
- animation-iteration-count: infinite;
- animation-name: blockTextShine;
- animation-timing-function: linear;
- background-image: $repo-editor-linear-gradient;
- background-repeat: no-repeat;
- background-size: 800px 45px;
- content: ' ';
- display: block;
- height: 100%;
+ [class^="skeleton-line-"] {
position: relative;
- }
-
- div {
- background: $white-light;
- height: 6px;
- left: 0;
- position: absolute;
- right: 0;
- }
-
- .skeleton-line-1 {
- left: 0;
- top: 8px;
- }
-
- .skeleton-line-2 {
- left: 150px;
- top: 0;
+ background-color: $theme-gray-100;
height: 10px;
- }
+ overflow: hidden;
- .skeleton-line-3 {
- left: 0;
- top: 23px;
- }
+ &:not(:last-of-type) {
+ margin-bottom: 4px;
+ }
- .skeleton-line-4 {
- left: 0;
- top: 38px;
+ &::after {
+ content: ' ';
+ display: block;
+ animation: blockTextShine 1s linear infinite forwards;
+ background-repeat: no-repeat;
+ background-size: cover;
+ background-image: linear-gradient(
+ to right,
+ $theme-gray-100 0%,
+ $theme-gray-50 20%,
+ $theme-gray-100 40%,
+ $theme-gray-100 100%
+ );
+ height: 10px;
+ }
}
+}
- .skeleton-line-5 {
- left: 200px;
- top: 28px;
- height: 10px;
- }
+$skeleton-line-widths: (
+ 156px,
+ 235px,
+ 200px,
+);
- .skeleton-line-6 {
- top: 14px;
- left: 230px;
- height: 10px;
+@for $count from 1 through length($skeleton-line-widths) {
+ .skeleton-line-#{$count} {
+ width: nth($skeleton-line-widths, $count);
}
}
diff --git a/app/assets/stylesheets/framework/variables.scss b/app/assets/stylesheets/framework/variables.scss
index 8ee1bb03d55..37223175199 100644
--- a/app/assets/stylesheets/framework/variables.scss
+++ b/app/assets/stylesheets/framework/variables.scss
@@ -714,20 +714,6 @@ $color-average-score: $orange-400;
$color-low-score: $red-400;
/*
-Repo editor
-*/
-$repo-editor-grey: #f6f7f9;
-$repo-editor-grey-darker: #e9ebee;
-$repo-editor-linear-gradient: linear-gradient(
- to right,
- $repo-editor-grey 0%,
- $repo-editor-grey-darker,
- 20%,
- $repo-editor-grey 40%,
- $repo-editor-grey 100%
-);
-
-/*
Performance Bar
*/
$perf-bar-text: #999;