Grasshopper c# error (cs0012)

hi i’m getting an error on one of the c# elements in my gh file:
Error (CS0012): The type ‘Rhino.UI.Interfaces.IGradient’ is defined in an assembly that is not referenced. You must add a reference to assembly ‘Rhino.UI, Version=7.6.21127.19001, Culture=neutral, PublicKeyToken=552281e97c755530’.

the error is pointing at the line:
private Grasshopper.GUI.Gradient.GH_Gradient _gradient;

i’ve tried to search about the error but no luck. would be great if anyone could help. thank you.

Right click on C# component > Manage assemblies > Add > locate Rhino.UI.dll in the Rhino System folder (C:/ProgramFiles/Rhino 7/System) > OK.

thank you v much!!!

Thanks Dani, this should really be fixed in Grasshopper. I added this as a bug to our bugtracker at
https://mcneel.myjetbrains.com/youtrack/issue/RH-64845