Skip to content

[BUG] When use icon on navbar there are no text #1642

@alohl669

Description

@alohl669

Describe the bug

Related to #1640
Looks like is not possible to show an icon near the text on navbar area.

To reproduce

Steps to reproduce the behavior:

  1. Create a menus.toml on config/_default/menus/menus.toml (not multilingual website)
  2. Use this example
[[main]]
  name = "Blog"
  weight = 10
  url = "/blog/"
  pre = "fas newspaper"

[[main]]
  name = "Podcast"
  weight = 20
  url = "/podcast/"
  pre = "fas microphone"

[[main]]
  name = "food"
  weight = 30
  url = "/food/"
  pre = "fas plate-wheat"

[[main]]
  name = "about"
  weight = 40
  url = "/about/"
  pre = "fas info-circle"
  1. run hugo server

Expected behavior

I did'n know if it was possible to put text + icon on the navbar on desktop display, I thougt that I was doing something wrong. So I asked on the discussion section because looks that is a real feature but only works using a cellphone view.

See the screenshots for more details.

Log file

Not visible errors

Watching for changes in /home/alohl669/code/RESEARCH/hugo/website/{archetypes,assets,content,data,i18n,layouts,static}
Watching for config changes in /home/alohl669/code/RESEARCH/hugo/website/hugo.toml, /home/alohl669/code/RESEARCH/hugo/website/config/_default, /home/alohl669/code/RESEARCH/hugo/website/config/_default/menus, /home/alohl669/code/RESEARCH/hugo/website/go.mod
Start building sites … 
hugo v0.152.2-6abdacad3f3fe944ea42177844469139e81feda6+extended linux/amd64 BuildDate=2025-10-24T15:31:49Z VendorInfo=snap:0.152.2


                  │ EN  
──────────────────┼─────
 Pages            │  78 
 Paginator pages  │   2 
 Non-page files   │   2 
 Static files     │ 109 
 Processed images │  60 
 Aliases          │   6 
 Cleaned          │   0 

Built in 2129 ms
Environment: "development"
Serving pages from disk
Running in Fast Render Mode. For full rebuilds on change: hugo server --disableFastRender
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1) 
Press Ctrl+C to stop

Screenshots

Cellphone view

Image

desktop view

Image

Host environment

Please complete the following information where applicable.

Hugo environment

Copy the output of hugo env or npm run env here.

hugo v0.152.2-6abdacad3f3fe944ea42177844469139e81feda6+extended linux/amd64 BuildDate=2025-10-24T15:31:49Z VendorInfo=snap:0.152.2
GOOS="linux"
GOARCH="amd64"
GOVERSION="go1.25.3"
github.com/sass/libsass="3.6.6"
github.com/webmproject/libwebp="v1.3.2"
github.com/sass/dart-sass/protocol="3.2.0"
github.com/sass/dart-sass/compiler="1.93.2"
github.com/sass/dart-sass/implementation="1.93.2"

Additional context

I just thought that I was doing something wrong or I miss something seeing the docs. Thanks to @markdumay to ask me to report it

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions