Base class for UIElement that handle resources
see Text see Image
Returns the resource of the UI element if exists