Stolperia's answer is very nice and thorough. I would also add that Maria's character is based on Juliet's from Shakespeare's Romeo and Juliet. The stories themselves of West Side Story and Romeo and Juliet are similar, of course, because they involve "star-cross'd lovers" (people who, according to society, are not supposed to be together -- or have an ill-fated end). In West Side Story, Tony and Maria represent affiliations with two opposing gangs, and in Romeo and Juliet, the title characters represent affiliations with two dissenting families.
When the producers and directors of West Side Story decided to change the ending from the dual tragedy of Romeo and Juliet, they also, whether intentionally or not, made Maria a stronger, more dynamic character than Juliet. Maria, for example, directly confronts the warring Sharks and Jets, whereas I do not believe Juliet ever would have had the "guts" to do so with the Capulets and Montagues. However, Maria does experience some of the same conflicts and Juliet, such as whether to choose her family and heritage, or to choose the love of her life (who happens to be an "enemy"). You might refer to this dilemma as one between head and heart. Anita, Maria's best friend and her brother's girlfriend, even tries to convince Maria, with a logical statement, to leave Tony, claiming, "A boy like that would kill your brother!" (after Tony accidentally stabs Bernardo, of course). Maria, however, ultimately chooses to follow her heart -- and it is that passion that serves her well when she delivers her fiery speech at the end that reminds all of the boys that their fighting has gotten them nowhere.
Maria is the daughter of recent Puerto Rican immigrants to New York City and the younger sister of Bernardo, who has become the leader of the Sharks, a gang of Puerto Rican youth seeking their place in their new location, starting with staking out a territory for their gang. As the daughter, Maria's parents expect her to fulfill the traditional female roles of working as a seamstress until she marries the Puerto Rican boy found and approved by her parents.
At a high school dance, Maria sees Tony, the leader of the Jets, the local working-class white gang that is the chief rival of the newcomer Sharks. Maria and Tony are immediately attracted to each other, an attraction actively and vehemently denounced and forbidden by Bernardo, Maria's Puerto Rican girlfriends at the bridal shop, and by the Jets. The tension between the two gangs over territorial rights emphasizes the tension felt by the forbidden lovers.
Maria is torn between two worlds - her Puerto Rican heritage and the expectations that come with it, and the opportunities of the new place in which she lives and the new love she has found with Tony.