Which garment was being referred to in Genesis 39 as being taken by Potiphar's wife whilst Joseph fled?
Your question cannot be answered from the biblical verses alone, as the nature of this garment is not specified, so we must turn to extra-biblical sources.
We know that all Egyptian men (besides for the king and his household) did not wear any clothing besides for a skirt, its length depending on the fashion of the specific period. See image below. This was because of the hot climate in Africa, which made too many cloths an impossibility as it would would have made them very uncomfortable working under the brutal sun. So the garment Potiphar's wife grabbed from Joseph was most probably his skirt, which may have left him naked (This would have reinforced her allegations against Joseph that he attempted to rape her. Smart lady!). However, we know that Egyptians wore loincloths underneath their skirts, so hopefully Joseph wore one as well and was left with something to cover his nakedness.