23 The festivals that have been introduced into the liturgy in more recent years have had a similar origin, and have been attended with similar results. When reverence and devotion to the Blessed Sacrament had grown cold, the feast of Corpus Christi was instituted, so that by means of solemn processions and prayer of eight days' duration, men might be brought once more to render public homage to Christ. So, too, the feast of the Sacred Heart of Jesus was instituted at a time when men were oppressed by the sad and gloomy severity of Jansenism, which had made their hearts grow cold, and shut them out from the love of God and the hope of salvation.
Source: Quas Primas (Vatican.va)