Skip to main content
Question

Is it possible to replace the 'Sticky' icon with CSS or third party scripts?

  • September 18, 2024
  • 4 replies
  • 40 views

DannyPancratz
Forum|alt.badge.img+9

Can I replace the bookmark icon with something else? 

Based on some other questions, it seems like it’d be possible. 

4 replies

Kenneth R
Forum|alt.badge.img+5
  • Expert ⭐️⭐️
  • September 23, 2024

This is a tricky one @DannyPancratz - I tried a few things before the weekend but couldn’t get it working.  I’ve asked our more technical folks.  :)


Kenneth R
Forum|alt.badge.img+5
  • Expert ⭐️⭐️
  • September 23, 2024

Hey @DannyPancratz - it looks like this works:

  .icon--star:before   {
color:transparent!important;
}

.icon--star:before {
background-repeat: no-repeat;
background-position:top;
background-image: url('newimagelink.png');
}

 


DannyPancratz
Forum|alt.badge.img+9
  • Author
  • VIP ⭐️⭐️⭐️⭐️⭐️
  • September 23, 2024

@Kenneth R thanks, but that didn’t quite work for me. It changed the star of the Favorite/Subscribe icon, not the bookmark icon for sticky. 

I assume a similar CSS approach will probably work if I can identify the correct target for the bookmark icon. 

Also, I just reported what I think is a bug: the Sticky label seems to no longer be showing when you click into a sticky topic. 


Kenneth R
Forum|alt.badge.img+5
  • Expert ⭐️⭐️
  • September 24, 2024

Ah sorry @DannyPancratz - I misunderstood and thought you meant the subscribe icon.  The bookmark icon is an SVG that’s defined by .topic-view_sticky-flag.  For this one it should also be possible to override it with an SVG from another library or update the fill colour via CSS.