Onyx Pikmin are onyx-colored, not-made-of-onyx Pikmin able to avoid detection from night predators. It is because they are black and the night is black, and unlike what others would desire these do not have illumination abilities. Illumination would only serve to make Onyx Pikmin stand out and be easier to see. Obviously, this would eliminate their night resistance, and keeping Pikmin alive is more useful than being able to see.
These Pikmin will not die overnight. They may die if the Captains do not return to the area they left Black Pikmin the next day (this will count as an overnight loss in the death totals), it depends on the game. Other aspects about how the Pikmin scatter overnight may vary as well: They may stay where they were, becoming idle ready to continue whatever they were doing the previous day. They may scatter, due to their attempts to run away from enemies overnight. They may return to where the onions were ready to be controlled immediately. It all depends on the game.
They are all black, excluding their leaf which is still green and their eyes which are the same as other Pikmin. It has also shown to be able to absorb nearby light, or at least that is the current theory for how its leaf "glows" black when idle as unlike other Pikmin's glowing, black is not a color that can be emitted.