Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add Fontawesome Icons #20

Merged
merged 4 commits into from
Jan 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
# 2.0.1
## _unreleased_
1. [](#new)
- add Fontawesome Icons _(v6.7.2)_ (#20)
- add Image Card Template (#19)
1. [](#bugfix)
- Fix reading time template missing
- Fix reading time template missing (#17)
- Fix transparent navigation bug (#18)
1. [](#improved)
- add translations for admin > pages > modals (navigation)
- add translations for admin > pages > modals (navigation) (#16)

# 2.0.0
## 30-09-2024
Expand Down
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ _Learn more about all the features of Hadron in detail on [tutorials.crabston.ch
- Featured posts for blog
- Built-in Support for Embed.ly
- Built-in Support for H5P
- Newest Fontawesome Icons (v6.7.2)
- more theme customization options
- other enhancements

Expand Down Expand Up @@ -74,6 +75,7 @@ header-dark: false # Inverts the text/logo to work better on dark backg
header-transparent: false # Allows the fixed header to be transparent over the page
sticky-footer: true # Causes the footer to be sticky at the bottom of the page
production-mode: true # In production mode, only minified CSS is used. When disabled, nested CSS with sourcemaps are enabled
fontawesome: # Customize the use of fontawesome icons
favicon: # A custom favicon rather than the theme default (see below for more information)
custom_logo: # A custom logo (see below)
custom_logo_mobile: # A custom logo for mobile devices (see below)
Expand All @@ -83,6 +85,17 @@ To make modifications, you can copy the `user/themes/hadron/hadron.yaml` file to

> NOTE: Do not modify the `user/themes/hadron/hadron.yaml` file directly or your changes will be lost with any updates

### Fontawesome Icons
You can customize the use of Fontawesome icons by setting the `fontawesome` option in the theme configuration file. The options are:

```yaml
fontawesome:
solid: false # Enable solid icons
regular: false # Enable regular icons
brand: false # Enable brand icons
```
If you activate an icon set, the built-in Quark icons (forkawesome) get deactivated. You can enable multiple icons sets at the same time.

### Custom Favicon & Logos
To add a custom favicon/ logo, you should put the favicon/ logo into the `user/themes/hadron/images/logo` folder. Standard image formats are supported (.png, .jpg, .gif, .svg, etc.). Then reference the logo via the YAML like so:

Expand Down
34 changes: 34 additions & 0 deletions blueprints.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,40 @@ form:
1: PLUGIN_ADMIN.ENABLED
validate:
type: bool
fontawesome:
type: section
title: THEME.HADRON.FONTAWESOME.TITLE
underline: true
fontawesome.solid:
type: toggle
label: THEME.HADRON.FONTAWESOME.ENABLE_SOLID.LABEL
highlight: 0
default: 0
options:
0: PLUGIN_ADMIN.DISABLED
1: PLUGIN_ADMIN.ENABLED
validate:
type: bool
fontawesome.regular:
type: toggle
label: THEME.HADRON.FONTAWESOME.ENABLE_REGULAR.LABEL
highlight: 0
default: 0
options:
0: PLUGIN_ADMIN.DISABLED
1: PLUGIN_ADMIN.ENABLED
validate:
type: bool
fontawesome.brand:
type: toggle
label: THEME.HADRON.FONTAWESOME.ENABLE_BRAND.LABEL
highlight: 0
default: 0
options:
0: PLUGIN_ADMIN.DISABLED
1: PLUGIN_ADMIN.ENABLED
validate:
type: bool
quark:
type: tab
title: THEME.QUARK.TITLE
Expand Down
6 changes: 6 additions & 0 deletions css/fontawesome-brands.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions css/fontawesome-regular.min.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/*!
* Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com
* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
* Copyright 2024 Fonticons, Inc.
*/
:host,:root{--fa-style-family-classic:"Font Awesome 6 Free";--fa-font-regular:normal 400 1em/1 "Font Awesome 6 Free"}@font-face{font-family:"Font Awesome 6 Free";font-style:normal;font-weight:400;font-display:block;src:url(../fonts/fontawesome-regular.woff2) format("woff2"),url(../fonts/fontawesome-regular.ttf) format("truetype")}.fa-regular,.far{font-weight:400}
6 changes: 6 additions & 0 deletions css/fontawesome-solid.min.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/*!
* Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com
* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
* Copyright 2024 Fonticons, Inc.
*/
:host,:root{--fa-style-family-classic:"Font Awesome 6 Free";--fa-font-solid:normal 900 1em/1 "Font Awesome 6 Free"}@font-face{font-family:"Font Awesome 6 Free";font-style:normal;font-weight:900;font-display:block;src:url(../fonts/fontawesome-solid.woff2) format("woff2"),url(../fonts/fontawesome-solid.ttf) format("truetype")}.fa-solid,.fas{font-weight:900}
Loading
Loading