💄 ⚡ optimization CDN vendors display & import generate site speed.
This commit is contained in:
parent
c116aa31ad
commit
9a83558e01
8
.gitignore
vendored
8
.gitignore
vendored
@ -1,6 +1,6 @@
|
||||
# Ignore files in Hugo NexT theme
|
||||
|
||||
.hugo_build.lock
|
||||
|
||||
exampleSite/public
|
||||
exampleSite/resources
|
||||
exampleSite/
|
||||
!exampleSite/content
|
||||
!exampleSite/start.sh
|
||||
!exampleSite/config.yaml
|
@ -8,9 +8,9 @@ Start a new journey for Hugo's theme of NexT.
|
||||
|
||||
Make `NexT` theme is easily & powerful.
|
||||
|
||||
# Preview
|
||||
# Preview
|
||||
|
||||
| Environment | :gemini: (**Default**) | :heart_decoration: | :six_pointed_star: | :pisces: | Status |
|
||||
| :---: | :---: | :---: | :---: | :---: | :---: |
|
||||
| Preliminary | [Gemini](https://hugo-next-dev.vercel.app/) | [Muse](https://hugo-next-dev.vercel.app/muse/) | [Mist](https://hugo-next-dev.vercel.app/mist/) | [Pisces](https://hugo-next-dev.vercel.app/pisces/) |  |
|
||||
| Production | [Gemini](https://hugo-next-prod.vercel.app/) | [Muse](https://hugo-next-prod.vercel.app/muse/) | [Mist](https://hugo-next-prod.vercel.app/mist/) | [Pisces](https://hugo-next-prod.vercel.app/pisces/) |  |
|
||||
| Preliminary | [Gemini](https://preview.hugo-next.eu.org/) | [Muse](https://preview.hugo-next.eu.org/muse/) | [Mist](https://preview.hugo-next.eu.org/mist/) | [Pisces](https://preview.hugo-next.eu.org/pisces/) |  |
|
||||
| Production | [Gemini](https://hugo-next.eu.org/) | [Muse](https://hugo-next.eu.org/muse/) | [Mist](https://hugo-next.eu.org/mist/) | [Pisces](https://hugo-next.eu.org/pisces/) |  |
|
@ -38,6 +38,19 @@
|
||||
img {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
$footer_vendors_imgs_len: length($footer_vendors_imgs_width);
|
||||
@if ($footer_vendors_imgs_len>0) {
|
||||
@for $i from 1 through $footer_vendors_imgs_len {
|
||||
a:nth-child(#{$i}) img {
|
||||
width: #{nth($footer_vendors_imgs_width, $i)}px;
|
||||
|
||||
@include mobile() {
|
||||
width: #{nth($footer_vendors_imgs_width, $i)-10}px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -48,24 +61,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes icon-animate {
|
||||
0%, 100% {
|
||||
transform: scale(1);
|
||||
}
|
||||
|
||||
10%, 30% {
|
||||
transform: scale(.9);
|
||||
}
|
||||
|
||||
20%, 40%, 60%, 80% {
|
||||
transform: scale(1.1);
|
||||
}
|
||||
|
||||
50%, 70% {
|
||||
transform: scale(1.1);
|
||||
}
|
||||
}
|
||||
|
||||
.languages {
|
||||
display: inline-block;
|
||||
font-size: $font-size-large;
|
||||
@ -91,7 +86,7 @@
|
||||
margin: 0 5px;
|
||||
|
||||
@if $footer_icon_animated {
|
||||
animation: icon-animate 1.33s ease-in-out infinite;
|
||||
animation: beat 1.33s ease-in-out infinite;
|
||||
}
|
||||
}
|
||||
|
||||
|
17
assets/css/_common/scaffolding/animation/icon.scss
Normal file
17
assets/css/_common/scaffolding/animation/icon.scss
Normal file
@ -0,0 +1,17 @@
|
||||
@keyframes beat {
|
||||
0%, 100% {
|
||||
transform: scale(1);
|
||||
}
|
||||
|
||||
10%, 30% {
|
||||
transform: scale(.9);
|
||||
}
|
||||
|
||||
20%, 40%, 60%, 80% {
|
||||
transform: scale(1.1);
|
||||
}
|
||||
|
||||
50%, 70% {
|
||||
transform: scale(1.1);
|
||||
}
|
||||
}
|
@ -1,2 +1,3 @@
|
||||
@import 'icon';
|
||||
@import 'show';
|
||||
@import 'hover';
|
@ -23,6 +23,15 @@ $footer_icon_color : {{ $P.footer.icon.color }};
|
||||
$footer_icon_animated : {{ $P.footer.icon.animated }};
|
||||
$footer_beian_enable : {{ $P.footer.beian.enable }};
|
||||
$footer_vendors_enable : {{ isset $P.footer "vendors" }};
|
||||
{{ with $P.footer.vendors }}
|
||||
{{ $width := slice "start" }}
|
||||
{{ range .list }}
|
||||
{{ if .image }}
|
||||
{{ $width = $width | append .image.width }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ printf "$footer_vendors_imgs_width:%s;" (delimit (after 1 $width) ", ") }}
|
||||
{{ end }}
|
||||
|
||||
// Counter
|
||||
$busuanzi_enable : {{ $P.busuanzi.enable }};
|
||||
|
@ -354,14 +354,18 @@ params:
|
||||
vendors:
|
||||
title: 提供CDN/云资源支持
|
||||
list:
|
||||
- name: Webify
|
||||
link: https://webify.cloudbase.net
|
||||
- name: Vercel
|
||||
img: /imgs/vendors/vercel.svg || 55
|
||||
image:
|
||||
url: /imgs/vendors/vercel.svg
|
||||
width: 50
|
||||
link: https://vercel.com
|
||||
- name: 又拍云
|
||||
img: /imgs/vendors/upyun.png || 50
|
||||
image:
|
||||
url: /imgs/vendors/upyun.png
|
||||
width: 43
|
||||
link: https://upyun.com
|
||||
- name: Webify
|
||||
link: https://webify.cloudbase.net
|
||||
|
||||
|
||||
# ---------------------------------------------------------------
|
||||
@ -711,7 +715,7 @@ params:
|
||||
#style: tabs
|
||||
# Choose a comment system to be displayed by default.
|
||||
# Available values: disqus | disqusjs | changyan | livere | gitalk | utterances
|
||||
active: waline
|
||||
active: utterances
|
||||
# Setting `true` means remembering the comment system selected by the visitor.
|
||||
storage: true
|
||||
# Lazyload all comment systems.
|
||||
@ -721,11 +725,11 @@ params:
|
||||
- name: Waline
|
||||
title: Waline
|
||||
color: "#27ae60"
|
||||
weight: 1
|
||||
- name: Utterances
|
||||
title: Utters
|
||||
color: "#494949"
|
||||
weight: 2
|
||||
- name: Utterances
|
||||
title: Utteranc
|
||||
color: "#886ce4"
|
||||
weight: 1
|
||||
|
||||
waline:
|
||||
enable: true
|
||||
@ -734,7 +738,7 @@ params:
|
||||
imgUploader: false
|
||||
wordLimit: 200
|
||||
requiredMeta: ['nick', 'mail']
|
||||
serverURL: "https://waline.js.org"
|
||||
serverURL: #<your waline server url>
|
||||
|
||||
# Disqus
|
||||
# For more information: https://disqus.com
|
||||
@ -766,7 +770,7 @@ params:
|
||||
# You can get your uid from https://livere.com/insight/myCode (General web site)
|
||||
livere:
|
||||
enable: true
|
||||
uid: MTAyMC81MTM4MC8yNzg2MQ== # <your_uid>
|
||||
uid: # <your_uid>
|
||||
|
||||
# Gitalk
|
||||
# For more information: https://gitalk.github.io
|
||||
@ -792,9 +796,9 @@ params:
|
||||
repo: username/repo-name # Github repository owner and name
|
||||
# Available values: pathname | url | title | og:title
|
||||
issueTerm: pathname
|
||||
label: Comments
|
||||
label:
|
||||
# Available values: github-light | github-dark | preferred-color-scheme | github-dark-orange | icy-dark | dark-blue | photon-dark | boxy-light
|
||||
theme: github-light
|
||||
theme: preferred-color-scheme
|
||||
|
||||
# Isso
|
||||
# For more information: https://posativ.org/isso/
|
||||
|
@ -93,9 +93,8 @@
|
||||
<div class="vendors-list">
|
||||
{{- range .list }}
|
||||
<a target="_blank" href="{{ .link }}" title="{{ .name }}">
|
||||
{{- if .img }}
|
||||
{{ $img := split .img "||" }}
|
||||
<img src="{{- trim (index $img 0) " " }}" width="{{- trim (index $img 1) " " -}}px" alt="{{ .name }}" />
|
||||
{{- if .image }}
|
||||
<img src="{{ .image.url }}" alt="{{ .name }}" />
|
||||
{{- else }}
|
||||
{{ .name }}
|
||||
{{- end }}
|
||||
|
Loading…
Reference in New Issue
Block a user