-
Notifications
You must be signed in to change notification settings - Fork 291
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
Add "temporarily hidden" badge to hidden audiences in the Selection Panel #9315
Add "temporarily hidden" badge to hidden audiences in the Selection Panel #9315
Conversation
Build files for 8c01dd5 have been deleted. |
Size Change: +50.3 kB (+2.78%) Total Size: 1.86 MB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @ankitrox, this looks good and works well. I've added a couple of small details around the stories to commit if you agree.
tooltipTitle: | ||
'Still collecting full data for this timeframe, partial data is displayed for this group', | ||
}; | ||
Default.scenario = { | ||
label: 'Modules/Analytics4/Components/AudienceSegmentation/Dashboard/PartialDataBadge/Default', | ||
label: 'Modules/Analytics4/Components/BadgeWithTooltip/Default', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
label: 'Modules/Analytics4/Components/BadgeWithTooltip/Default', | |
label: 'Components/BadgeWithTooltip/Default', |
}; | ||
|
||
export default { | ||
title: 'Modules/Analytics4/Components/AudienceSegmentation/Dashboard/PartialDataBadge', | ||
title: 'Modules/Analytics4/Components/BadgeWithTooltip', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
title: 'Modules/Analytics4/Components/BadgeWithTooltip', | |
title: 'Components/BadgeWithTooltip', |
Now that you've made this a nice reusable component, it doesn't need to be used just in Analytics so you can move it to the main components section of the stories.
} | ||
|
||
export const Default = Template.bind( {} ); | ||
Default.storyName = 'Default'; | ||
|
||
Default.args = { | ||
label: 'Title for badge with tooltip', | ||
tooltipTitle: | ||
'Still collecting full data for this timeframe, partial data is displayed for this group', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
'Still collecting full data for this timeframe, partial data is displayed for this group', | |
'This is an example of tooltip content for a badge with tooltip', |
This is a small detail.
@benbowler Thanks for review and adding the feedback. As Evan pointed out in a recent review, we don't actually need to specify the label for scenarios, as it is by default determined from the default title and the story's storyName, so I have skipped that point. Rest of the points addressed, tested and pushed the changes in PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ankitrox, LGTM ✅
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Excellent work on this, thank you @ankitrox !
- I've left a few comments in the PR.
- According to the IB, we should add some test coverage for the appearance of the "Temporarily hidden" badge.
- Can we add one test case that verifies that the "Temporarily hidden" badge appears when conditions are met?
- Can we add one test case that verifies that the "New" badge does not appear when the "Temporarily hidden" badge is visible?
Please let me know if you have any questions, thank you!
...nalytics-4/components/audience-segmentation/dashboard/AudienceSelectionPanel/AudienceItem.js
Outdated
Show resolved
Hide resolved
...nalytics-4/components/audience-segmentation/dashboard/AudienceSelectionPanel/AudienceItem.js
Outdated
Show resolved
Hide resolved
assets/sass/components/analytics-4/audience-segmentation/_googlesitekit-badge-with-tooltip.scss
Outdated
Show resolved
Hide resolved
...oogle-site-kit_Modules_Analytics4_Components_BadgeWithTooltip_Default_0_document_0_small.png
Outdated
Show resolved
Hide resolved
...ogle-site-kit_Modules_Analytics4_Components_BadgeWithTooltip_Default_0_document_1_medium.png
Outdated
Show resolved
Hide resolved
...oogle-site-kit_Modules_Analytics4_Components_BadgeWithTooltip_Default_0_document_2_large.png
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, forgot to include this one in the original review above.
assets/sass/components/analytics-4/audience-segmentation/_googlesitekit-badge-with-tooltip.scss
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @ankitrox . Thank you for updating the tooltip text. Maybe it didn't catch your attention but that wasn't the only feedback in my code review. Could you please take a look at my comments above and address them?
Moreover, I feel there is an additional update required to the tooltip text. I've asked Tom here.
I understand that we're under a time constraint here but I believe the changes requested are quite minimal. I'd have gone and applied them myself but since we're waiting for an AC change confirmation, I'm sending this back to Execution. CC: @techanvil @ivonac4
...nalytics-4/components/audience-segmentation/dashboard/AudienceSelectionPanel/AudienceItem.js
Outdated
Show resolved
Hide resolved
Thanks for spotting that the text still needed an update! I've applied that change myself but see there are other comments for @ankitrox still to address, so I've left this in execution. |
Thank you @techanvil for correcting the text and committing the change. @nfmohit I've addressed the other comments. Sorry for missing them at the first place. Over to you for re-review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Excellent work here, @ankitrox!
I've left a small number of very minor comments. As they are very minor, I hope you won't mind if I go ahead and address them myself considering our time limitation.
.../analytics-4/components/audience-segmentation/dashboard/AudienceSelectionPanel/index.test.js
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, brilliant work, @ankitrox !
Note: I've verified that the failing tests in CI are unrelated to this PR.
Summary
Addresses issue:
Relevant technical choices
PR Author Checklist
Do not alter or remove anything below. The following sections will be managed by moderators only.
Code Reviewer Checklist
Merge Reviewer Checklist