Fix PurgeCSS

parent 38f91cae
Pipeline #96 failed with stage
in 1 minute and 42 seconds
...@@ -14,7 +14,7 @@ before_script: ...@@ -14,7 +14,7 @@ before_script:
- bundle install - bundle install
- ./scripts/ci_fix_baseurl.sh - ./scripts/ci_fix_baseurl.sh
- jekyll build -d public - jekyll build -d public
- ./node_modules/.bin/purgecss --css 'public/assets/css/*.css' --content 'public/**/*.html' --out 'public/assets/css/' - ./scripts/purgecss.sh
deploy-prod: deploy-prod:
stage: deploy stage: deploy
......
...@@ -28,6 +28,7 @@ GEM ...@@ -28,6 +28,7 @@ GEM
rouge (>= 1.7, < 4) rouge (>= 1.7, < 4)
safe_yaml (~> 1.0) safe_yaml (~> 1.0)
jekyll-paginate (1.1.0) jekyll-paginate (1.1.0)
jekyll-purgecss (0.2.0)
jekyll-sass-converter (1.5.2) jekyll-sass-converter (1.5.2)
sass (~> 3.4) sass (~> 3.4)
jekyll-sitemap (1.3.1) jekyll-sitemap (1.3.1)
...@@ -64,6 +65,7 @@ PLATFORMS ...@@ -64,6 +65,7 @@ PLATFORMS
DEPENDENCIES DEPENDENCIES
jekyll jekyll
jekyll-paginate jekyll-paginate
jekyll-purgecss
jekyll-sitemap jekyll-sitemap
support-for support-for
......
...@@ -12773,6 +12773,7 @@ CONTACT PAGE STYLING ...@@ -12773,6 +12773,7 @@ CONTACT PAGE STYLING
width: 48%; width: 48%;
float: right; float: right;
margin-right: 0; } margin-right: 0; }
/* purgecss start ignore */
#home-hq-map { #home-hq-map {
-webkit-clip-path: polygon(0% calc(100vw * 0.052), 100% 0%, 100% calc(100% - calc(100vw * 0.052)), 0% 100%); -webkit-clip-path: polygon(0% calc(100vw * 0.052), 100% 0%, 100% calc(100% - calc(100vw * 0.052)), 0% 100%);
clip-path: polygon(0% calc(100vw * 0.052), 100% 0%, 100% calc(100% - calc(100vw * 0.052)), 0% 100%); } clip-path: polygon(0% calc(100vw * 0.052), 100% 0%, 100% calc(100% - calc(100vw * 0.052)), 0% 100%); }
...@@ -12780,6 +12781,7 @@ CONTACT PAGE STYLING ...@@ -12780,6 +12781,7 @@ CONTACT PAGE STYLING
transform: translateY(calc(calc(100vw * -0.052335956242943835) - 38px)) rotate(-3deg); } transform: translateY(calc(calc(100vw * -0.052335956242943835) - 38px)) rotate(-3deg); }
#home-hq-map .leaflet-top.leaflet-left { #home-hq-map .leaflet-top.leaflet-left {
transform: translateY(calc(calc(100vw * 0.052335956242943835))); } transform: translateY(calc(calc(100vw * 0.052335956242943835))); }
/* purgecss end ignore */
.before-map { .before-map {
padding-bottom: 35px; } padding-bottom: 35px; }
.before-map p:last-of-type { .before-map p:last-of-type {
......
...@@ -313,10 +313,12 @@ CONTACT PAGE STYLING ...@@ -313,10 +313,12 @@ CONTACT PAGE STYLING
} }
} }
/* purgecss start ignore */
#home-hq-map { #home-hq-map {
-webkit-clip-path: polygon(0% calc(100vw * 0.052), 100% 0%, 100% calc(100% - calc(100vw * 0.052)), 0% 100%); -webkit-clip-path: polygon(0% calc(100vw * 0.052), 100% 0%, 100% calc(100% - calc(100vw * 0.052)), 0% 100%);
clip-path: polygon(0% calc(100vw * 0.052), 100% 0%, 100% calc(100% - calc(100vw * 0.052)), 0% 100%); clip-path: polygon(0% calc(100vw * 0.052), 100% 0%, 100% calc(100% - calc(100vw * 0.052)), 0% 100%);
// -0.052335956242943835 == sin(-3deg) // -0.052335956242943835 == sin(-3deg)
// Contributors badge // Contributors badge
.leaflet-bottom.leaflet-right { .leaflet-bottom.leaflet-right {
...@@ -328,6 +330,7 @@ CONTACT PAGE STYLING ...@@ -328,6 +330,7 @@ CONTACT PAGE STYLING
transform: translateY(calc(calc(100vw * 0.052335956242943835))); transform: translateY(calc(calc(100vw * 0.052335956242943835)));
} }
} }
/* purgecss end ignore */
.before-map { .before-map {
padding-bottom: 35px; padding-bottom: 35px;
......
#!/bin/bash
sitedir="$1"
echo "Purging unused CSS..."
./node_modules/.bin/purgecss \
--css "$sitedir"/assets/css/'*'.css \
--content "$sitedir"/index.html "$sitedir"/'**/*.html' "$sitedir"/assets/js/'*.js' \
--out "$sitedir"/assets/css/
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment