Mary as Mediatrix of all graces is official Catholic doctrine, but not a dogma of faith. In *Fundamentals of Catholic Dogma * (pg. 215), Dr. Ludwig Ott outlines the doctrinal basis for Mary’s Universal Mediation (her co-operation in the Incarnation and the Redemption, as well as her relationship to the Church):
a) Since Mary gave the source of all grace to men, it is to be expected that she would also co-operate in the distribution of all grace.
b) As Mary became the spiritual Mother of all the redeemed, it is fitting that she, by her contant motherly intercession should care for the supernatural life of all her children.
c) As Mary is “the prototype of the Church (St. Ambrose, Expos.ev.sec.Luc.II 7), and as all grace of redemption is obtained by the Church, it is to be assumed that Mary, by her heavenly intercession, is the universal mediatrix of grace.
One excerpt cannot adequately cover the full scope of this topic, thus I refer you to the following:
Church Teaching on Mary as Mediatrix of (All) Graces
ewtn.com/faith/Teachings/marya4a.htm
ourladyswarriors.org/articles/mother.htm
ewtn.com/faith/Teachings/MARYA4.HTM