The 8 was the upgrade to the standard iPhone line (7 and 7 Plus), the X was the new tier above the 8.
The 8 had as many improvements in it as the 7 had from the 6S and the 6S from the 6 before it (faster hardware, better cameras, new features (Qi charging)).
The X was a big departure and represented a new tier above the standard iPhone line (hence it was a lot more expensive).
The Xr replaced the iPhone 8 series as the standard iPhone line.
The 11 replaces the Xr as the standard iPhone line.
The XS, XS Max, 11 Pro and 11 Pro Max are the ultra-premium tier.