Most cameras sensors can detect the infrared light emitted from the notch area of the X. Your eyes (usually) cannot see it.
The camera recording pics up the light you can’t see, and it’s displayed on the screen which emits light in the range you can see.
I’m sure it’s more technical than that but I’m not an engineer!