Commit graph

116 commits

Author SHA1 Message Date
Melroy van den Berg 2cfb09e9a3
theme(fix): add transform.Plainify to the summary body content of the share links (#758)
You definitely want to **add Plainify transformer first**, because the
body content will become a HTML encoding mess. I left `HTMLEscape` there
as well, just be sure for security reasons. But if you want, I can
remove the second transformer.

Like a tweet on X will look like this:


![image](https://github.com/user-attachments/assets/73ab37b0-decc-47a4-8bbd-cf43cbef1641)


After implementing `transform.Plainify`, it will look much better:


![image](https://github.com/user-attachments/assets/962ba515-72ae-4b46-827f-2c477358d065)

(ignore the red, I don't have X premium pro blabla, it's red because I
hit the max limit of chars)

Signed-off-by: Melroy van den Berg <melroy@melroy.org>
2024-10-24 05:56:04 +07:00
Melroy van den Berg 12cd81b681
theme(fix) social share cache (#755)
Do NOT use the same cache name for social _share_ and social _follow_..

This will never work of course.

Signed-off-by: Melroy van den Berg <melroy@melroy.org>
2024-10-22 17:53:04 +07:00
Cyrill Raccaud 5a1776455f
complete the feature for the cover dimming class in page (#732)
- feature already present for site
- add info for the param to the example

Like https://github.com/theNewDynamic/gohugo-theme-ananke/pull/702, this
PR wants to add the cover class to the page as well, but adds also the
documentation to the example and allows both for page params and site
params.

Solves https://github.com/theNewDynamic/gohugo-theme-ananke/issues/696
in a proper way for site and page with fallback and documentation in the
example.

Default:

<img width="1512" alt="Bildschirmfoto 2024-10-12 um 14 47 12"
src="https://github.com/user-attachments/assets/fbbec618-2045-4be7-94d7-09169a253a96">

Same as default `cover_dimming_class = bg-black-60`:

<img width="1512" alt="Bildschirmfoto 2024-10-12 um 14 47 12"
src="https://github.com/user-attachments/assets/fbbec618-2045-4be7-94d7-09169a253a96">

`cover_dimming_class = bg-black-20`:

<img width="1512" alt="Bildschirmfoto 2024-10-12 um 14 47 20"
src="https://github.com/user-attachments/assets/7bf64564-4f6d-42c9-bed1-83b426d487ae">

`cover_dimming_class = bg-black-90`:

<img width="1512" alt="Bildschirmfoto 2024-10-12 um 14 47 34"
src="https://github.com/user-attachments/assets/354a0e49-7446-46d7-adc1-f8e4ecee3831">


**Closing issues**

closes #702
closes #696

---------

Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
Co-authored-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-21 15:48:03 +07:00
Cyrill Raccaud 9fc4b73a36
theme(fix): header image positioning (#731)
Currently, the header image for a post is `bg-top`, but it would be nice
the control this behavior to lets say `top|center|bottom`, as often the
interesting part of an image is in the center. Using the
`featured_image_class` param, one can now customize the class to control
the alignment of the featured header image. It is also possible to add
additional classes for further customization if needed.


Default case:

<img width="1512" alt="Bildschirmfoto 2024-10-12 um 14 23 10"
src="https://github.com/user-attachments/assets/477bafd2-e50a-44bf-93df-2289cb8380b2">

Same as default case but set explicitly `featured_image_class = cover
bg-top`:

<img width="1512" alt="Bildschirmfoto 2024-10-12 um 14 23 10"
src="https://github.com/user-attachments/assets/477bafd2-e50a-44bf-93df-2289cb8380b2">

`featured_image_class = cover bg-center`:

<img width="1512" alt="Bildschirmfoto 2024-10-12 um 14 23 27"
src="https://github.com/user-attachments/assets/7bae039d-d31b-405b-b5c0-0dc9e13a4f8c">

`featured_image_class = cover bg-bottom`:

<img width="1512" alt="Bildschirmfoto 2024-10-12 um 14 23 36"
src="https://github.com/user-attachments/assets/52dc14cd-2a30-4763-ae90-353d10fb34e7">

`featured_image_class = contain bg-top`:

<img width="1512" alt="Bildschirmfoto 2024-10-12 um 14 29 16"
src="https://github.com/user-attachments/assets/1ee6f371-f2b4-4740-924d-9ea6c1a44df8">

**Code formatting**

<!-- See the simple style guide. -->

**Closing issues**

Closes #729
2024-10-21 14:57:39 +07:00
Patrick Kollitsch cc6da237ea
theme(fix): use internal methods to evaluate environment
closes #625
closes #733
closes #453
closes #574

Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-21 10:03:45 +07:00
Patrick Kollitsch a9cd70d1e6
theme(fix): bring some logic into /disabled sharing
Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-21 06:54:33 +07:00
Patrick Kollitsch 825ea52af9
theme(fix): cleanup unused functions
Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-21 06:02:43 +07:00
Patrick Kollitsch 14eeb655ce
theme(fix): hover color for social icons
Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-21 05:59:52 +07:00
Patrick Kollitsch d9f9cb513f
theme(feat): social share links (wip)
Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-21 05:46:32 +07:00
Patrick Kollitsch 8762f563f9
theme(fix): making sure the noopener rel attribute stays even with other configurations
Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-20 17:23:51 +07:00
Patrick Kollitsch 7913086a0f
theme(fix): add labels and label override functionality
Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-20 15:58:53 +07:00
Patrick Kollitsch 9254c455c9
theme(fix): override profile link generation with full link
Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-20 15:27:19 +07:00
Patrick Kollitsch 4f3e709d83
theme(feat): social media follow links
documentation will follow at https://github.com/theNewDynamic/gohugo-theme-ananke/wiki/Social-media-network-setup

Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-10-20 12:47:56 +07:00
Patrick Kollitsch 321680f6ee
theme(fix): replace deprecated resources.ToCSS with css.Sass
fixes #712

Signed-off-by: Patrick Kollitsch <patrick@davids-neighbour.com>
2024-09-17 23:31:24 +07:00
Melroy van den Berg c086834f0e
Change to /intent/tweet (#652)
Change from /share to /intent/tweet.
2023-09-19 11:47:32 -04:00
Aren Siekmeier 6affbfb0dd
fix permissions (#581) 2022-12-14 09:56:24 -05:00
James Henstridge 5f5dfb15e8
assets: update mastodon logo in social links (#597)
* assets: replace Mastodon logo

The new version is based on the logo-black.svg file distributed from
https://joinmastodon.org/branding, adjusted to match the metrics of the
other social logos.

* layouts: change the color for the mastodon social link

I've picked a purple from https://joinmastodon.org/branding.
2022-12-14 09:55:14 -05:00
Regis Philibert a0c7382c59
Fix duplicate rel attributes on social-follow 2022-12-02 16:32:01 -05:00
Regis Philibert 6b66dc32d4
Add a rel option to social registers (#596)
* Add a `rel` option to social registers

Fixes #417

* Fix typo
2022-12-02 14:22:06 -05:00
Regis Philibert b393088d09
Make sure only the title closest to content is an h1, (#585)
not the hero's.

Fixes #584
2022-10-31 11:34:59 -04:00
James Henstridge 5a8b531a7c
Improve links for sitemap and taxonomies (#569)
* layouts: use absURL to construct absolute URLs instead of concatenating with .Site.BaseURL

* layouts: let hugo generate URLs to taxonomy terms

* layouts: link to current language's home page in the site footer
2022-09-07 08:36:32 -04:00
Regis Philibert 470ea40982
Only apply the absURL on images served through satic directory (#557)
This will solve the subdirectory edge case without communication

Fixes #556
2022-06-10 15:36:57 -04:00
Regis Philibert a98a70782c
Enable/Disable Social follow/share per service (#550)
* This allows user to set `follow: false` on a service to see it removed from the list of socials throughout.

Fixes #547

* Update README
2022-05-06 11:26:54 -04:00
Regis Philibert c49009b823 Only add html[dir] attr if languageDirection is explicitly set 2022-04-21 14:23:44 -04:00
Meir Kriheli 19242fd2f8
Added support for Right-To-Left languages (#532)
* Added support for Right-To-Left languages

* Added language-direction partial
2022-04-21 14:17:49 -04:00
Regis Philibert 751ac93c1b
Upgrade "minVersion" of theme to 84 (#543)
* Upgrade "minVersion" of theme to 84

Check hugo.IsExtended before trying to process scss files

Fixes #541
2022-04-21 11:48:54 -04:00
Regis Philibert d4e5a698a8 Update exampleSite 2022-02-11 14:54:39 -05:00
Regis Philibert ca04e6b567 Revert 36c029abb9 2022-02-11 14:51:50 -05:00
Jack 6045d7891c
433 fix tags layout (#472)
* Added tags class to tags list

* display tags inline

* Added di class to list

* Removed tags class
2022-02-02 11:45:48 -05:00
Regis Philibert baaf9476db Remove template tags from socials SVGs
Fixes #505
2022-02-02 10:15:01 -05:00
Regis Philibert 8cd36f504e
Use .Render for summary and summary-with-image throughout (#498) 2022-01-19 11:24:13 -05:00
Troy Lindsay 36c029abb9
Fix support for site config featured image (#489) (#490)
* Unintentionally caused by #474
2022-01-12 12:16:02 -05:00
Troy Lindsay 3789b8edae
Standardize featured_image logic (#473) (#474) 2022-01-10 15:24:14 -05:00
Regis Philibert 57e38aad38
Make disable_share settings on both page and site level (#465)
Fixes #438
2021-12-23 16:50:08 -05:00
Regis Philibert 3592ce1c03 Re-introducing site-scripts partial for user to overwrite
Fixes #464
2021-12-23 16:33:51 -05:00
Regis Philibert 73a363ca52
Fix _styles.css bad reference in GetMainCSS (#463)
Fixes #459
2021-12-23 16:02:15 -05:00
Regis Philibert 1f11fbe012
Featured image detection refactoring: (#462)
We look for .Params.featured_image
If found > we use that as URL
If we find a Page resource matching the value of the above, we use its .RelPermalink
If none of the above we look for an resource whose filepath contains `featured` or `cover` and use its .RelPermalink if found

Fixes #233
Fixes #407
2021-12-23 15:45:27 -05:00
Regis Philibert f078a2b4d9 Fixes #332
Fixes #333
2021-12-23 14:52:38 -05:00
Regis Philibert c7b9901e01
Refactor social service logic and UX (#425)
* Start of work

* Refactor social service logic

Update README

Fixes #422

* Add URL to contributors instuctions

* Add tiktok
2021-12-02 15:22:18 -05:00
Joel S Aufrecht 3710f7e92a
added tiktok to available social media links (#444) 2021-11-16 09:15:28 -05:00
Sarah Grefalda 08d842f171
Use i18n for site navigation link tooltips (#392) 2021-10-01 13:20:46 -04:00
Jan Steinke e3f7fbe39d
enable hosting the website also on other domains (#355) 2021-07-14 09:29:08 -04:00
Regis Philibert 6a8f9511aa Fix resource transformation
Fixes #426
2021-06-17 09:21:34 -04:00
Regis Philibert 6eb54ab5fd
Refactor styling to drop PostCSS (#424)
Update custom_css logic (ensure retrocompat)

Fixes #423
2021-06-15 09:58:27 -04:00
Regis Philibert ffd9d903c9
Add optional processing of styles with Hugo Pipes (#387)
* Using resources.PostCSS to handle stylesheets

* Allow optional processing of assets through Hugo Pipes

* We can settle with 0.64.0
2021-01-19 15:43:02 -05:00
Jan Steinke a7f88bb583
use RelPermalink for i18n menu (#353) 2020-10-13 08:16:45 -04:00
Sean 5001b28387
Add automatic cover image support (#303)
* Add support for auto-detection of featured images.

* Rename Partial, Add Documentation

Renamed the partial to func/GetFeaturedImage.html.

Additionally added more documentation in the partial to explain how it
worked, and what values were returned.

Co-authored-by: Sean Zimmermann <sz2243@columbia.edu>
2020-06-23 09:34:09 -04:00
Tanner Smith 9171519154
Site logo (#284)
* Add the option to use a logo for the top left site title
2020-06-03 16:26:29 -05:00
Tanner Smith 9752a70c09
Add head partial (#285)
* Add head-additions partial
2020-06-03 16:01:01 -05:00
nickjwhite 4cf0842964
Use relative URL for favicon (#251)
This fixes sites which have the baseURL in a subdirectory.

Co-authored-by: Nick White <git@njw.name>
2020-06-03 10:17:41 -04:00