I believe this covers all the permutations you've asked for.
Note that passing through CBX in either direction costs money. You can buy a CBX ticket on arrival, but a valid airline ticket or boarding pass in our out of TIJ is required.
If you fly into TIJ from outside Mexico:
If you're on an international transit from outside Mexico through Tijuana to an airport in a country other than Mexico, you'll simply remain in Concourse B as you do today, and board your departing flight. You do not clear immigration or collect baggage. CBX is irrelevant for this itinerary.
If you're arriving from outside Mexico and connecting to a domestic flight, you will clear Mexican immigration here, go over to the other concourse, and wait for your flight. This is also the same as today. If your layover is long enough, and you have a visa or are visa exempt, you may use CBX to visit the United States briefly. You will clear immigration in both directions.
If you're arriving in TIJ from outside Mexico and you're walking to the U.S., you'll clear Mexican immigration and customs, follow the signs for the CBX terminal, buy your ticket, and go to the U.S. You will clear U.S. immigration even if your flight originated in the United States, because you did depart the U.S. and enter Mexico, however briefly.
If you fly into TIJ from another airport in Mexico:
If you arrive in TIJ from a domestic flight and you are bound for the U.S., you'll follow the signs for the CBX terminal, buy your ticket, and walk north. After you cross into the U.S., you'll run into Customs and Border Protection and clear immigration there.
If you walk into TIJ from the United States:
You will enter the CBX terminal, buy your ticket, and walk south. When you enter Mexico, you will clear Mexican immigration and customs. You can then proceed to your departure terminal.