rhazdon / hugo-theme-hello-friend-ng

Pretty basic theme for Hugo that covers all of the essentials. All you have to do is start typing!
https://github.com/rhazdon/hugo-theme-hello-friend-ng/
Other
1.45k stars 765 forks source link

Move code out of params author key #456

Open ytrepidorosonomous opened 8 months ago

ytrepidorosonomous commented 8 months ago

All the code below in your config is under the [params.author key. You need to move it

dateform        = "Jan 2, 2006"
  dateformShort   = "Jan 2"
  dateformNum     = "2006-01-02"
  dateformNumTime = "2006-01-02 15:04"

  # Metadata mostly used in document's head
  # 
  description = "Nice theme for homepages and blogs"
  keywords = ""
  images = [""]

  # Home subtitle of the index page.
  #
  homeSubtitle = "Hello Friend NG"

  # Set a background for the homepage
  # backgroundImage = "assets/images/background.jpg"

  # Prefix of link to the git commit detail page. GitInfo must be enabled.
  #
  # gitUrl = ""

  # Set disableReadOtherPosts to true in order to hide the links to other posts.
  #
  disableReadOtherPosts = false

  # Enable theme toggle
  # 
  # This options enables the theme toggle for the theme. 
  # Per default, this option is off. 
  # The theme is respecting the prefers-color-scheme of the operating system. 
  # With this option on, the page user is able to set the scheme he wants. 
  enableThemeToggle = false

  # Sharing buttons
  #
  # There are a lot of buttons preconfigured. If you want to change them,
  # generate the buttons here: https://sharingbuttons.io
  # and add them into your own `layouts/partials/sharing-buttons.html`
  #
  enableSharingButtons = true

  # Global language menu
  #
  # Enables the global language menu.
  #
  enableGlobalLanguageMenu = true

  # Integrate Javascript files or stylesheets by adding the url to the external assets or by
  # linking local files with their path relative to the static folder, e.g. "css/styles.css"
  #
  customCSS = []
  customJS  = []

  # Toggle this option need to rebuild SCSS, requires extended version of Hugo
  #
  justifyContent = false  # Set "text-align: justify" to .post-content.

  # Integrate Plausible.io
  # plausibleDataDomain = 'test.com'
  # plausibleScriptSource = 'https://plausible.io/js/script.js'
gefloh commented 7 months ago

Yes you're right. At first I was thinking the toml spec has changed...

Also line https://github.com/rhazdon/hugo-theme-hello-friend-ng/blob/51e697bea7eb265c5b6bc532636bb4c707a84173/layouts/partials/footer.html#L6 has to be changed from .Site.Author.name to .Site.Params.Author.name otherwise the author won't show up in the footer.

Edit: For the latter see already existing PR #455 .