We currently display Literal[1, 2] | Literal["foo"], but the spec (and other type checkers) prefer Literal[1, 2, "foo"]. We allow the latter in an annotation, but we don't display it that way.
We should probably switch to displaying this like the spec and other type checkers do.
I would leave class and function literals out of this change, since they aren't part of the spec and we may want to display them entirely differently.