@@ -0,0 +1,720 @@
+package rapanui.ui;%0A%0Aimport java.awt.Dimension;%0Aimport java.awt.event.ActionEvent;%0Aimport java.awt.event.ActionListener;%0A%0Aimport javax.swing.JButton;%0Aimport javax.swing.JComponent;%0A%0Aclass CollapseButton extends JButton implements ActionListener %7B%0A%09boolean isCollapsed;%0A%09JComponent%5B%5D targets;%0A%0A%09public CollapseButton(JComponent... targets) %7B%0A%09%09this.targets = targets;%0A%09%09isCollapsed = !targets%5B0%5D.isVisible();%0A%09%09addActionListener(this);%0A%09%7D%0A%0A%09@Override%0A%09public String getText() %7B%0A%09%09return isCollapsed ? %22%5CuD83D%5CuDF82%22 : %22%5CuD83D%5CuDF83%22;%0A%09%7D%0A%0A%09@Override%0A%09public void actionPerformed(ActionEvent arg0) %7B%0A%09%09isCollapsed = !isCollapsed;%0A%09%09for (JComponent target : targets)%0A%09%09%09target.setVisible(!isCollapsed);%0A%09%09revalidate();%0A%09%7D%0A%7D%0A

add a helper button class for collapsible stuff