fix(docs-infra): correctly cache footer image by the SW (#27250)

When using relative paths for CSS resources (such as background images),
`@angular/cli` will move them to the root `dist/` directory (and update
the paths in CSS accordingly). This results in the SW being unable to
cache the resource, because it is not where it expects it to be.

This commit fixes this issue for the footer background image, by using
an absolute path for the URL. (It also removes an unused style that
would have been affected by the same issue.)

PR Close #27250
This commit is contained in:
George Kalpakas 2018-11-27 00:47:34 +02:00 committed by Igor Minar
parent af952cad62
commit 271fcb0f3e
2 changed files with 2 additions and 17 deletions

View File

@ -103,8 +103,8 @@ footer::after {
left: 0;
right: 0;
background:
url('../src/assets/images/logos/angular/angular_whiteTransparent_withMargin.png') top 0 left 0 repeat,
url('../src/assets/images/logos/angular/angular_whiteTransparent_withMargin.png') top 80px left 160px repeat;
url('/assets/images/logos/angular/angular_whiteTransparent_withMargin.png') top 0 left 0 repeat,
url('/assets/images/logos/angular/angular_whiteTransparent_withMargin.png') top 80px left 160px repeat;
opacity: 0.05;
background-size: 320px auto;
}

View File

@ -67,21 +67,6 @@ a.button.mat-button {
background: $darkgray;
color: rgba($white, .87);
}
&.button-shield,
&.button-shield.mat-button {
background-color: $blue;
background: $blue url('assets/images/logos/angular/angular_whiteTransparent.svg') 24px 13px no-repeat;
color: rgba($white, .87);
padding-left: 54px;
background-size: 22px 22px;
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min-device-pixel-ratio: 2) {
background: $blue url('assets/images/logos/angular/angular_whiteTransparent.svg') 24px 13px no-repeat;
background-size: 22px 22px;
}
}
}
.cta-bar {