Added click events to buttons. Updated UI components for easier relative layout generation.