portio-hugo icon indicating copy to clipboard operation
portio-hugo copied to clipboard

Configure header footer

Open AutomateAaron opened this issue 5 years ago • 7 comments
trafficstars

This PR adds the following configuration options to the config.toml:

footerButtonTarget = "/contact"
footerButtonText = "Get in Touch"
footerCallToAction = "Let's Start a Project"
footerTopTitle = "Contact me"

headerButtonTarget = "/contact"
headerButtonText = "Hire Me Now"

AutomateAaron avatar Oct 06 '20 03:10 AutomateAaron

@kausarpial also, I'm happy to merge any conflicts between these branches if you can just give a ✔️ on the reviews.

AutomateAaron avatar Oct 06 '20 03:10 AutomateAaron

@kausarpial also, I'm happy to merge any conflicts between these branches if you can just give a ✔️ on the reviews.

Hi @AaronNBrock, Please use absURL in the links and please remove / from the front of the links. Otherwise, it won't work on the live link on themes.gohugo.io.

kausarpial avatar Oct 06 '20 14:10 kausarpial

@kausarpial I was following example on the hugo documentation

The URLs must be relative to the context root. If the baseURL is https://example.com/mysite/, then the URLs in the menu must not include the context root mysite. Using an absolute URL will override the baseURL. If the value used for URL in the above example is https://subdomain.example.com/, the output will be https://subdomain.example.com.

Using absURL strips off the #id from the links which breaks the smoothscrolling, do you know if relURL would work?

AutomateAaron avatar Oct 06 '20 15:10 AutomateAaron

@kausarpial I was following example on the hugo documentation

The URLs must be relative to the context root. If the baseURL is https://example.com/mysite/, then the URLs in the menu must not include the context root mysite. Using an absolute URL will override the baseURL. If the value used for URL in the above example is https://subdomain.example.com/, the output will be https://subdomain.example.com.

Using absURL strips off the #id from the links which breaks the smoothscrolling, do you know if relURL would work?

Yeah, I also face that kind of problem for the #id. I think we should compromise that. Because it's hosted on a directory in the themes.gohugo.io instead of a subdomain. Let me know if you find a better solution.

kausarpial avatar Oct 06 '20 15:10 kausarpial

How do other themes do it? I feel we can't be the first to come across this issue.

AutomateAaron avatar Oct 06 '20 15:10 AutomateAaron

Can you suggest a theme with that functionality? It'd be great if we can do that. I'll also do some research on that too.

kausarpial avatar Oct 06 '20 15:10 kausarpial

This theme: hugo-profile

Is using {{ .Url }} w/o any relURL or absURL: header.html#L28

For reference, this is how the item is defined: config.yaml#L34

And is seems to work okay on the demo page.

AutomateAaron avatar Oct 12 '20 16:10 AutomateAaron