Added a UiUtils class to provide useful functions for user interface components.