Minecraft wiki entry for Piglin, associated text: If the player is under the influence of the Invisibility effect, they can open containers in front of piglins without aggravating them (short range), although breaking containers or golden blocks still angers them (mid/long range).