jekyll-theme-centos 2.53.0 → 2.54.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/_data/base/color.yml +91 -454
- data/_data/base/color_schema.yml +48 -390
- data/_data/base/fontawesome_schema.yml +2 -2
- data/_data/base/fonts_schema.yml +24 -16
- data/_includes/base/fontawesome.html.liquid +16 -2
- data/_includes/base/fonts.html.liquid +11 -20
- data/_sass/base/_light-dark.scss +8 -8
- data/_sass/base/_maps.scss +3 -6
- data/_sass/base/_variables.scss +13 -16
- metadata +1 -1
|
@@ -28,10 +28,21 @@ Schema: src/YAML/fontawesome_schema.yml
|
|
|
28
28
|
{%- assign fontawesome_css_bundles = with_fontawesome_data.css_bundles %}
|
|
29
29
|
{%- assign fontawesome_css_integrity = with_fontawesome_schema.css_bundles.x_integrity.properties %}
|
|
30
30
|
|
|
31
|
+
{%- comment %} Escaped once here, since every value below goes into an attribute. {%- endcomment %}
|
|
32
|
+
{%- assign fontawesome_version = fontawesome_version | escape %}
|
|
33
|
+
{%- assign fontawesome_cdn = fontawesome_cdn | escape %}
|
|
34
|
+
{%- assign fontawesome_css_bundle_name = fontawesome_css_bundle_name | escape %}
|
|
35
|
+
{%- assign fontawesome_css_bundle_integrity = fontawesome_css_bundle_integrity | escape %}
|
|
36
|
+
{%- assign fontawesome_js_bundle_name = fontawesome_js_bundle_name | escape %}
|
|
37
|
+
{%- assign fontawesome_js_bundle_integrity = fontawesome_js_bundle_integrity | escape %}
|
|
38
|
+
|
|
31
39
|
{%- capture html_fontawesome_preload %}
|
|
32
40
|
{%- if fontawesome_mode == "css" and fontawesome_css_bundles %}
|
|
33
41
|
{%- for bundle in fontawesome_css_bundles %}
|
|
34
|
-
|
|
42
|
+
{%- comment %} A bundle with no integrity value in the schema is left out, so nothing loads unverified. {%- endcomment %}
|
|
43
|
+
{%- assign bundle_integrity = fontawesome_css_integrity[bundle] %}
|
|
44
|
+
{%- unless bundle_integrity %}{% continue %}{% endunless %}
|
|
45
|
+
<link rel="preload" href="{{ fontawesome_cdn }}/{{ fontawesome_version }}/css/{{ bundle | escape }}.min.css" as="style" fetchpriority="high" integrity="{{ bundle_integrity | escape }}" crossorigin="anonymous" />
|
|
35
46
|
{%- endfor %}
|
|
36
47
|
{%- elsif fontawesome_mode == "css" %}
|
|
37
48
|
<link rel="preload" href="{{ fontawesome_cdn }}/{{ fontawesome_version }}/css/{{ fontawesome_css_bundle_name }}.min.css" as="style" fetchpriority="high" integrity="{{ fontawesome_css_bundle_integrity }}" crossorigin="anonymous" />
|
|
@@ -43,7 +54,10 @@ Schema: src/YAML/fontawesome_schema.yml
|
|
|
43
54
|
{%- capture html_fontawesome_head %}
|
|
44
55
|
{%- if fontawesome_mode == "css" and fontawesome_css_bundles %}
|
|
45
56
|
{%- for bundle in fontawesome_css_bundles %}
|
|
46
|
-
|
|
57
|
+
{%- comment %} A bundle with no integrity value in the schema is left out, so nothing loads unverified. {%- endcomment %}
|
|
58
|
+
{%- assign bundle_integrity = fontawesome_css_integrity[bundle] %}
|
|
59
|
+
{%- unless bundle_integrity %}{% continue %}{% endunless %}
|
|
60
|
+
<link rel="stylesheet" href="{{ fontawesome_cdn }}/{{ fontawesome_version }}/css/{{ bundle | escape }}.min.css" integrity="{{ bundle_integrity | escape }}" crossorigin="anonymous" referrerpolicy="no-referrer" />
|
|
47
61
|
{%- endfor %}
|
|
48
62
|
{%- elsif fontawesome_mode == "css" %}
|
|
49
63
|
<link rel="stylesheet" href="{{ fontawesome_cdn }}/{{ fontawesome_version }}/css/{{ fontawesome_css_bundle_name }}.min.css" integrity="{{ fontawesome_css_bundle_integrity }}" crossorigin="anonymous" referrerpolicy="no-referrer" />
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{% comment %}
|
|
2
|
-
fonts: loads the page's web fonts
|
|
2
|
+
fonts: loads the page's web fonts from pinned packages on a CDN, each verified by its integrity value. head.html.liquid calls it with type="hints" and type="preload".
|
|
3
3
|
Data: include.data > page.with_fonts_data > site.data.fonts > site.data.base.fonts
|
|
4
4
|
Schema: src/YAML/fonts_schema.yml
|
|
5
5
|
{% endcomment %}
|
|
@@ -18,31 +18,22 @@ Schema: src/YAML/fonts_schema.yml
|
|
|
18
18
|
{%- assign with_fonts_schema = site.data.base.fonts_schema.properties.with_fonts_data.properties %}
|
|
19
19
|
|
|
20
20
|
{%- if with_fonts %}
|
|
21
|
-
{%- assign fonts_cdn
|
|
22
|
-
{%- assign
|
|
23
|
-
{%- assign
|
|
24
|
-
{%- assign fonts_family_stylesheet = with_fonts_schema.families.items.properties.stylesheet.default %}
|
|
21
|
+
{%- assign fonts_cdn = with_fonts_data.cdn | default: with_fonts_schema.cdn.default %}
|
|
22
|
+
{%- assign fonts_families = with_fonts_data.families | default: with_fonts_schema.families.default %}
|
|
23
|
+
{%- assign fonts_family_stylesheet = with_fonts_schema.families.items.properties.stylesheet.default %}
|
|
25
24
|
|
|
26
25
|
{%- assign type = include.type %}
|
|
27
26
|
{%- case type %}
|
|
28
27
|
{%- when "hints" %}
|
|
29
|
-
{
|
|
30
|
-
<link rel="
|
|
31
|
-
<link rel="dns-prefetch" href="https://fonts.googleapis.com" />
|
|
32
|
-
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
|
33
|
-
<link rel="dns-prefetch" href="https://fonts.gstatic.com" />
|
|
34
|
-
{%- elsif fonts_families.size > 0 %}
|
|
35
|
-
<link rel="preconnect" href="{{ fonts_cdn }}" crossorigin />
|
|
36
|
-
<link rel="dns-prefetch" href="{{ fonts_cdn }}" />
|
|
37
|
-
{%- endif %}
|
|
28
|
+
<link rel="preconnect" href="{{ fonts_cdn | escape }}" crossorigin />
|
|
29
|
+
<link rel="dns-prefetch" href="{{ fonts_cdn | escape }}" />
|
|
38
30
|
{%- when "preload" %}
|
|
39
|
-
{%-
|
|
40
|
-
<link rel="preload" href="{{ fonts_default_stylesheet }}" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
|
41
|
-
<noscript><link rel="stylesheet" href="{{ fonts_default_stylesheet }}" /></noscript>
|
|
42
|
-
{%- else %}
|
|
31
|
+
{%- comment %} A family with a missing or blank integrity value is left out, so nothing loads unverified. An empty string is truthy in Liquid, so check its size. {%- endcomment %}
|
|
43
32
|
{%- for family in fonts_families %}
|
|
44
|
-
|
|
33
|
+
{%- assign family_integrity = family.integrity | strip %}
|
|
34
|
+
{%- if family_integrity.size == 0 %}{% continue %}{% endif %}
|
|
35
|
+
{%- capture family_href %}{{ fonts_cdn }}/{{ family.package }}@{{ family.version }}/{{ family.stylesheet | default: fonts_family_stylesheet }}{% endcapture %}
|
|
36
|
+
<link rel="stylesheet" href="{{ family_href | escape }}" integrity="{{ family_integrity | escape }}" crossorigin="anonymous" referrerpolicy="no-referrer" />
|
|
45
37
|
{%- endfor %}
|
|
46
|
-
{%- endif %}
|
|
47
38
|
{%- endcase %}
|
|
48
39
|
{%- endif %}
|
data/_sass/base/_light-dark.scss
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
//
|
|
2
|
-
//
|
|
3
|
-
//
|
|
4
|
-
// Generated: Shade 50 → $light, Shade 950 → $dark
|
|
1
|
+
// $light and $dark are the ends of the centos-purple shade scale that
|
|
2
|
+
// _theme-colors.scss generates. They're literals because _variables.scss needs
|
|
3
|
+
// them before that scale exists.
|
|
5
4
|
//
|
|
6
|
-
//
|
|
7
|
-
//
|
|
5
|
+
// After a change to the purple base color or the shade rules, copy the new
|
|
6
|
+
// --bs-centos-purple-50 and --bs-centos-purple-950 values from the compiled CSS.
|
|
7
|
+
// scripts/colors/tests/test_color_contract.py fails until they match.
|
|
8
8
|
|
|
9
|
-
$light: #F6EDF4 !default; // centos-purple-50
|
|
10
|
-
$dark: #22061B !default;
|
|
9
|
+
$light: #F6EDF4 !default; // centos-purple-50
|
|
10
|
+
$dark: #22061B !default; // centos-purple-950
|
data/_sass/base/_maps.scss
CHANGED
|
@@ -62,7 +62,9 @@ $centos-bg-gradients: (
|
|
|
62
62
|
)
|
|
63
63
|
) !default;
|
|
64
64
|
|
|
65
|
-
// Define custom text gradients.
|
|
65
|
+
// Define custom text gradients. _gradients.scss turns them into
|
|
66
|
+
// .text-gradient-* classes: a gradient can't be a `color` value, so they clip a
|
|
67
|
+
// background gradient to the text instead of using the utilities API.
|
|
66
68
|
$centos-text-gradients: (
|
|
67
69
|
"primary": linear-gradient(
|
|
68
70
|
90deg,
|
|
@@ -89,10 +91,5 @@ $utilities: map.merge(
|
|
|
89
91
|
class: bg-gradient,
|
|
90
92
|
values: $centos-bg-gradients
|
|
91
93
|
),
|
|
92
|
-
"centos-text-gradient": (
|
|
93
|
-
property: color,
|
|
94
|
-
class: text-gradient,
|
|
95
|
-
values: $centos-text-gradients,
|
|
96
|
-
),
|
|
97
94
|
)
|
|
98
95
|
);
|
data/_sass/base/_variables.scss
CHANGED
|
@@ -86,8 +86,7 @@
|
|
|
86
86
|
// enough for the 2.0x multiplier to hit 100% — orange, blue, and green all
|
|
87
87
|
// do. Purple's base saturation is too low, so purple-950 lands close to the
|
|
88
88
|
// wallpaper's dark corner rather than matching it exactly; see
|
|
89
|
-
// src/YAML/color.yml
|
|
90
|
-
// actual current value.
|
|
89
|
+
// src/YAML/color.yml for its actual current value.
|
|
91
90
|
@function saturated-shade($color, $shade) {
|
|
92
91
|
// Extract current HSL values from the color
|
|
93
92
|
$current-hue: color.hue($color);
|
|
@@ -106,8 +105,7 @@
|
|
|
106
105
|
// ================================================================================
|
|
107
106
|
// CentOS Color (Our beloved branding colors)
|
|
108
107
|
// ================================================================================
|
|
109
|
-
// Not !default:
|
|
110
|
-
// map's exact form, and the brand colors aren't per-project settings.
|
|
108
|
+
// Not !default: the brand colors aren't per-project settings.
|
|
111
109
|
$centos-base-colors: (
|
|
112
110
|
centos-purple: #A14F8C,
|
|
113
111
|
centos-orange: #EFA724,
|
|
@@ -150,14 +148,10 @@ $warning: #C86A00 !default; // Darkened centos-orange - warm, urgent
|
|
|
150
148
|
$danger: #C62828 !default; // External red - no CentOS equivalent
|
|
151
149
|
$info: #1976D2 !default; // External blue - distinguishes from warning
|
|
152
150
|
|
|
153
|
-
//
|
|
154
|
-
//
|
|
155
|
-
//
|
|
156
|
-
//
|
|
157
|
-
// for all other shades in the color system.
|
|
158
|
-
//
|
|
159
|
-
// To update after color changes: python3 scripts/colors/generate-scss-light-dark.py
|
|
160
|
-
// The generated values are imported from: src/SASS/_light-dark.scss
|
|
151
|
+
// $light and $dark are centos-purple-50 and centos-purple-950. Assigning the shade
|
|
152
|
+
// functions' results here causes Dart Sass chicken-and-egg issues, so
|
|
153
|
+
// src/SASS/_light-dark.scss holds them as literals, and the colour contract test
|
|
154
|
+
// checks they still match those shades.
|
|
161
155
|
@import "light-dark";
|
|
162
156
|
|
|
163
157
|
$white: #ffffff !default;
|
|
@@ -165,8 +159,9 @@ $black: #000000 !default;
|
|
|
165
159
|
|
|
166
160
|
// Bootstrap's default inline-code color isn't part of this site's brand
|
|
167
161
|
// and fails WCAG AA against the code background in _content.scss.
|
|
168
|
-
// This is centos-purple-700
|
|
169
|
-
|
|
162
|
+
// This is centos-purple-700, kept as a literal like $light and $dark; the
|
|
163
|
+
// colour contract test checks that it still matches that shade.
|
|
164
|
+
$code-color: #67335A !default;
|
|
170
165
|
|
|
171
166
|
// Background and Body variables
|
|
172
167
|
// These control the default background and text colors for the entire page.
|
|
@@ -208,8 +203,10 @@ $spacers: (
|
|
|
208
203
|
// --------------------------------------------------------------------------------
|
|
209
204
|
// Typography
|
|
210
205
|
// --------------------------------------------------------------------------------
|
|
211
|
-
|
|
212
|
-
|
|
206
|
+
// The fonts component loads these families from pinned packages, which declare the
|
|
207
|
+
// "Variable" names. The plain names follow, for a site that loads them another way.
|
|
208
|
+
$font-family-sans-serif: "Montserrat Variable", "Montserrat", sans-serif !default;
|
|
209
|
+
$font-family-monospace: "Source Code Pro Variable", "Source Code Pro", monospace !default;
|
|
213
210
|
$headings-font-weight: 700 !default;
|
|
214
211
|
$font-size-base: $spacer !default;
|
|
215
212
|
$h1-font-size: $font-size-base * 2.75 !default;
|