Strain-tunable electronic structures and optical properties of semiconducting MXenes