If California doesnt submit their votes as mandated by the Constitution their votes will not be counted.
The California legislature is free to allocate its electoral votes any way it wishes. It is not even required to conduct an election to do so. However, you can rest assured that should a Republican win the nation-wide popular vote but lose in California and the electoral college vote, the state legislature would convene and pass a bill awarding the state’s electoral votes to the democrat, likely saying they must respect the wishes of the voters of California. And do it all with a straight face.
I believe that Massachusetts did something similar about appointing replacement Senators when Ted, the Swimmer, died.