design isOpen, open, and main