diff options
author | Alex Shpak <alex-shpak@users.noreply.github.com> | 2019-04-09 22:59:29 +0200 |
---|---|---|
committer | Alex Shpak <alex-shpak@users.noreply.github.com> | 2019-04-09 22:59:29 +0200 |
commit | 31a262451ae123a50d59bf4f8ad748d2cd14cdb1 (patch) | |
tree | 2b08db4532b2a9d47574d54b2e0bf14ab3760b13 | |
parent | 6ef4a4b69ce51a6c38aa5a2350bb6be7a3ee6bc4 (diff) |
Move from custom.css to custom.scss to be able to use variables
-rw-r--r-- | assets/book.scss | 5 | ||||
-rw-r--r-- | assets/custom.scss | 2 | ||||
-rw-r--r-- | exampleSite/assets/custom.scss | 1 | ||||
-rw-r--r-- | exampleSite/static/styles.css | 1 | ||||
-rw-r--r-- | layouts/partials/docs/html-head.html | 7 |
5 files changed, 8 insertions, 8 deletions
diff --git a/assets/book.scss b/assets/book.scss index c2689b9..7ba2bfa 100644 --- a/assets/book.scss +++ b/assets/book.scss @@ -217,4 +217,7 @@ aside nav, .book-toc nav { padding: $padding-16 * 2 $padding-16; } -}
\ No newline at end of file +} + +// Add custom defined styles +@import 'custom'
\ No newline at end of file diff --git a/assets/custom.scss b/assets/custom.scss new file mode 100644 index 0000000..181c87c --- /dev/null +++ b/assets/custom.scss @@ -0,0 +1,2 @@ +/* To be overridden by theme user */ +// @import "variables"; diff --git a/exampleSite/assets/custom.scss b/exampleSite/assets/custom.scss new file mode 100644 index 0000000..a0f49eb --- /dev/null +++ b/exampleSite/assets/custom.scss @@ -0,0 +1 @@ +@import "variables" diff --git a/exampleSite/static/styles.css b/exampleSite/static/styles.css deleted file mode 100644 index 4a9ab6b..0000000 --- a/exampleSite/static/styles.css +++ /dev/null @@ -1 +0,0 @@ -/* Your custom styles here */
\ No newline at end of file diff --git a/layouts/partials/docs/html-head.html b/layouts/partials/docs/html-head.html index 2e1a57d..72542ca 100644 --- a/layouts/partials/docs/html-head.html +++ b/layouts/partials/docs/html-head.html @@ -5,16 +5,11 @@ <!-- Fonts for the theme --> <link href="https://fonts.googleapis.com/css?family=Oxygen|Oxygen+Mono:300,400,700" rel="stylesheet"> -<!-- Theme stylesheet, if possible do not edit this stylesheet --> +<!-- Theme stylesheet, you can customize scss by creatig `assets/custom.scss` in your website --> <link rel="stylesheet" href="{{ "normalize.min.css" | relURL }}"> {{ $styles := resources.Get "book.scss" | resources.ToCSS | resources.Minify | resources.Fingerprint }} <link rel="stylesheet" href="{{ $styles.RelPermalink }}"> -<!-- Custom stylesheet - for your changes --> -{{ if (fileExists "styles.css" | relURL) -}} -<link rel="stylesheet" href="{{ "styles.css" | relURL }}?v={{ now.Unix }}" type='text/css' media='all'> -{{- end }} - <!-- Favicon --> <link rel="icon" href="{{ "favicon.png" | relURL }}" type="image/x-icon"> |