Make WordPress Core

Opened 7 years ago

Closed 6 years ago

#40117 closed defect (bug) (worksforme)

Dashicons in adminbar

Reported by: sebastianpisula's profile sebastian.pisula Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Toolbar Keywords:
Focuses: Cc:


I try add to admin bar option with Dashicon, for example:

                                'id'    => 'test',
                                'title' => '<span class="dashicons dashicons-admin-links"></span> Label',

and I don't see icon. Why ? Css for wpadminbar overwrite font family for dashicons:

#wpadminbar *{
    font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",sans-serif;

Change History (2)

#1 @swissspidy
7 years ago

  • Component changed from General to Toolbar
  • Keywords close added

IIRC you'd need to use the ab-icon class if you add the icon like this.

#2 @danieltj
6 years ago

  • Keywords close removed
  • Milestone Awaiting Review deleted
  • Resolution set to worksforme
  • Status changed from new to closed

Correct, the .ab-icon class needs to be added.

Note: See TracTickets for help on using tickets.