mirror of
https://github.com/CaiJimmy/hugo-theme-stack.git
synced 2024-11-27 04:03:48 +01:00
feat(style): remove timeago.js, and improve article-time style
This commit is contained in:
parent
4bf9d82961
commit
af487e0f3f
3 changed files with 3 additions and 15 deletions
|
@ -109,13 +109,12 @@
|
|||
svg {
|
||||
vertical-align: middle;
|
||||
margin-right: 8px;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
time {
|
||||
font-size: 16px;
|
||||
@media (max-width: $on-desktop) {
|
||||
font-size: 14px;
|
||||
}
|
||||
font-size: 1.4rem;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -9,14 +9,6 @@ let Stack = {
|
|||
*/
|
||||
menu();
|
||||
|
||||
/**
|
||||
* Add timeago
|
||||
*/
|
||||
const timeagoElements = document.querySelectorAll('article time[data-timeago=true]');
|
||||
if (timeagoElements.length) {
|
||||
timeago.render(timeagoElements);
|
||||
}
|
||||
|
||||
if (document.querySelector('.article-content')) {
|
||||
createGallery('.article-content');
|
||||
}
|
||||
|
|
|
@ -1,6 +1,3 @@
|
|||
<script src="https://cdn.jsdelivr.net/npm/timeago.js@4.0.2/dist/timeago.min.js"
|
||||
integrity="sha256-sTurDi2etLN9CpnUIoCC9y5iynb2qr/uo6QJqzoO7mA=" crossorigin="anonymous"></script>
|
||||
|
||||
<script src="https://cdn.jsdelivr.net/npm/node-vibrant@3.1.5/dist/vibrant.min.js"
|
||||
integrity="sha256-5NovOZc4iwiAWTYIFiIM7DxKUXKWvpVEuMEPLzcm5/g=" crossorigin="anonymous"></script>
|
||||
|
||||
|
|
Loading…
Reference in a new issue