Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement the Selection Panel Info Notice #8159

Open
17 tasks
techanvil opened this issue Jan 25, 2024 · 1 comment
Open
17 tasks

Implement the Selection Panel Info Notice #8159

techanvil opened this issue Jan 25, 2024 · 1 comment
Labels
Module: Analytics Google Analytics module related issues P1 Medium priority Squad 2 (Team M) Issues for Squad 2 Type: Enhancement Improvement of an existing feature

Comments

@techanvil
Copy link
Collaborator

techanvil commented Jan 25, 2024

Feature Description

Implement the info notice will be displayed when the Selection Panel is opened with only one item selected.

See audiences creation > info notice in the design doc.


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

Acceptance criteria

  • If there is only one audience currently selected, when the Selection Panel is opened it will display a dismissible info notice encouraging the user to add another audience to the selection.
  • This should be implemented as per the Figma design.
  • It will have a Got it button for dismissing the notice. Clicking the button will permanently dismiss the notice and it will not be shown again to the current user.

Implementation Brief

Note: It could be worth taking a look at the Info Notice component to see if can be refactored for reuse. See #8137.

In assets/js/modules/analytics-4/components/dashboard/AudienceSegmentation/InfoNotice.js:

  • Add a new id prop to the InfoNotice component.
  • Add a new infoIcon prop to the InfoNotice component.
  • Add the id to the div element.
  • Render the infoIcon prop if it is provided. Otherwise, render the LightbulbIcon component.

In the selection panel component, which is being implemented in #8157:

  • Get the selected/configured audiences using the getConfiguredAudiences selector.
  • Get the InfoNotice dismissible state using the isItemDismissed selector using an appropriate id value.
  • If only one audience AND the InfoNotice is not dismissed, render the AudienceSegmentation/InfoNotice component.
  • Pass an appropriate id value to the InfoNotice component.
  • Extract the info icon from the Figma design and pass it as the infoIcon prop to the InfoNotice component.
  • Pass Got it as the dismissLabel prop.
  • Pass a callback function to the onDismiss prop that dismisses the InfoNotice using the dismissItem action.
  • Pass the below text to the content prop:
    By adding another group to your dashboard, you will be able to compare them and understand which content brings back users from each group
    
  • Preferably, create a new component for the selection panel info notice and use it in the selection panel component to keep the code clean and maintainable.

Test Coverage

  • In case of a new component, create a new storybook file for it.
  • Add a story to the selection panel storybook to show the info notice when only one audience is selected.
  • Add a new story to the AudienceSegmentation/InfoNotice storybook to include the new infoIcon prop.

QA Brief

Changelog entry

@techanvil techanvil added Module: Analytics Google Analytics module related issues P1 Medium priority Type: Enhancement Improvement of an existing feature labels Jan 25, 2024
@hussain-t hussain-t self-assigned this Jan 30, 2024
@hussain-t hussain-t removed their assignment Feb 26, 2024
@techanvil techanvil assigned techanvil and unassigned techanvil Mar 15, 2024
@hussain-t hussain-t assigned hussain-t and unassigned hussain-t Mar 18, 2024
@ivonac4 ivonac4 added Next Up Issues to prioritize for definition and removed Next Up Issues to prioritize for definition labels Mar 19, 2024
@eugene-manuilov eugene-manuilov self-assigned this Mar 26, 2024
@eugene-manuilov
Copy link
Collaborator

IB ✔️

@eugene-manuilov eugene-manuilov removed their assignment Mar 26, 2024
@ivonac4 ivonac4 added the Squad 2 (Team M) Issues for Squad 2 label Apr 9, 2024
@ivonac4 ivonac4 added Sp Wk 2 Issues to be completed in the second week of the assigned sprint and removed Sp Wk 2 Issues to be completed in the second week of the assigned sprint labels Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Module: Analytics Google Analytics module related issues P1 Medium priority Squad 2 (Team M) Issues for Squad 2 Type: Enhancement Improvement of an existing feature
Projects
None yet
Development

No branches or pull requests

4 participants