Compare commits

...

15 Commits

Author SHA1 Message Date
Mark Dumay
1506281000 Merge pull request #156 from gethinode/develop
SEO
2023-02-18 17:21:32 +01:00
mark
a0a550d070 Fix scss issue 2023-02-18 17:01:03 +01:00
mark
0fe6e477a4 Bump package version 2023-02-18 16:55:24 +01:00
mark
a8618e1da3 Fix SEO issue 2023-02-18 16:54:44 +01:00
mark
e724130159 Refine scss definitions 2023-02-18 07:44:38 +01:00
Mark Dumay
831fc66534 Merge pull request #153 from gethinode/develop
Fix rendering of scss docs
2023-02-18 07:29:48 +01:00
mark
ba8631b6a3 Bump package version 2023-02-18 07:23:26 +01:00
mark
0092588d87 Fix rendering of scss 2023-02-18 07:22:53 +01:00
Mark Dumay
210f02089f Merge pull request #152 from gethinode/develop
Display
2023-02-18 07:06:13 +01:00
mark
6508caec70 Remove redundant file 2023-02-18 06:59:40 +01:00
mark
5123cd1d6b Bump dependencies 2023-02-18 06:55:58 +01:00
Mark Dumay
ed0b3c9da3 Merge pull request #151 from gethinode/merge
Sync branch
2023-02-18 06:54:42 +01:00
Mark Dumay
55100c9b62 Merge branch 'develop' into merge 2023-02-18 06:54:22 +01:00
mark
1728c66dcc Bump dependencies 2023-02-18 06:49:45 +01:00
mark
4fa17934fd Add display property for color modes 2023-02-18 06:48:45 +01:00
12 changed files with 71 additions and 37 deletions

View File

@@ -12,6 +12,7 @@ $light: {{ site.Params.style.light | default "#f8f9fa" }
$dark: {{ site.Params.style.dark | default "#212529" }};
$navbar-offset: {{ if site.Params.navigation.fixed }}{{ site.Params.navigation.offset | default "4em" }}{{ else }}0em{{ end }};
$enable-dark-mode: {{ site.Params.main.enableDarkMode | default true }} !default;
$enable-important-utilities: true !default;
// Include default variable overrides
@import "common/variables.scss";
@@ -97,7 +98,7 @@ $enable-dark-mode: {{ site.Params.main.enableDarkMode | default tru
@import "layouts/type.scss";
@import "common/export.scss";
@import "helpers/colored-links.scss";
@import "helpers/hidden.scss";
@import "helpers/display.scss";
// Import theme placeholder
@import "theme.scss";

View File

@@ -25,3 +25,4 @@
}
// scss-docs-end export
// stylelint-enable selector-pseudo-class-no-unknown

View File

@@ -17,7 +17,7 @@ $font-weight-bold: 600 !default;
$font-weight-bolder: bolder !default;
strong {
font-weight: 600 !important;
font-weight: 600 if($enable-important-utilities, !important, null);
}
// scss-docs-end font

View File

@@ -4,5 +4,5 @@
.btn-primary:active,
.btn-primary.active,
.open > .dropdown-toggle.btn-primary {
color: #fff !important;
color: #fff if($enable-important-utilities, !important, null);
}

View File

@@ -13,15 +13,15 @@
/* Remove border from toggler */
.navbar-toggler {
border: 0 !important;
border: 0 if($enable-important-utilities, !important, null);
}
.navbar-toggler:focus,
.navbar-toggler:active,
.navbar-toggler-icon:focus {
outline: none !important;
box-shadow: none !important;
border: 0 !important;
outline: none if($enable-important-utilities, !important, null);
box-shadow: none if($enable-important-utilities, !important, null);
border: 0 if($enable-important-utilities, !important, null);
}
/* Lines of the Toggler */

View File

@@ -1,4 +1,4 @@
// stylelint-disable function-name-case
// stylelint-disable function-name-case, declaration-no-important
// scss-docs-start colored-links
@each $color, $value in $theme-colors {
@@ -6,16 +6,20 @@
$color-rgb: to-rgb($value);
.link-bg-#{$color} {
color: $contrast-color !important; // stylelint-disable-line declaration-no-important
background-color: RGBA($color-rgb, var(--#{$prefix}bg-opacity, 1)) if($enable-important-utilities, !important, null); // stylelint-disable-line annotation-no-unknown
color: $contrast-color if($enable-important-utilities, !important, null);
background-color: RGBA($color-rgb, var(--#{$prefix}bg-opacity, 1)) if($enable-important-utilities, !important, null);
@if $link-shade-percentage != 0 {
&:hover,
&:focus {
color: if($contrast-color == $color-contrast-light, shade-color($contrast-color, $link-shade-percentage), tint-color($contrast-color, $link-shade-percentage)) !important; // stylelint-disable-line declaration-no-important
color: if($contrast-color == $color-contrast-light,
shade-color($contrast-color, $link-shade-percentage),
tint-color($contrast-color, $link-shade-percentage))
if($enable-important-utilities, !important, null);
}
}
}
}
// scss-docs-end colored-links
// stylelint-enable function-name-case, declaration-no-important

View File

@@ -0,0 +1,30 @@
.hidden {
display: none;
}
// stylelint-disable annotation-no-unknown
// scss-docs-start display-color
.d-none-light {
display: none if($enable-important-utilities, !important, null);
}
.d-none-dark {
display: block if($enable-important-utilities, !important, null);
}
@if $enable-dark-mode {
@include color-mode(dark) {
.d-none-light {
display: block if($enable-important-utilities, !important, null);
}
.d-none-dark {
display: none if($enable-important-utilities, !important, null);
}
}
}
// scss-docs-end display-color
// stylelint-enable annotation-no-unknown

View File

@@ -1,3 +0,0 @@
.hidden {
display: none;
}

View File

@@ -185,19 +185,19 @@
</a>
<ul class="dropdown-menu dropdown-menu-end" aria-labelledby="navbar-color-theme">
<li>
<a class="dropdown-item" data-bs-theme-value="light">
<a class="dropdown-item" data-bs-theme-value="light" href="#!">
{{- partial "assets/icon.html" (dict "icon" "fas sun theme-icon") }}
{{ T "colorLight" }}
</a>
</li>
<li>
<a class="dropdown-item" data-bs-theme-value="dark">
<a class="dropdown-item" data-bs-theme-value="dark" href="#!">
{{- partial "assets/icon.html" (dict "icon" "fas moon theme-icon") }}
{{ T "colorDark" }}
</a>
</li>
<li>
<a class="dropdown-item" data-bs-theme-value="auto">
<a class="dropdown-item" data-bs-theme-value="auto" href="#!">
{{- partial "assets/icon.html" (dict "icon" "fas circle-half-stroke theme-icon" ) }}
{{ T "colorAuto" }}
</a>

View File

@@ -25,6 +25,7 @@
{{- $capture_start = printf "// scss-docs-start %s" $name -}}
{{- $capture_end = printf "// scss-docs-end %s" $name -}}
{{- end -}}
{{- $extension = strings.TrimLeft "." $extension }}
{{- else -}}
{{- errorf "File format not supported (line %s): %s" .Position $file -}}
{{- end -}}
@@ -71,7 +72,7 @@
</ul>
<div class="border-start border-end border-bottom mb-3">
<div class="collapse multi-{{ $id }}{{ if $show }} show{{ end }} syntax-highlight" id="body-{{ $id }}">
{{- highlight (trim $match "\r\n") "toml" "" -}}
{{- highlight (trim $match "\r\n") $extension "" -}}
</div>
<div class="collapse multi-{{ $id }}{{ if not $show }} show{{ end }} p-3" id="footer-{{ $id }}"><i>...</i></div>
</div>

34
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{
"name": "@gethinode/hinode",
"version": "0.9.0",
"version": "0.9.3",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "@gethinode/hinode",
"version": "0.9.0",
"version": "0.9.3",
"hasInstallScript": true,
"license": "MIT",
"devDependencies": {
@@ -28,7 +28,7 @@
"rimraf": "^4.1.2",
"shx": "^0.3.4",
"stylelint": "^15.1.0",
"stylelint-config-standard-scss": "^7.0.0"
"stylelint-config-standard-scss": "^7.0.1"
}
},
"node_modules/@babel/code-frame": {
@@ -154,9 +154,9 @@
}
},
"node_modules/@csstools/css-tokenizer": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-2.0.1.tgz",
"integrity": "sha512-sYD3H7ReR88S/4+V5VbKiBEUJF4FqvG+8aNJkxqoPAnbhFziDG22IDZc4+h+xA63SfgM+h15lq5OnLeCxQ9nPA==",
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-2.0.2.tgz",
"integrity": "sha512-prUTipz0NZH7Lc5wyBUy93NFy3QYDMVEQgSeZzNdpMbKRd6V2bgRFyJ+O0S0Dw0MXWuE/H9WXlJk3kzMZRHZ/g==",
"dev": true,
"engines": {
"node": "^14 || ^16 || >=18"
@@ -179,8 +179,8 @@
"url": "https://opencollective.com/csstools"
},
"peerDependencies": {
"@csstools/css-parser-algorithms": "^2.0.0",
"@csstools/css-tokenizer": "^2.0.0"
"postcss": "^8.4",
"postcss-selector-parser": "^6.0.10"
}
},
"node_modules/@csstools/selector-specificity": {
@@ -5096,9 +5096,9 @@
}
},
"node_modules/stylelint-config-recommended-scss": {
"version": "9.0.0",
"resolved": "https://registry.npmjs.org/stylelint-config-recommended-scss/-/stylelint-config-recommended-scss-9.0.0.tgz",
"integrity": "sha512-5e9pn3Ztfncd8s9OqvvCW7tZpYe+vGmPi7VEXX7XEp+Kj38PnKCrvFCBL+hQ7rkD4d5QzjB3BxlFEyo/30UWUw==",
"version": "9.0.1",
"resolved": "https://registry.npmjs.org/stylelint-config-recommended-scss/-/stylelint-config-recommended-scss-9.0.1.tgz",
"integrity": "sha512-qAmz/TdrqslwiMTuLM3QXeISUkfEDUXGMfRBCHm/xrkCJNnQefv+mzG2mWTsWkqcVk8HAyUkug10dwAcYp2fCQ==",
"dev": true,
"dependencies": {
"postcss-scss": "^4.0.2",
@@ -5750,9 +5750,9 @@
"requires": {}
},
"@csstools/css-tokenizer": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-2.0.1.tgz",
"integrity": "sha512-sYD3H7ReR88S/4+V5VbKiBEUJF4FqvG+8aNJkxqoPAnbhFziDG22IDZc4+h+xA63SfgM+h15lq5OnLeCxQ9nPA==",
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-2.0.2.tgz",
"integrity": "sha512-prUTipz0NZH7Lc5wyBUy93NFy3QYDMVEQgSeZzNdpMbKRd6V2bgRFyJ+O0S0Dw0MXWuE/H9WXlJk3kzMZRHZ/g==",
"dev": true
},
"@csstools/media-query-list-parser": {
@@ -9330,9 +9330,9 @@
"requires": {}
},
"stylelint-config-recommended-scss": {
"version": "9.0.0",
"resolved": "https://registry.npmjs.org/stylelint-config-recommended-scss/-/stylelint-config-recommended-scss-9.0.0.tgz",
"integrity": "sha512-5e9pn3Ztfncd8s9OqvvCW7tZpYe+vGmPi7VEXX7XEp+Kj38PnKCrvFCBL+hQ7rkD4d5QzjB3BxlFEyo/30UWUw==",
"version": "9.0.1",
"resolved": "https://registry.npmjs.org/stylelint-config-recommended-scss/-/stylelint-config-recommended-scss-9.0.1.tgz",
"integrity": "sha512-qAmz/TdrqslwiMTuLM3QXeISUkfEDUXGMfRBCHm/xrkCJNnQefv+mzG2mWTsWkqcVk8HAyUkug10dwAcYp2fCQ==",
"dev": true,
"requires": {
"postcss-scss": "^4.0.2",

View File

@@ -1,6 +1,6 @@
{
"name": "@gethinode/hinode",
"version": "0.9.0",
"version": "0.9.3",
"description": "Hinode is a clean documentation and blog theme for Hugo, an open-source static site generator",
"keywords": [
"hugo",
@@ -70,7 +70,7 @@
"rimraf": "^4.1.2",
"shx": "^0.3.4",
"stylelint": "^15.1.0",
"stylelint-config-standard-scss": "^7.0.0"
"stylelint-config-standard-scss": "^7.0.1"
},
"otherDependencies": {
"hugo": "0.110.0"