Updated the main class with JComponent and added a serial version ID.