[FIXED] Seting link icon changes all icons within the link

According to documentation, to make a component clickable I put it within a link component. However, if I change the link icon, all icons within the link change. Is this a bug or I am missing something?

Here is the simple code to test it:

from anvil import *

class Links(LinksTemplate):
  def __init__(self, **properties):
    # Set Form properties and Data Bindings.
    self.init_components(**properties)
    
    # Any code you write here will run when the form opens.
    self.label = Label(icon='fa:plus')
    self.link = Link()
    self.link.add_component(self.label)
    self.add_component(self.link)
    self.link.icon = 'fa:minus' # Both icons change to minus
    print(self.label.icon) # Outputs 'fa:plus'
    
    # Uncomment to change icon back to plus
    # self.label.icon = 'fa:plus'

I concur, and that does seem wrong.

The visible icon changes on both but the icon properties seem, programmatically, to be correct.

Yep, that’s a bug! Moving to Bug Reports.

1 Like

Hey @meredydd, it looks like this is fixed. That was quick! :smile:

Are there any public release notes or a change log? I would like to see when a new version is released and possibly what is fixed.

1 Like