refactored menu creation