mirror of
https://github.com/thomasjsn/hugo-theme-hello-friend.git
synced 2024-11-24 16:55:07 +01:00
Merge branch 'master' into patch-1
This commit is contained in:
commit
ca2c51710a
@ -44,12 +44,6 @@ rules:
|
||||
no-unused-vars:
|
||||
- 2
|
||||
- argsIgnorePattern: "^_"
|
||||
# jsx a11y
|
||||
jsx-a11y/no-static-element-interactions: 0
|
||||
jsx-a11y/anchor-is-valid:
|
||||
- 2
|
||||
- specialLink:
|
||||
- to
|
||||
|
||||
globals:
|
||||
document: true
|
||||
|
1
.gitignore
vendored
1
.gitignore
vendored
@ -1 +1,2 @@
|
||||
node_modules
|
||||
public
|
||||
|
@ -1,5 +1,11 @@
|
||||
{
|
||||
"parser": "babel",
|
||||
"printWidth": 100,
|
||||
"trailingComma": "all"
|
||||
"trailingComma": "all",
|
||||
"overrides": [{
|
||||
"files": ".html",
|
||||
"options": {
|
||||
"parser": "html"
|
||||
}
|
||||
}]
|
||||
}
|
||||
|
17
COMMUNITY-FEATURES.md
Normal file
17
COMMUNITY-FEATURES.md
Normal file
@ -0,0 +1,17 @@
|
||||
# Community features
|
||||
|
||||
<!--
|
||||
Did a cool thing with the theme and want to share it with rest of the Hello Friend theme users? Jump in!
|
||||
|
||||
Please follow the template:
|
||||
|
||||
- **NAME_OF_THE_FEATURE** (LINK TO YOUR FORK)
|
||||
- SHORT DESCRIPTION
|
||||
- SOMETHING ABOUT YOU (name and who you are / what you do / etc.)
|
||||
|
||||
eg:
|
||||
|
||||
- **Social media icons** (https://github.com/...)
|
||||
- This was a big missing feature of the theme. It will help your audience reach you over the internet.
|
||||
- John, a javascript developer.
|
||||
-->
|
78
README.md
78
README.md
@ -2,27 +2,28 @@
|
||||
|
||||
![Hello Friend](https://github.com/panr/hugo-theme-hello-friend/blob/master/images/screenshot.png?raw=true)
|
||||
|
||||
### DEMO - https://hugo-hello-friend.now.sh/
|
||||
### DEMO - https://hugo-hello-friend.now.sh/ <a id="demo" />
|
||||
|
||||
<a href="https://www.buymeacoffee.com/panr" target="_blank"><img src="https://res.cloudinary.com/panr/image/upload/v1579374705/buymeacoffee_y6yvov.svg" alt="Buy Me A Coffee" ></a>
|
||||
|
||||
---
|
||||
|
||||
- [Hello Friend](#hello-friend)
|
||||
- [DEMO - https://hugo-hello-friend.now.sh/](#demo---httpshugo-hello-friendnowsh)
|
||||
- [DEMO - https://hugo-hello-friend.now.sh/](#demo)
|
||||
- [Features](#features)
|
||||
- [Built-in shortcodes](#built-in-shortcodes)
|
||||
- [Code highlighting](#code-highlighting)
|
||||
- [Improved RSS Feed](#improved-rss-feed)
|
||||
- [How to start](#how-to-start)
|
||||
- [How to run your site](#how-to-run-your-site)
|
||||
- [How to configure](#how-to-configure)
|
||||
- [How to add a cover image to your posts](#how-to-add-a-cover-image-to-your-posts)
|
||||
- [How to display the Last Modified Date in your posts](#how-to-display-the-last-modified-date-in-your-posts)
|
||||
- [How to hide "Read more" button](#how-to-hide-read-more-button)
|
||||
- [Add-ons](#add-ons)
|
||||
- [How to run your site](#how-to-run-your-site)
|
||||
- [How to edit the theme](#how-to-edit-the-theme)
|
||||
- [How to contribute](#how-to-contribute)
|
||||
- [How to (safely) edit the theme](#how-to-edit)
|
||||
- [Found a bug?](#bug)
|
||||
- [New cool idea or feature](#feature)
|
||||
- [`Hello Friend` theme user?](#hello-friend-theme-user)
|
||||
- [Sponsoring](#sponsoring)
|
||||
- [License](#license)
|
||||
@ -107,6 +108,18 @@ If you don't want to make any radical changes, it's the best option, because you
|
||||
$ git submodule add https://github.com/panr/hugo-theme-hello-friend.git themes/hello-friend
|
||||
```
|
||||
|
||||
⚠️ **The theme needs at least Hugo version 0.74.x**.
|
||||
|
||||
## How to run your site
|
||||
|
||||
From your Hugo root directory run:
|
||||
|
||||
```
|
||||
$ hugo server -t hello-friend
|
||||
```
|
||||
|
||||
and go to `localhost:1313` in your browser. From now on all the changes you make will go live, so you don't need to refresh your browser every single time.
|
||||
|
||||
## How to configure
|
||||
|
||||
The theme doesn't require any advanced configuration. Just copy:
|
||||
@ -210,37 +223,60 @@ In a post's front matter you have to add `hideReadMore` param set to `true`. Thi
|
||||
- **Extended `<head>`** — if you need to add something inside `<head>` element, after all of all of the theme's `<script>` and `<link>` tags are declared, please take a look at `layouts/partial/extended_head.html` https://github.com/panr/hugo-theme-hello-friend/blob/master/layouts/partials/extended_head.html
|
||||
- **Extended `<footer>`** — if you need to add something before end of `<body>` element, please take a look at `layouts/partial/extended_footer.html` https://github.com/panr/hugo-theme-hello-friend/blob/master/layouts/partials/extended_footer.html
|
||||
|
||||
## How to run your site
|
||||
## How to (safely) edit the theme <a id="how-to-edit" />
|
||||
|
||||
From your Hugo root directory run:
|
||||
If you have to override only some of the styles, you can do this easily by adding `static/style.css` in your root directory and point things you want to change.
|
||||
|
||||
To change something directly in the theme, you have to go to `themes/hello-friend` and modify the files.
|
||||
|
||||
First, you need to install Node dependencies. To do so, go to the theme directory (from your Hugo root directory):
|
||||
|
||||
```bash
|
||||
$ hugo server -t hello-friend
|
||||
$ cd themes/hello-friend
|
||||
```
|
||||
|
||||
and go to `localhost:1313` in your browser. From now on all the changes you make will go live, so you don't need to refresh your browser every single time.
|
||||
then run:
|
||||
|
||||
## How to edit the theme
|
||||
```bash
|
||||
$ npm install
|
||||
$ npm i yarn
|
||||
$ yarn
|
||||
```
|
||||
|
||||
If you have to override some of the styles, you can do this easily by adding `static/style.css` in your root directory and point things you want to change.
|
||||
|
||||
Otherwise, if you really want to edit the theme, you need to install Node dependencies. To do so, go to the theme directory (from your Hugo root directory):
|
||||
After you modified the files you can run webpack in watch mode:
|
||||
|
||||
```bash
|
||||
$ cd themes/hello-friend
|
||||
$ yarn dev
|
||||
```
|
||||
|
||||
and then run:
|
||||
or rebuild theme
|
||||
|
||||
```bash
|
||||
$ npm install
|
||||
$ npm i yarn
|
||||
$ yarn
|
||||
$ yarn build
|
||||
```
|
||||
|
||||
## How to contribute
|
||||
To see the changes (remember to restart `hugo server`).
|
||||
|
||||
If you spot any bugs, please use [Issue Tracker](https://github.com/panr/hugo-theme-hello-friend/issues) or if you want to add a new feature directly please create a new [Pull Request](https://github.com/panr/hugo-theme-hello-friend/pulls).
|
||||
## Found a bug? <a id="bug" />
|
||||
|
||||
If you spot any bugs, please use [Issue Tracker](https://github.com/panr/hugo-theme-hello-friend/issues) or create a new [Pull Request](https://github.com/panr/hugo-theme-hello-friend/pulls) to fix the issue.
|
||||
|
||||
## New cool idea or feature? <a id="feature" />
|
||||
|
||||
The theme is in constant development since 2019 and has got many cool features that helped many of you and made the theme better. But there were also many features that I wasn't sure about because I want to keep the theme as simple as possible.
|
||||
|
||||
So, let's say you have an idea of how to extend the theme. That's cool and you're welcome to do that, just follow these steps:
|
||||
|
||||
- fork the theme
|
||||
- implement the feature
|
||||
- write an instruction how to use the feature
|
||||
- give a working example of the implementation for other users
|
||||
- add info about your work to `COMMUNITY-FEATURES.md`
|
||||
- make a PR with edited `COMMUNITY-FEATURES.md`
|
||||
|
||||
This will help keeping the theme close to its roots, and also allow anyone who wishes to improve it and match their needs, to do whatever they want.
|
||||
|
||||
Sounds OK? Cool, let's rock! 🤘
|
||||
|
||||
## `Hello Friend` theme user?
|
||||
|
||||
@ -254,6 +290,6 @@ If you like my work and want to support the development of the project, now you
|
||||
|
||||
## License
|
||||
|
||||
Copyright © 2019 Radosław Kozieł ([@panr](https://twitter.com/panr))
|
||||
Copyright © 2019-2020 Radosław Kozieł ([@panr](https://twitter.com/panr))
|
||||
|
||||
The theme is released under the MIT License. Check the [original theme license](https://github.com/panr/hugo-theme-hello-friend/blob/master/LICENSE.md) for additional licensing information.
|
||||
|
8
USERS.md
8
USERS.md
@ -8,7 +8,9 @@ TEMPLATE:
|
||||
-->
|
||||
|
||||
- https://0x44.pw — **Ian Pringle** (System Admin and developer)
|
||||
- https://adamormsby.com - **Adam Ormsby** (Generalist Programmer - Web, Mobile, Games)
|
||||
- https://arubacao.com **Christopher Lass** (Software Engineer and DevOps)
|
||||
- https://blog.agate.pw/ - **Marco Agate** (System Engineer, DevOps)
|
||||
- https://blog.agung.io - **Agung Pratama** (Software Engineer and DevOps)
|
||||
- https://blog.jyny.dev/ - **Jyny Chen** (Software Engineer)
|
||||
- https://blog.lepape.me/ - **François Le Pape** (Student & developer freelance)
|
||||
@ -18,8 +20,10 @@ TEMPLATE:
|
||||
- https://etra0.github.io/ - **Sebastián Aedo** (Computer Science student, interested in Game Hacking)
|
||||
- https://fazi1058.github.io **Faezeh Roeinfard** (Student)
|
||||
- https://felixleger.com/ - **Félix Léger** (Sofware Developer and DevOps)
|
||||
- https://gabrielacaesar.com/ - **Gabriela Caesar** (Data journalist)
|
||||
- https://guilhermesteves.dev/ - **Guilherme Esteves** (Software Engineer, Writer, Speaker)
|
||||
- https://ilya-lesikov.com - **Ilya Lesikov** (DevOps, SRE)
|
||||
- https://imgalone.com/ - **Iancu makes games alone** (Indie Game Dev)
|
||||
- https://jonathan.rico.live/ - **Jonathan Rico** (Electronics Engineer)
|
||||
- https://kartiniteknologi.id/ - **Kartini Teknologi team** (Tech podcast)
|
||||
- https://mfaishal.com **Faishal Irawan** (Student)
|
||||
@ -28,7 +32,3 @@ TEMPLATE:
|
||||
- https://protocod.gitlab.io/blog/ **protocod** (Web Developer)
|
||||
- https://simeononsecurity.ch/ - **SimeonOnSecurity)** (Security and Automation Blog)
|
||||
- https://verso.re/ - **Joan Calabrés** (Security Engineer)
|
||||
- https://www.adamormsby.com - **Adam Ormsby** (Generalist Programmer - Web, Mobile, Games)
|
||||
- https://www.gabrielacaesar.com/ - **Gabriela Caesar** (Data journalist)
|
||||
- https://www.imgalone.com/ - **Iancu makes games alone** (Indie Game Dev)
|
||||
|
||||
|
@ -13,7 +13,8 @@ body {
|
||||
padding: 0;
|
||||
font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Roboto", "Segoe UI", Helvetica, Arial, sans-serif;
|
||||
font-size: 1rem;
|
||||
font-weight: 600;
|
||||
font-weight: 500;
|
||||
font-feature-settings: "liga", "tnum", "case", "calt", "zero", "ss01", "locl";
|
||||
line-height: 1.54;
|
||||
background-color: var(--background);
|
||||
color: var(--color);
|
||||
@ -124,7 +125,7 @@ figure {
|
||||
}
|
||||
}
|
||||
|
||||
code {
|
||||
code, kbd {
|
||||
font-family: Consolas,Monaco,Andale Mono,Ubuntu Mono,monospace;
|
||||
background: var(--background-secondary);
|
||||
padding: 1px 6px;
|
||||
@ -132,6 +133,12 @@ code {
|
||||
border-radius: 5px;
|
||||
font-size: .9rem;
|
||||
font-weight: normal;
|
||||
|
||||
code, kbd {
|
||||
background: transparent;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
|
||||
pre {
|
||||
@ -151,7 +158,7 @@ pre {
|
||||
color: #ccc;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
font-size: .9rem;
|
||||
font-size: inherit;
|
||||
}
|
||||
}
|
||||
|
||||
@ -243,3 +250,20 @@ hr {
|
||||
.hidden {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.framed {
|
||||
padding: 20px;
|
||||
border-radius: 10px;
|
||||
border: 1px solid var(--border-color);
|
||||
max-width: 800px;
|
||||
}
|
||||
|
||||
blockquote.twitter-tweet {
|
||||
background: hsl(206deg 62% 45% / 10%);
|
||||
border: none;
|
||||
padding: 30px;
|
||||
color: inherit;
|
||||
font-size: inherit;
|
||||
line-height: inherit;
|
||||
border-radius: 8px;
|
||||
}
|
@ -16,7 +16,7 @@
|
||||
border-right: 1px solid;
|
||||
margin-right: 18px;
|
||||
padding-right: 24px;
|
||||
font-weight: 600;
|
||||
font-weight: 500;
|
||||
|
||||
@media (--phone) {
|
||||
@mixin menu;
|
@ -49,7 +49,7 @@
|
||||
justify-content: center;
|
||||
background: var(--background-secondary);
|
||||
font-size: 1rem;
|
||||
font-weight: 600;
|
||||
font-weight: 500;
|
||||
border-radius: 8px;
|
||||
max-width: 40%;
|
||||
padding: 0;
|
17
assets/css/style.css
Normal file
17
assets/css/style.css
Normal file
@ -0,0 +1,17 @@
|
||||
@import 'fonts.css';
|
||||
@import 'variables.css';
|
||||
@import 'buttons.css';
|
||||
|
||||
@import 'header.css';
|
||||
@import 'logo.css';
|
||||
@import 'menu.css';
|
||||
@import 'main.css';
|
||||
@import 'post.css';
|
||||
@import 'pagination.css';
|
||||
@import 'footer.css';
|
||||
|
||||
@import 'terms.css';
|
||||
@import 'archive.css';
|
||||
|
||||
@import 'prism.css';
|
||||
@import 'code.css';
|
BIN
assets/fonts/Inter-Bold.woff
Normal file
BIN
assets/fonts/Inter-Bold.woff
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-Bold.woff2
Normal file
BIN
assets/fonts/Inter-Bold.woff2
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-BoldItalic.woff
Normal file
BIN
assets/fonts/Inter-BoldItalic.woff
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-BoldItalic.woff2
Normal file
BIN
assets/fonts/Inter-BoldItalic.woff2
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-Italic.woff
Normal file
BIN
assets/fonts/Inter-Italic.woff
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-Italic.woff2
Normal file
BIN
assets/fonts/Inter-Italic.woff2
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-Medium.woff
Normal file
BIN
assets/fonts/Inter-Medium.woff
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-Medium.woff2
Normal file
BIN
assets/fonts/Inter-Medium.woff2
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-MediumItalic.woff
Normal file
BIN
assets/fonts/Inter-MediumItalic.woff
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-MediumItalic.woff2
Normal file
BIN
assets/fonts/Inter-MediumItalic.woff2
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-Regular.woff
Normal file
BIN
assets/fonts/Inter-Regular.woff
Normal file
Binary file not shown.
BIN
assets/fonts/Inter-Regular.woff2
Normal file
BIN
assets/fonts/Inter-Regular.woff2
Normal file
Binary file not shown.
18
babel.config.js
Normal file
18
babel.config.js
Normal file
@ -0,0 +1,18 @@
|
||||
module.exports = function(api) {
|
||||
api.cache(true);
|
||||
|
||||
const presets = [
|
||||
[
|
||||
"@babel/preset-env",
|
||||
{
|
||||
targets: "last 2 versions, >1%, not dead",
|
||||
},
|
||||
],
|
||||
];
|
||||
const plugins = [];
|
||||
|
||||
return {
|
||||
presets,
|
||||
plugins,
|
||||
};
|
||||
};
|
@ -8,6 +8,12 @@
|
||||
{{ end }}
|
||||
{{ $paginator := .Paginate (where $PageContext.RegularPages "Type" $contentTypeName) }}
|
||||
|
||||
{{ if .Content }}
|
||||
<div class="index-content {{ if .Params.framed -}}framed{{- end -}}">
|
||||
{{ .Content }}
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
<div class="posts">
|
||||
{{ range $paginator.Pages }}
|
||||
<div class="post on-list">
|
||||
@ -39,9 +45,9 @@
|
||||
{{ if .Params.Cover }}
|
||||
<figure class="post-cover">
|
||||
{{ if .Params.UseRelativeCover }}
|
||||
<img src="{{ (printf "%s%s" .Permalink .Params.Cover ) }}" />
|
||||
<img src="{{ (printf "%s%s" .Permalink .Params.Cover ) }}" alt="{{ .Title | plainify | default " " }}"/>
|
||||
{{ else }}
|
||||
<img src="{{ .Params.Cover | absURL }}" />
|
||||
<img src="{{ .Params.Cover | absURL }}" alt="{{ .Title | plainify | default " " }}"/>
|
||||
{{ end }}
|
||||
|
||||
{{ if .Params.CoverCaption }}
|
||||
|
@ -30,9 +30,9 @@
|
||||
{{ if .Params.Cover }}
|
||||
<figure class="post-cover">
|
||||
{{ if .Params.UseRelativeCover }}
|
||||
<img src="{{ (printf "%s%s" .Permalink .Params.Cover ) }}" />
|
||||
<img src="{{ (printf "%s%s" .Permalink .Params.Cover ) }}" alt="{{ .Title | plainify | default " " }}" />
|
||||
{{ else }}
|
||||
<img src="{{ .Params.Cover | absURL }}" />
|
||||
<img src="{{ .Params.Cover | absURL }}" alt="{{ .Title | plainify | default " " }}" />
|
||||
{{ end }}
|
||||
|
||||
{{ if .Params.CoverCaption }}
|
||||
|
@ -34,9 +34,9 @@
|
||||
{{ if .Params.Cover }}
|
||||
<figure class="post-cover">
|
||||
{{ if .Params.UseRelativeCover }}
|
||||
<img src="{{ (printf "%s%s" .Permalink .Params.Cover ) }}" />
|
||||
<img src="{{ (printf "%s%s" .Permalink .Params.Cover ) }}" alt="{{ .Title | plainify | default " " }}" />
|
||||
{{ else }}
|
||||
<img src="{{ .Params.Cover | absURL }}" />
|
||||
<img src="{{ .Params.Cover | absURL }}" alt="{{ .Title | plainify | default " " }}" />
|
||||
{{ end }}
|
||||
|
||||
{{ if .Params.CoverCaption }}
|
||||
|
@ -14,4 +14,5 @@
|
||||
|
||||
<script src="{{ "assets/main.js" | absURL }}"></script>
|
||||
<script src="{{ "assets/prism.js" | absURL }}"></script>
|
||||
|
||||
{{- partial "extended_footer.html" . }}
|
||||
|
@ -10,7 +10,6 @@
|
||||
|
||||
<!-- Theme CSS -->
|
||||
<link rel="stylesheet" href="{{ "assets/style.css" | absURL }}">
|
||||
|
||||
<!-- Custom CSS to override theme properties (/static/style.css) -->
|
||||
<link rel="stylesheet" href="{{ "style.css" | absURL }}">
|
||||
|
||||
|
43
package.json
43
package.json
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "hello-friend",
|
||||
"version": "1.0.0",
|
||||
"version": "2.0.0",
|
||||
"main": "index.js",
|
||||
"author": "Radosław Kozieł <@panr> <radoslaw.koziel@gmail.com>",
|
||||
"license": "MIT",
|
||||
@ -19,35 +19,36 @@
|
||||
"@babel/plugin-transform-runtime": "^7.2.0",
|
||||
"@babel/preset-env": "^7.3.1",
|
||||
"@babel/preset-stage-2": "^7.0.0",
|
||||
"babel-eslint": "^8.2.1",
|
||||
"babel-eslint": "^10.1.0",
|
||||
"babel-loader": "^8.0.5",
|
||||
"browserslist": "^4.0.1",
|
||||
"clean-webpack-plugin": "^0.1.19",
|
||||
"clean-webpack-plugin": "^3.0.0",
|
||||
"clipboard": "^2.0.4",
|
||||
"css-loader": "^1.0.1",
|
||||
"css-loader": "^4.2.2",
|
||||
"cssnano": "^4.1.8",
|
||||
"eslint-config-airbnb": "^17.1.0",
|
||||
"eslint-config-prettier": "^2.10.0",
|
||||
"eslint-config-airbnb": "^18.2.0",
|
||||
"eslint-config-prettier": "^6.11.0",
|
||||
"eslint-plugin-jsx-a11y": "^6.2.1",
|
||||
"extract-text-webpack-plugin": "^4.0.0-beta.0",
|
||||
"file-loader": "^1.1.11",
|
||||
"html-webpack-plugin": "^3.2.0",
|
||||
"file-loader": "^6.1.0",
|
||||
"html-webpack-plugin": "^4.4.1",
|
||||
"husky": "^4.2.5",
|
||||
"mini-css-extract-plugin": "^0.11.0",
|
||||
"postcss": "^7.0.0",
|
||||
"postcss-browser-reporter": "^0.5.0",
|
||||
"postcss-cli": "^6.1.1",
|
||||
"postcss-import": "^11.1.0",
|
||||
"postcss-loader": "^2.1.6",
|
||||
"postcss-browser-reporter": "^0.6.0",
|
||||
"postcss-cli": "^7.1.2",
|
||||
"postcss-import": "^12.0.1",
|
||||
"postcss-loader": "^3.0.0",
|
||||
"postcss-mixins": "^6.2.1",
|
||||
"postcss-nested": "^3.0.0",
|
||||
"postcss-preset-env": "^5.3.0",
|
||||
"postcss-reporter": "^5.0.0",
|
||||
"postcss-url": "^7.3.2",
|
||||
"prettier-eslint-cli": "^4.7.1",
|
||||
"ramda": "^0.25.0",
|
||||
"style-loader": "^0.21.0",
|
||||
"uglifyjs-webpack-plugin": "^1.3.0",
|
||||
"url-loader": "^1.1.2",
|
||||
"postcss-nested": "^4.2.3",
|
||||
"postcss-preset-env": "^6.7.0",
|
||||
"postcss-reporter": "^6.0.1",
|
||||
"postcss-url": "^8.0.0",
|
||||
"prettier-eslint-cli": "^5.0.0",
|
||||
"ramda": "^0.27.1",
|
||||
"style-loader": "^1.2.1",
|
||||
"uglifyjs-webpack-plugin": "^2.2.0",
|
||||
"url-loader": "^4.1.0",
|
||||
"webpack": "^4.29.3",
|
||||
"webpack-cli": "^3.2.3"
|
||||
},
|
||||
|
@ -1,17 +0,0 @@
|
||||
@import 'variables';
|
||||
@import 'fonts';
|
||||
@import 'buttons';
|
||||
|
||||
@import 'header';
|
||||
@import 'logo';
|
||||
@import 'menu';
|
||||
@import 'main';
|
||||
@import 'post';
|
||||
@import 'pagination';
|
||||
@import 'footer';
|
||||
|
||||
@import 'terms';
|
||||
@import 'archive';
|
||||
|
||||
@import 'prism';
|
||||
@import 'code';
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1 +0,0 @@
|
||||
// Add your script here
|
BIN
static/assets/1b084c69c69a1b3a2618caed68164471.woff2
Normal file
BIN
static/assets/1b084c69c69a1b3a2618caed68164471.woff2
Normal file
Binary file not shown.
BIN
static/assets/2505c0d4b34ffca98f8f8852e24928eb.woff2
Normal file
BIN
static/assets/2505c0d4b34ffca98f8f8852e24928eb.woff2
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
static/assets/3c747ac4004be3a30e9807662caebaa0.woff2
Normal file
BIN
static/assets/3c747ac4004be3a30e9807662caebaa0.woff2
Normal file
Binary file not shown.
Binary file not shown.
BIN
static/assets/5b53c519b3184a74a98ca6125f513c9d.woff2
Normal file
BIN
static/assets/5b53c519b3184a74a98ca6125f513c9d.woff2
Normal file
Binary file not shown.
Binary file not shown.
BIN
static/assets/642b4659478701575989a8926822356b.woff
Normal file
BIN
static/assets/642b4659478701575989a8926822356b.woff
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
static/assets/86b501b4ef9d20d70996b196b69dc1e7.woff2
Normal file
BIN
static/assets/86b501b4ef9d20d70996b196b69dc1e7.woff2
Normal file
Binary file not shown.
BIN
static/assets/aa42f3d22ea9fae2b945f33b94d180ea.woff
Normal file
BIN
static/assets/aa42f3d22ea9fae2b945f33b94d180ea.woff
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
static/assets/c7c0091f1b2b06064572ec0016f1e142.woff
Normal file
BIN
static/assets/c7c0091f1b2b06064572ec0016f1e142.woff
Normal file
Binary file not shown.
BIN
static/assets/cc6a88688869161eb83642d9393a0c2d.woff
Normal file
BIN
static/assets/cc6a88688869161eb83642d9393a0c2d.woff
Normal file
Binary file not shown.
BIN
static/assets/f25066e37f191178ef56ae1f2f901f92.woff2
Normal file
BIN
static/assets/f25066e37f191178ef56ae1f2f901f92.woff2
Normal file
Binary file not shown.
BIN
static/assets/fa701b4b599a803effc38485e2957ca3.woff
Normal file
BIN
static/assets/fa701b4b599a803effc38485e2957ca3.woff
Normal file
Binary file not shown.
BIN
static/assets/fc49d131f795b4d48f261495d4caef09.woff
Normal file
BIN
static/assets/fc49d131f795b4d48f261495d4caef09.woff
Normal file
Binary file not shown.
@ -1 +1 @@
|
||||
!function(e){var t={};function n(o){if(t[o])return t[o].exports;var r=t[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(o,r,function(t){return e[t]}.bind(null,r));return o},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){n(1),n(2),e.exports=n(3)},function(e,t){},function(e,t){var n=document.querySelector(".container"),o=document.querySelector(".menu"),r=document.querySelector(".menu-trigger"),i=(document.querySelector(".menu__inner--desktop"),document.querySelector(".menu__sub-inner-more-trigger")),c=document.querySelector(".menu__sub-inner-more"),d=getComputedStyle(document.body).getPropertyValue("--phoneWidth"),u=function(){return window.matchMedia(d).matches},l=function(){r&&r.classList.toggle("hidden",!u()),o&&o.classList.toggle("hidden",u()),c&&c.classList.toggle("hidden",!u())};o&&o.addEventListener("click",function(e){return e.stopPropagation()}),c&&c.addEventListener("click",function(e){return e.stopPropagation()}),l(),document.body.addEventListener("click",function(){u()||!c||c.classList.contains("hidden")?u()&&!o.classList.contains("hidden")&&o.classList.add("hidden"):c.classList.add("hidden")}),window.addEventListener("resize",l),r&&r.addEventListener("click",function(e){e.stopPropagation(),o&&o.classList.toggle("hidden")}),i&&i.addEventListener("click",function(e){e.stopPropagation(),c&&c.classList.toggle("hidden"),c&&c.getBoundingClientRect().right>n.getBoundingClientRect().right&&(c.style.left="auto",c.style.right=0)})},function(e,t){var n=window.localStorage&&window.localStorage.getItem("theme"),o=document.querySelector(".theme-toggle"),r="dark"===n;null!==n&&document.body.classList.toggle("dark-theme",r),o.addEventListener("click",function(){document.body.classList.toggle("dark-theme"),window.localStorage&&window.localStorage.setItem("theme",document.body.classList.contains("dark-theme")?"dark":"light")})}]);
|
||||
!function(n){var o={};function r(e){if(o[e])return o[e].exports;var t=o[e]={i:e,l:!1,exports:{}};return n[e].call(t.exports,t,t.exports,r),t.l=!0,t.exports}r.m=n,r.c=o,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)r.d(n,o,function(e){return t[e]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=0)}([function(e,t,n){n(1),e.exports=n(2)},function(e,t){function n(){return window.matchMedia(l).matches}function o(){c&&c.classList.toggle("hidden",!n()),i&&i.classList.toggle("hidden",n()),u&&u.classList.toggle("hidden",!n())}var r=document.querySelector(".container"),i=document.querySelector(".menu"),c=document.querySelector(".menu-trigger"),d=(document.querySelector(".menu__inner--desktop"),document.querySelector(".menu__sub-inner-more-trigger")),u=document.querySelector(".menu__sub-inner-more"),l=getComputedStyle(document.body).getPropertyValue("--phoneWidth");i&&i.addEventListener("click",function(e){return e.stopPropagation()}),u&&u.addEventListener("click",function(e){return e.stopPropagation()}),o(),document.body.addEventListener("click",function(){n()||!u||u.classList.contains("hidden")?n()&&!i.classList.contains("hidden")&&i.classList.add("hidden"):u.classList.add("hidden")}),window.addEventListener("resize",o),c&&c.addEventListener("click",function(e){e.stopPropagation(),i&&i.classList.toggle("hidden")}),d&&d.addEventListener("click",function(e){e.stopPropagation(),u&&u.classList.toggle("hidden"),u&&u.getBoundingClientRect().right>r.getBoundingClientRect().right&&(u.style.left="auto",u.style.right=0)})},function(e,t){var n=window.localStorage&&window.localStorage.getItem("theme"),o=document.querySelector(".theme-toggle"),r="dark"===n;null!==n&&document.body.classList.toggle("dark-theme",r),o.addEventListener("click",function(){document.body.classList.toggle("dark-theme"),window.localStorage&&window.localStorage.setItem("theme",document.body.classList.contains("dark-theme")?"dark":"light")})}]);
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
32
theme.toml
32
theme.toml
@ -1,13 +1,27 @@
|
||||
name = "hello-friend"
|
||||
description = "A simple theme for Hugo. That's it."
|
||||
features = ["blog", "shortcode", "syntax Highlighting"]
|
||||
homepage = "https://github.com/panr/hugo-theme-hello-friend/"
|
||||
license = "MIT"
|
||||
licenselink = "https://github.com/panr/hugo-theme-hello-friend/blob/master/LICENSE.md"
|
||||
description = "A simple theme for Hugo. That's it."
|
||||
homepage = "https://github.com/panr/hugo-theme-hello-friend/"
|
||||
tags = ["blog", "clean", "customizable", "dark", "highlighting", "light", "minimal", "monochromatic", "multilingual", "personal", "responsive", "simple", "technical"]
|
||||
features = ["blog", "shortcode", "syntax Highlighting"]
|
||||
min_version = 0.57
|
||||
min_version = 0.74
|
||||
name = "hello-friend"
|
||||
tags = [
|
||||
"blog",
|
||||
"clean",
|
||||
"customizable",
|
||||
"dark",
|
||||
"highlighting",
|
||||
"light",
|
||||
"minimal",
|
||||
"monochromatic",
|
||||
"multilingual",
|
||||
"personal",
|
||||
"responsive",
|
||||
"simple",
|
||||
"technical",
|
||||
]
|
||||
|
||||
[author]
|
||||
name = "panr"
|
||||
homepage = "https://radoslawkoziel.pl"
|
||||
twitter = "https://twitter.com/panr"
|
||||
homepage = "https://radoslawkoziel.pl"
|
||||
name = "panr"
|
||||
twitter = "https://twitter.com/panr"
|
||||
|
@ -1,6 +1,6 @@
|
||||
const Webpack = require("webpack");
|
||||
const ExtractTextPlugin = require("extract-text-webpack-plugin");
|
||||
const CleanPlugin = require("clean-webpack-plugin");
|
||||
const MiniCssExtractPlugin = require("mini-css-extract-plugin");
|
||||
const { CleanWebpackPlugin } = require("clean-webpack-plugin");
|
||||
const HtmlWebpackPlugin = require("html-webpack-plugin");
|
||||
const UglifyJsPlugin = require("uglifyjs-webpack-plugin");
|
||||
|
||||
@ -8,22 +8,18 @@ const path = require("path");
|
||||
|
||||
const join = (...paths) => path.join(__dirname, ...paths);
|
||||
|
||||
module.exports = {
|
||||
module.exports = (env, { mode }) => ({
|
||||
resolve: {
|
||||
extensions: [".js", ".css"],
|
||||
modules: ["source", "node_modules"],
|
||||
modules: ["assets", "node_modules"],
|
||||
},
|
||||
entry: {
|
||||
"main.js": [
|
||||
join("source", "js", "index.js"),
|
||||
join("source", "js", "menu.js"),
|
||||
join("source", "js", "theme.js"),
|
||||
],
|
||||
"prism.js": join("source", "js", "prism.js"),
|
||||
"style.css": join("source", "css", "style.css"),
|
||||
main: [join("assets", "js", "menu.js"), join("assets", "js", "theme.js")],
|
||||
prism: join("assets", "js", "prism.js"),
|
||||
style: join("assets", "css", "style.css"),
|
||||
},
|
||||
output: {
|
||||
filename: "[name]",
|
||||
filename: "[name].js",
|
||||
path: join("static/assets"),
|
||||
publicPath: "",
|
||||
},
|
||||
@ -55,17 +51,17 @@ module.exports = {
|
||||
},
|
||||
{
|
||||
test: /\.css$/,
|
||||
use: ExtractTextPlugin.extract({
|
||||
fallback: "style-loader",
|
||||
use: [
|
||||
MiniCssExtractPlugin.loader,
|
||||
{
|
||||
loader: "css-loader",
|
||||
options: {
|
||||
minimize: true,
|
||||
modules: true,
|
||||
importLoaders: 1,
|
||||
modules: {
|
||||
localIdentName: "[local]",
|
||||
},
|
||||
import: true,
|
||||
importLoaders: 1,
|
||||
},
|
||||
},
|
||||
{
|
||||
loader: "postcss-loader",
|
||||
@ -76,7 +72,6 @@ module.exports = {
|
||||
},
|
||||
},
|
||||
],
|
||||
}),
|
||||
},
|
||||
],
|
||||
},
|
||||
@ -91,5 +86,15 @@ module.exports = {
|
||||
}),
|
||||
],
|
||||
},
|
||||
plugins: [new CleanPlugin(join("static/assets")), new ExtractTextPlugin("[name]")],
|
||||
};
|
||||
plugins: [
|
||||
new CleanWebpackPlugin({
|
||||
cleanOnceBeforeBuildPatterns: [join("static/assets")],
|
||||
cleanAfterEveryBuildPatterns: [join("static/assets/style.js")],
|
||||
verbose: true,
|
||||
}),
|
||||
new MiniCssExtractPlugin({
|
||||
filename: "[name].css",
|
||||
chunkFilename: "[id].css",
|
||||
}),
|
||||
],
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user