Loading
Issue #3624950: Stop using cache.page.max_age as the render max-age of Blazy elements
The formatter Cache option fell back to system.performance cache.page.max_age, which is the browser and proxy TTL, not a render lifetime. Drupal ships it as 0, so on the default configuration every Blazy and Slick field declared max-age 0 and pulled its page out of the dynamic page cache.
An empty option now declares neither a max-age nor cache keys, so the element inherits its parents' and children's cacheability, matching the option's "Leave empty to disable caching" description. An explicit value is cast to int, since the formatter form submits it as a string and Cache::mergeMaxAges() compares strictly.
Adds BlazyCacheMetadataTest covering empty, unset, empty string, a number, a numeric string, -1 and '-1'.
Closes #3624950