feat: #3593679 Restore the prior consent mode when cancelling opt-out switch

feat: #3593679 Restore the prior consent mode when the opt-out switch is unchecked and apply consent changes without a reload

  • Save the current mode to pianoanalytics_consent_mode_prior when toggling the opt-out switch (never saving opt-out itself) and restore it on uncheck, instead of forcing essential.
  • Re-apply _configurePrivacy() after a toggle so the new mode takes effect on the live SDK without a page reload.
  • Fall back to paConsent.getMode() in _configurePrivacy() when no stored or exempt mode applies, so purposes and body class always reflect an effective mode.
  • Declare the core/drupalSettings dependency on the optout switch library.

Merge request reports

Loading