X-Ray Mode is Not Working
Your issue is you pinned the mesh settings in the properties panel, so you can change the settings of any other objects. Simply de-pin it so you can change the settings of the other objects:



Then, give the armature the X-Ray, because the object that has the X-Ray box checked is the one that will show through any other object. In this case, you want to to uncheck X-Ray on the mesh and check it for the armature.