Because there are three notes in a major chord, it is possible to find all three inversions of any major chord along any set of three adjacent strings. The diagram demonstrates this with a C chord on the 1st, 2nd and 3rd strings.
Here are the above inversions as individual chord shapes. Each of them can be used to play any major chord.