It is permitted to pray the rosary publicly during eucharistic exposition. What’s not permitted is to expose the Eucharist for the sole purpose of reciting the rosary. The reason for this restriction is to ensure that pious exercises do not detract the faithful from the purpose of eucharistic adoration.
The Congregation for Divine Worship and the Discipline of the Sacraments, in the 34th edition of Notitiae (1998), states the following:
One should not expose the Eucharist only to recite the rosary. However, among the prayers that are used during adoration, the recitation of the rosary may certainly be included, emphasizing the christological aspects with biblical readings relating to the mysteries, and providing time for silent adoration and meditation on them. (507-511)
Also: “In the surroundings of exposition, anything must be carefully avoided that could in any way obscure Christ’s intention of instituting the holy Eucharist above all in order to be near us to feed, to heal, and to comfort us” (Eucharisticum Mysterium 60).