Storage: Keep pansy blossoms in their plastic clamshells in the refrigerator until you are ready to use them. If they start to droop a little bit, try briefly dipping them in ice water to refresh them.
Shelf Life: Up to ten days.

Pansies can be used whole or as separated petals to bring bright color to plates, platters, cakes, and salads. If adding to salads, do so after tossing all other ingredients with the dressing to allow the pansies to shine.
Because they’re relatively flat and have large petals, pansies are a particularly good choice for candying.
How to Candy Flowers