FIX: correctly defines data-attributes used by local-dates (PR #14418)

This was previously relying on data-* being allowed by other initialisers which could cause bugs if local dates ends up being used in other contexts.

GitHub

feel free to merge once approved