question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Module disconnect modal wording assumes module has features

See original GitHub issue

Bug Description

All modules have the option to declare a list of features as user-facing short descriptions, e.g. “Intelligent, automatic ad placement” is one for AdSense. Features are not a required element of module registration though so components that use this should not assume that this list will always be present, even if all Site Kit modules provide it.

Steps to reproduce

  1. Activate Idea Hub
  2. Deactivate Idea Hub

Screenshots

image


Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

  • If a module has no available features defined, the message that would otherwise appear above the list of features in the disconnect dialog should not appear.
  • Note that Site Kit modules should always provide features to clarify the meaning of disconnecting said modal. This tweak is only so that eventual third-party modules are not technically required to provide such a list.

Implementation Brief

See working branch here https://github.com/google/site-kit-wp/tree/bug/3691-Module-disconnect-modal-no-features

Using assets/js/components/settings/SettingsActiveModule/ConfirmDisconnect.js

  • If no features are passed as props e.g. feature prop is null/undefined/empty array, do not pass in subtitle string to inner Dialog component (e.g. pass in empty string or null)

Create a .stories.js file for the ConfirmDisconnect component

  • Add a story where the features are populated (current behaviour)
  • Add a new story where there are no new features

Test Coverage

  • No changes

Visual Regression Changes

  • No changes

QA Brief

Check two new stories in Storybook

Changelog entry

  • Improve module disconnect screen when a module doesn’t have listed features.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:11 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
aaemnnosttvcommented, Jul 28, 2021

@danielgent I agree stories would be the easiest. A more robust test would be adding tests for SettingsActiveModule using a custom module registered in the test (or using provideModuleRegistrations with override) but I don’t think it’s necessary here.

I could add <ConfirmDisconnect /> to storybook with examples with and without features?

SGTM 👍

0reactions
cole10upcommented, Aug 10, 2021

Thanks for having a look @aaemnnosttv. While I understood the ticket and the problem as well as the fact that we no longer have a scenario to cover this specific update. My testing efforts above were to ensure that with this update, we retained the functionality and content in each of our modals.

Thanks again!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Angular 8 - Custom Modal Window / Dialog Box
LAST UPDATED: JUNE 22 2020 - Simple Modal Window in Angular 8 with Angular CLI. Custom modal without the need for 3rd party...
Read more >
How to Create a Popup in Divi Without a Plugin
Today, we're going to show you how to take Divi's lightbox functionality and use it to display a Divi popup of sections, rows,...
Read more >
Page 7: Assessment - IRIS Center
To evaluate whether the students have mastered the content and to assign grades, teachers at Sycamore Middle School typically rely on the chapter...
Read more >
Modules | Kaltura Knowledge Center
The basic configuration of enable/disable is in the Chapters module in KMS or KAF Admin page. ... Edit Media. After you enable the...
Read more >
Bolt for Python - Slack Platform Developer Tools
Refer to the module document to learn the available listener arguments. ... an app can use to open a modal that confirms the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found