It can severely affect your performance (depending on how accustomed you are to have been already masking it as a habit). However, if you strive to be honest, your work ethic will not be compromised. Depending on your employer’s understanding, you may be supported for your healing, or you may be judged for your performance and depression. Work ethic is not conforming to an unrealistic ideal, true ethics is being true to oneself, even if your performance turns out to be below than what is expected by others. This requires courage, even the courage to lose your job if needs be. (Your ethics will actually be compromised when you lie about/hide your depression and try to perform, perform for a while and then secretly under-perform for some times, and then perform again, so on.)
I am not sure how many workplaces are out there that are conscious enough to hold an understanding space for depressed people. The important thing is, you can be depressed but still be loving towards yourself and feel ethically uncompromised. This can have a healing effect on you as well, because you are giving yourself permission to be yourself so that your understanding can evolve, your awareness can come into those parts where you were not aware of before. Depression is something we create subconsciously, so we can progress towards healing with awareness, making more of our mind conscious, integrated. Wise guidance also teaches us how to direct our awareness so as not to get lost in certain parts of ourselves.
And what about this compromised ethics? It is not that something is getting broken about you. It is just that, when you are not fully honest with yourself, this keeps hiding certain parts of yourself from yourself. It is of course natural not to have awakened to all of ourselves yet. But if we keep not being honest even though we know we can be honest at a given moment, then this is certainly keeping us from integrating ourselves. This is the compromise I am trying to point to. Having the courage to be honest when you know you can be will preserve your ethics and increase your integrity. It will evolve your understanding to higher levels of wisdom. A higher wisdom is synonymous with feeling more oneness with your human self, and your environment (everything that seems outside yourself), equaling a more evolved morality and a natural expression of this morality.