Though the First Amendment generally limits only actions by the government, many states have statutes that limit even private employers' ability to fire employees for their political activities (see this article for more details); some of them broadly cover ideological advocacy, and not just election-related activities:

In particular, two California statutes, enacted in 1937, provide: