lib/cli.rb
def gallery_menu

        puts "Please select a number from the list present to learn more about a gallery".black.on_white
        user_input=gets.chomp

        if !user_input.to_i.between?(1,Galleries.all.count)
            puts "Please choose a valid number".black.on_white
            list_gallery
            gallery_menu
        else 
            gallery=Galleries.all[user_input.to_i - 1]
            gallery_details(gallery)
            explore_gallery(gallery)
        end 

    end
#GALLERY: Asks User to make a selection from gallery list, checks validility of selection, and, if valid, calls on gallery_details
Asks User to make a selection from gallery list, checks validility of selection, and, if valid, calls on gallery_details
Asks User to make a selection from gallery list checks validility of selection and if valid calls on gallery_details
def gallery_menu
        puts "Please select a number from the list present to learn more about a gallery".black.on_white
        user_input=gets.chomp
        if !user_input.to_i.between?(1,Galleries.all.count)
            puts "Please choose a valid number".black.on_white
            list_gallery
            gallery_menu
        else 
            gallery=Galleries.all[user_input.to_i - 1]
            gallery_details(gallery)
            explore_gallery(gallery)
        end 
    end
def gallery_menu puts "Please select a number from the list present to learn more about a gallery" . black . on_white user_input = gets . chomp if ! user_input . to_i . between? ( 1 , Galleries . all . count ) puts "Please choose a valid number" . black . on_white list_gallery gallery_menu else gallery = Galleries . all [ user_input . to_i - 1 ] gallery_details ( gallery ) explore_gallery ( gallery ) end end
GALLERY: Asks User to make a selection from gallery list, checks validility of selection, and, if valid, calls on gallery_details
GALLERY : Asks User to make a selection from gallery list checks validility of selection and if valid calls on gallery_details