To get us all back on track and show the validity of the lawsuit, I give you, the 14th Amendment:
All persons born or naturalized in the United States, and subject to the jurisdiction thereof, are citizens of the United States and of the State wherein they reside. No State shall make or enforce any law which shall abridge the privileges or immunities of citizens of the United States; nor shall any State deprive any person of life, liberty, or property, without due process of law; nor deny to any person within its jurisdiction the equal protection of the laws.
I've highlighted the relevant portions, as you can see.
After defining the two types of citizenship, the section then goes on to talk about any person.
In particular, any person
subject to the jurisdiction of a State.
Lawful aliens are just that type of person that the amendment is about.
The State may not deprive them of their rights without due process of law. Nor may the State withhold the equal protection of the law from lawful aliens.
By providing licenses or permits to lawful citizens of New Mexico, they must provide the same to lawful resident aliens.
Further, by statutory law, the US Government provides to lawful resident aliens the same fundamental rights and protections it affords to US citizens. That law is generally referred to as immigration law and preempts any State law to the contrary (sorry Tom, it is part of the complaint).
The complaint cites three civil rights violations: 1. Violation of 2A. 2. Violation of 14A. 3. Preemption of US Immigration law.