-
Notifications
You must be signed in to change notification settings - Fork 14.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use Hugo for Sass processing (#9404)
* Move all Sass into a common /assets directory * Remove node-sass make command * Change head partial to accommodate full Sass rules * Bump Hugo version in Netlify config * Use separate partial for CSS imports * Bump Hugo version * Remove PostCSS from the pipeline * Un-bump version * Update Hugo version to 0.44 * Update Hugo version in Makefile * Update production Hugo version * Fix misspelled variable name * Add ./resources folder to Git * Update Hugo version in Netlify config to 0.45.1 * Use un-cached css.html partial * Re-work extra CSS logic for .Params.css
- Loading branch information
1 parent
ac493db
commit 1060c00
Showing
20 changed files
with
45 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,5 +12,3 @@ linkTitle: "Documentation" | |
main_menu: true | ||
weight: 5 | ||
--- | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
{{- $mainSass := "sass/styles.sass" }} | ||
{{- $caseStudySass := "sass/case_study_styles.sass" }} | ||
<link rel="stylesheet" type="text/css" href="/css/base_fonts.css"> | ||
{{- if .Site.IsServer }} | ||
{{- $mainCssOpts := (dict "targetPath" "css/styles.css") }} | ||
{{- $mainCss := resources.Get $mainSass | toCSS $mainCssOpts }} | ||
<link rel="stylesheet" media="screen" href="{{ $mainCss.RelPermalink }}"><!-- default styles.css on --> | ||
{{- else }} | ||
{{- $mainCssOpts := (dict "targetPath" "css/styles.css") }} | ||
{{- $mainCss := resources.Get $mainSass | toCSS $mainCssOpts | minify | fingerprint }} | ||
<link rel="stylesheet" media="screen" href="{{ $mainCss.RelPermalink }}" integrity="{{ $mainCss.Data.Integrity }}"><!-- default styles.css on --> | ||
{{- end }} | ||
{{- if .Params.case_study_styles }} | ||
{{- $caseStudyCssOpts := (dict "targetPath" "css/styles.css") }} | ||
{{- $caseStudyCss := resources.Get $caseStudySass | toCSS $caseStudyCssOpts | minify | fingerprint }} | ||
<link rel="stylesheet" media="screen" href="{{ $caseStudyCss.Permalink }}" integrity="{{ $caseStudyCss.Data.Integrity }}"><!-- custom case_study_styles on --> | ||
{{- end }} | ||
<link rel="stylesheet" type="text/css" href="https://code.jquery.com/ui/1.12.1/themes/smoothness/jquery-ui.css"> | ||
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.min.css"> | ||
<link rel="stylesheet" type="text/css" href="{{ "css/callouts.css" | relURL }}"> | ||
<link rel="stylesheet" type="text/css" href="{{ "css/custom-jekyll/tags.css" | relURL }}"> | ||
{{- if .Params.deprecated }} | ||
<link rel="stylesheet" type="text/css" href="{{ "css/deprecation-warning.css" | relURL }}"> | ||
{{- end }} | ||
{{- if eq .Params.class "gridPage" }} | ||
<link rel="stylesheet" type="text/css" href="{{ "css/gridpage.css" | relURL }}"> | ||
{{- end }} | ||
{{- with .Params.css }} | ||
{{- range (split . ",") }} | ||
{{- $url := trim . " " | relURL }} | ||
<link rel="stylesheet" type="text/css" href="{{ $url }}"><!-- custom css added --> | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
resources/_gen/assets/sass/cn/sass/styles.sass_cb957da2191fde4902dd41b139c8069d.content
Large diffs are not rendered by default.
Oops, something went wrong.
1 change: 1 addition & 0 deletions
1
resources/_gen/assets/sass/cn/sass/styles.sass_cb957da2191fde4902dd41b139c8069d.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"Target":"css/styles.min.cc96976ab977e15130372b9aa336567b7cd2c0cfdbacc2884d84a5f56868cc20.css","MediaType":"text/css","Data":{"Integrity":"sha256-zJaXarl34VEwNyuaozZWe3zSwM/brMKITYSl9WhozCA="}} |
1 change: 1 addition & 0 deletions
1
...ces/_gen/assets/sass/sass/case_study_styles.sass_cb957da2191fde4902dd41b139c8069d.content
Large diffs are not rendered by default.
Oops, something went wrong.
1 change: 1 addition & 0 deletions
1
resources/_gen/assets/sass/sass/case_study_styles.sass_cb957da2191fde4902dd41b139c8069d.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"Target":"css/styles.min.3a4a157b6c0f5130dd7ada2cc65c770a1e7b22b443594d9f713ff99fd6ca0425.css","MediaType":"text/css","Data":{"Integrity":"sha256-OkoVe2wPUTDdetosxlx3Ch57IrRDWU2fcT/5n9bKBCU="}} |
1 change: 1 addition & 0 deletions
1
resources/_gen/assets/sass/sass/styles.sass_cb957da2191fde4902dd41b139c8069d.content
Large diffs are not rendered by default.
Oops, something went wrong.
1 change: 1 addition & 0 deletions
1
resources/_gen/assets/sass/sass/styles.sass_cb957da2191fde4902dd41b139c8069d.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"Target":"css/styles.min.cc96976ab977e15130372b9aa336567b7cd2c0cfdbacc2884d84a5f56868cc20.css","MediaType":"text/css","Data":{"Integrity":"sha256-zJaXarl34VEwNyuaozZWe3zSwM/brMKITYSl9WhozCA="}} |