Akamai's Cloud Manager is an open-source, single-page application designed as the primary frontend interface for interacting with the Linode API. It is entrusted by hundreds of thousands of customers with the management of their Linode services.
There are a very small number of events that we consider ACTIONS_WITHOUT_USERNAMES. Some of these actions have no username, and other we want to override the username with Linode - we have a util called getEventUsername to do this for us.
We weren't making use of the username from the util correctly in this component, which we assign at L36.
Without using this util, if a username existed (as it does for entity_transfer_create events), we were rendering the wrong initial in the avatar component. Since this is an 'action without username', we want the username to be Linode and to render the Akamai logo as the avatar.
We were already using this util in the EventRow component on Event Landing page; the bug was just in the Notification Center event.
~No changeset, didn't make it to prod.~ Adding a changeset because this actually was an existing bug in prod, but becomes more obvious once we start using the initialed avatars.
Changes ๐
Uses the username from getEventUsername util to correctly identify events whose usernames we are changing and render the correct avatar accordingly.
Target release date ๐๏ธ
9/16/24
Preview ๐ท
Before
After
Prod:
How to test ๐งช
Prerequisites
(How to setup test environment)
Use an account without a Gravatar.
In dev, trigger a service transfer.
Reproduction steps
(How to reproduce the issue, if applicable)
Open the notification center.
Notice that although the username associated with the service transfer create event shows up as 'Linode' in the notification, the avatar has the first letter of your account username. (This is because the event.username is actually your user when coming from the API.)
Verification steps
(How to verify changes)
Check out this PR.
Open the notification center.
Notice that by using the util, we now are correctly overriding that event.username with Linode when passing that prop to the Avatar component. The Akamai logo is displayed as a result.
Verify that that matches the event in Events Landing.
Description ๐
One more bug fix...
There are a very small number of events that we consider
ACTIONS_WITHOUT_USERNAMES
. Some of these actions have no username, and other we want to override the username withLinode
- we have a util calledgetEventUsername
to do this for us.We weren't making use of the username from the util correctly in this component, which we assign at L36.
Without using this util, if a username existed (as it does for
entity_transfer_create
events), we were rendering the wrong initial in the avatar component. Since this is an 'action without username', we want the username to be Linode and to render the Akamai logo as the avatar.We were already using this util in the EventRow component on Event Landing page; the bug was just in the Notification Center event.
~No changeset, didn't make it to prod.~ Adding a changeset because this actually was an existing bug in prod, but becomes more obvious once we start using the initialed avatars.
Changes ๐
username
fromgetEventUsername
util to correctly identify events whose usernames we are changing and render the correct avatar accordingly.Target release date ๐๏ธ
9/16/24
Preview ๐ท
How to test ๐งช
Prerequisites
(How to setup test environment)
Reproduction steps
(How to reproduce the issue, if applicable)
Verification steps
(How to verify changes)
event.username
withLinode
when passing that prop to the Avatar component. The Akamai logo is displayed as a result.As an Author I have considered ๐ค
Check all that apply