Welcome to the HP Support Community.
Does this happen while copying too?
When you do print in black, some amount of ink is taken from the color cartridges too. Do try replacing the color ink cartridge.
If the issue still persists, do try steps from here: https://support.hp.com/us-en/product/hp-photosmart-5520-e-all-in-one-printer-series/5157533/document/c03955472
Let me know if this helps.
If the information I've provided was helpful, give us some reinforcement by clicking the Accepted Solution and Kudos buttons, that'll help us and others see that we've got the answers!
Thanks!
Have a great day!