Skip to content

refactor: [M3-9656] - [Akamai Design System] Label Component #12005

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

Draft
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

carrillo-erik
Copy link
Contributor

@carrillo-erik carrillo-erik commented Apr 10, 2025

Description 📝

This PR refactors the Label component to the new Akamai Design System.

Changes 🔄

  • Label component supports two size variants:
    1. Typography.Label.Bold.L
    2. Typography.Label.Bold.S
  • Labels can display optional icons positioned either to the left or right of the text.
  • Large label (L) uses 20x20px icons
  • Small label (S) uses 16x16px icons

Preview 📷

Before After

How to test 🧪

Verification steps

  • Play with passing different values for labelTooltipIconPosition and labelTooltipIconSize
Author Checklists

As an Author, to speed up the review process, I considered 🤔

👀 Doing a self review
❔ Our contribution guidelines
🤏 Splitting feature into small PRs
➕ Adding a changeset
🧪 Providing/improving test coverage
🔐 Removing all sensitive information from the code and PR description
🚩 Using a feature flag to protect the release
👣 Providing comprehensive reproduction steps
📑 Providing or updating our documentation
🕛 Scheduling a pair reviewing session
📱 Providing mobile support
♿ Providing accessibility support


  • I have read and considered all applicable items listed above.

As an Author, before moving this PR from Draft to Open, I confirmed ✅

  • All unit tests are passing
  • TypeScript compilation succeeded without errors
  • Code passes all linting rules

@carrillo-erik carrillo-erik added the Design Tokens Laying the groundwork for Design Tokens label Apr 10, 2025
@carrillo-erik carrillo-erik self-assigned this Apr 10, 2025
@jaalah-akamai jaalah-akamai added the Requires UX Approval Design System Component Requires UX Approval label Apr 16, 2025
@linode-gh-bot
Copy link
Collaborator

Cloud Manager UI test results

🔺 6 failing tests on test run #3 ↗︎

❌ Failing✅ Passing↪️ Skipped🕐 Duration
6 Failing540 Passing7 Skipped160m 5s

Details

Failing Tests
SpecTest
resize-linode.spec.tsCloud Manager Cypress Tests→resize linode » resize linode
edit-user-alert.spec.tsCloud Manager Cypress Tests→Integration Tests for Edit Alert » Integration Tests for Edit Alert
object-storage.e2e.spec.tsCloud Manager Cypress Tests→object storage end-to-end tests » object storage end-to-end tests
rebuild-linode.spec.tsCloud Manager Cypress Tests→rebuild linode » rebuild linode
access-key.e2e.spec.tsCloud Manager Cypress Tests→object storage access key end-to-end tests » object storage access key end-to-end tests
object-storage-objects-multicluster.spec.tsCloud Manager Cypress Tests→Object Storage Multicluster objects » Object Storage Multicluster objects

Troubleshooting

Use this command to re-run the failing tests:

pnpm cy:run -s "cypress/e2e/core/linodes/resize-linode.spec.ts,cypress/e2e/core/cloudpulse/edit-user-alert.spec.ts,cypress/e2e/core/objectStorage/object-storage.e2e.spec.ts,cypress/e2e/core/linodes/rebuild-linode.spec.ts,cypress/e2e/core/objectStorage/access-key.e2e.spec.ts,cypress/e2e/core/objectStorageMulticluster/object-storage-objects-multicluster.spec.ts"

@davyd-akamai
Copy link

@jaalah-akamai Not sure that I can run it locally, but if you could attach screenshots into "Before/After" section to review, that's will be enough.

@carrillo-erik
Copy link
Contributor Author

carrillo-erik commented Apr 17, 2025

@davyd-akamai Here are some screen shots. As this is still in Draft, I will wait for the Before and After images in the PR description until I can open this up for Review.

Current Label and Icon size and placement

Label with Icon on right side
current-label-font-size
current-icon-size

Changes Introduced in this PR

Large Label with Large Icon on right side
largeLabelIcon-Right
largeLabelText
Small Label with Small Icon on left side
smallLabelIcon-Left
smallLabelText

Copy link

@davyd-akamai davyd-akamai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great!

@davyd-akamai
Copy link

@tzmiivsk-akamai could you take a look as well?

@tzmiivsk-akamai
Copy link

tzmiivsk-akamai commented Apr 18, 2025

Hi! @carrillo-erik @davyd-akamai Based on the screenshots, I can see that the text color differs from the tokens I see in Figma. I'd also like to point out that in Figma, the default colors for the icons on the left and right are different (the info icon always uses a secondary color).
Unfortunately, I can’t be sure about the padding between the icon and the label just from the screenshot, but it looks okay to me. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Design Tokens Laying the groundwork for Design Tokens Requires UX Approval Design System Component Requires UX Approval
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants