If you identify that the hostility is arising because of something about you as a woman, or a person of color, or because of your age, or your disability, or some other protected status, then it is illegal.
To treat you equally as a woman, to not permit you to be sexually harassed, to not permit you to be working in an environment that may be hostile to women in general, and you in particular; to ensure that your work environment for the nine months of your pregnancy is flexible, isn’t hostile; that you are able to come back from maternity leave that your employer must provide for you, and they must provide a place for you to express milk after you come back from your maternity leave.
There are at least five principle ways that you can be discriminated against at work based on your pregnancy.
If you’re going to have your Rosa Parks moment, make it count. Make sure you document, document, document the complaint, and all follow up to the boss, to the HR department. Whatever happens, put it in writing. Hold their feet to the fire. Stand up for yourself. The Rosa Parks moment, Circa 2018 in the workplace.
Every case has a statute of limitations – the date by which it must be filed, or the chances are lost forever. In discrimination cases, sexual harassment, pregnancy discrimination, retaliation, any kind of employment law case, a charge of discrimination must be filed with the United States Equal Employment Opportunity Commission before you’re allowed to file in court, and that charge of discrimination must be filed, within either 180 days of the last discriminatory act or 300 days of the last discriminatory act, depending on the state where you work. So for instance, in New York, that federal filing date with EEOC is 300 days from, if you were fired, that is likely the last discriminatory act.