feat(volkskrant): suppress onboarding, widget and coachmark popups #33

Closed
opened 2026-10-10 12:22:53 +02:00 by midas · 0 comments
Owner

Part of #16.

Feature description

de Volkskrant has a QA switch that suppresses most popups at once: nl.persgroep.config.core.testing.PopupSuppression. Release builds bind a no-op implementation that always returns false. Use it (or the per-popup hooks below) to remove feature-onboarding dialogs, the home-screen widget prompt and similar nags.

Findings (7.52.0, unobfuscated)

  • PopupSuppressionModule.bindPopupSuppression$foundation_configuration binds PopupSuppressionNoOpt, whose getIsSuppressed()Z returns false. PopupSuppressionImpl exists for test builds.
  • Consumers of isSuppressed:
    • GetPendingOnboardingItemsUseCase: returns an empty list, so no feature-onboarding dialogs (FeatureOnboardingRepositoryImpl also checks it).
    • WidgetDiscoveryViewModel.onPageInView: the home-screen widget discovery prompt.
    • ShouldRequestInAppReviewUseCase: the review banner (#35).
    • SuppressFirebaseInAppMessagingUseCase: sets areMessagesSuppressed (#34).
    • ConsentManagerImpl.refreshConsent: skips the consent refresh, logging "Popup suppression is enabled, skipping consent refresh." This one is a problem.
    • TestIntentHandler: test only.
  • Not covered by PopupSuppression: the add-to-queue coachmark (AddToQueueCoachmarkTrigger) and the audio page onboarding hint (InlineMessage, see #19).

Forcing PopupSuppressionNoOpt.getIsSuppressed() to true also skips the consent popup. The analytics dispatcher would then never get consent: its queue grows without limit, and ads/tracking consent stay unset. So either:

  • patch the consumers one by one (preferred); or
  • force isSuppressed true and add an exception in ConsentManagerImpl.refreshConsent (more fragile).

Approach

  • Return an empty list from GetPendingOnboardingItemsUseCase.invoke.
  • Return early from WidgetDiscoveryViewModel.onPageInView.
  • Coachmark: make AddToQueueCoachmarkTrigger never fire (research the exact method).
  • Optionally drop the audio-page InlineMessage via #19.
  • Patch name suggestion: Hide nag popups. Review and Firebase In-App Messaging are separate issues so they can be options.

Done when

  • Build passes; patch applied on 7.52.0.
  • Device check (after asking) on a fresh install: the consent dialog still appears once; no feature-onboarding or widget prompts.
  • Documented in docs/apps/volkskrant.md, including the PopupSuppression finding.

Midas Settings

  • Toggle: Verberg onboarding- en tippop-ups (hide_onboarding_popups), category "Pop-ups en meldingen", default on.
  • Covers feature onboarding, the widget prompt and the coachmark. Read in each hook at runtime; it takes effect the next time a popup would appear.
  • Needs #49 and #50.
Part of #16. ## Feature description de Volkskrant has a QA switch that suppresses most popups at once: `nl.persgroep.config.core.testing.PopupSuppression`. Release builds bind a no-op implementation that always returns false. Use it (or the per-popup hooks below) to remove feature-onboarding dialogs, the home-screen widget prompt and similar nags. ## Findings (7.52.0, unobfuscated) - `PopupSuppressionModule.bindPopupSuppression$foundation_configuration` binds `PopupSuppressionNoOpt`, whose `getIsSuppressed()Z` returns false. `PopupSuppressionImpl` exists for test builds. - Consumers of `isSuppressed`: - `GetPendingOnboardingItemsUseCase`: returns an empty list, so no feature-onboarding dialogs (`FeatureOnboardingRepositoryImpl` also checks it). - `WidgetDiscoveryViewModel.onPageInView`: the home-screen widget discovery prompt. - `ShouldRequestInAppReviewUseCase`: the review banner (#35). - `SuppressFirebaseInAppMessagingUseCase`: sets `areMessagesSuppressed` (#34). - `ConsentManagerImpl.refreshConsent`: skips the consent refresh, logging "Popup suppression is enabled, skipping consent refresh." **This one is a problem.** - `TestIntentHandler`: test only. - Not covered by PopupSuppression: the add-to-queue coachmark (`AddToQueueCoachmarkTrigger`) and the audio page onboarding hint (`InlineMessage`, see #19). ## Consent caveat Forcing `PopupSuppressionNoOpt.getIsSuppressed()` to true also skips the consent popup. The analytics dispatcher would then never get consent: its queue grows without limit, and ads/tracking consent stay unset. So either: - patch the consumers one by one (preferred); or - force `isSuppressed` true and add an exception in `ConsentManagerImpl.refreshConsent` (more fragile). ## Approach - Return an empty list from `GetPendingOnboardingItemsUseCase.invoke`. - Return early from `WidgetDiscoveryViewModel.onPageInView`. - Coachmark: make `AddToQueueCoachmarkTrigger` never fire (research the exact method). - Optionally drop the audio-page `InlineMessage` via #19. - Patch name suggestion: **Hide nag popups**. Review and Firebase In-App Messaging are separate issues so they can be options. ## Done when - [ ] Build passes; patch applied on 7.52.0. - [ ] Device check (after asking) on a fresh install: the consent dialog still appears once; no feature-onboarding or widget prompts. - [ ] Documented in `docs/apps/volkskrant.md`, including the PopupSuppression finding. ## Midas Settings - Toggle: **Verberg onboarding- en tippop-ups** (`hide_onboarding_popups`), category "Pop-ups en meldingen", default **on**. - Covers feature onboarding, the widget prompt and the coachmark. Read in each hook at runtime; it takes effect the next time a popup would appear. - Needs #49 and #50.
midas closed this issue 2026-10-10 20:59:11 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
midas/midas-patches#33
No description provided.