gurusabarish / hugo-profile

A highly customizable and mobile first Hugo template for personal portfolio and blog.
https://hugo-profile.netlify.app
MIT License
760 stars 432 forks source link

Change order of content/menu items #106

Open rbcavanaugh opened 1 year ago

rbcavanaugh commented 1 year ago

Hi - thanks for a great template. Is it possible to change the order of the content on the page (and the corresponding menu items?)

Also - Are the 'plus signs' on the left of the page intentional? Is there a way to remove them?

image
gurusabarish commented 1 year ago

Hi @rbcavanaugh

Is it possible to change the order of the content on the page (and the corresponding menu items?)

Currently, we can align the menu items. I will add content alignment in future.

Also - Are the 'plus signs' on the left of the page intentional? Is there a way to remove them?

added option to remove in https://github.com/gurusabarish/hugo-profile/commit/e26564cde65d060e4e7406e8f9cde7f20cecc017

Thanks,

hrokr commented 8 months ago

@rbcavanaugh -- I can answer these.

Double plus signs: In hugo.yaml, if you have this as true and there is no image, then two columns of + will be on the far left. To fix it, set to false.

bottomImage:
         enable: false

Unfortunately, this doesn't fix the wonky spacing.

Menu items: Toggle the title/link in the header: hugo.yaml --> navbar --> menus The order of items in the header is controlled by header.html The order of the actual sections is controlled by index.html

rvqzs commented 2 months ago

Hi @rbcavanaugh,

Is it possible to change the order of the content on the page (and the corresponding menu items?)

Yes, you can definitely change the order of the content on the page and the corresponding menu items by adjusting their weight values in the config.yaml file.

In Hugo, the weight property in the config.yaml file controls the order of navigation items. Items with lower weights appear before those with higher weights.

For example, if you want one item to appear before another, assign it a lower weight value.

Here’s how you can set it up:

Example config.yaml Configuration:

Menus:
  main:
    # Dropdown menu
    - identifier: dropdown
      title: mainMenu
      name: Menu
      weight: 1  # This will appear before the Blog item

    - identifier: blog
      name: Blog
      title: Blog posts
      url: /blogs
      weight: 2  # This will appear after the Menu item

In this configuration:

Visual Example:

Navigation Menu Example

I hope this helps!