What does "comedy" mean?

Comedy: A dramatic composition, or representation of a bright and amusing character, based upon the foibles of individuals, the manners of society, or the ludicrous events or accidents of life; a play in which mirth predominates and the termination of the plot is happy; -- opposed to tragedy. With all the vivacity if comedy. Macaulay. Are come to play a pleasant comedy. Shak.

Sources