mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-25 00:33:58 -04:00
Fix border around letter images
Things in CSS stack top to bottom like this: - image - `box-shadow` - `background` We are drawing the border around the letter using `box-shadow`. This was working fine because the images of our letters had a transparent background, so you could see the border through them. At some point our letters have changed to have a white background. So you can no longer see the border. This commit: - adds a new pseudo element which stacks above the image of the letter - moves the border from the image itself to said pseudo element
This commit is contained in:
@@ -28,11 +28,20 @@ $iso-paper-ratio: 141.42135624%;
|
|||||||
width: 0px;
|
width: 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
content: "";
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
box-shadow: inset 0 0 0 1px $border-colour;
|
||||||
|
}
|
||||||
|
|
||||||
img {
|
img {
|
||||||
display: block;
|
display: block;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
background: $white;
|
background: $white;
|
||||||
box-shadow: inset 0 0 0 1px $border-colour;
|
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user