Problem/Motivation
The tab strip built by CloudflarePurgeLinks::build() attaches the cloudflare_purge/navigation library only on its own render element, which carries a #cache keyed by route + permissions. That element's bubbled #attached can be served stale from the render cache: we observed the credentials page (with settings.php overrides) rendering the tab markup while nav.css was absent, so the tabs fell back to a plain bullet list.
Proposed resolution
Also attach the library at form level, next to the existing cloudflare_purge/form attachment in CloudflarePurgeForm, so the stylesheet loads regardless of the sub-element's cache state:
$form['#attached']['library'][] = 'cloudflare_purge/form';
+ $form['#attached']['library'][] = 'cloudflare_purge/navigation';
Comments
Comment #2
julien commentedAttaching the patch.
Comment #3
julien commentedComment #4
flashwebcenterHello,
Thank you for the patch. Done and committed to the 3.1.x-dev branch. The navigation library is now attached at the page level on all 9 pages that render the tab strip, and the scan confirmed it loads only on those pages.
Best wishes,
Alaa