Skip to content

fix(ai-label): React & WC link colors#21991

Merged
devadula-nandan merged 2 commits into
carbon-design-system:mainfrom
devadula-nandan:fix/popover-links-colors
Apr 23, 2026
Merged

fix(ai-label): React & WC link colors#21991
devadula-nandan merged 2 commits into
carbon-design-system:mainfrom
devadula-nandan:fix/popover-links-colors

Conversation

@devadula-nandan

@devadula-nandan devadula-nandan commented Apr 10, 2026

Copy link
Copy Markdown
Contributor

Closes #18647

AILabel builds on the base of ToggleTip
functionally it inherits every behavior of toggletip.
with a visual difference
the background color of toggletip content follows a contrasting color compared to theme background
the background color of ai-label follows similar color of theme background. but with a gradient.

in this case we have to reset the tokens to their defaults in AILabel to avoid any unwanted changes which are valid only in the ToggleTip.

Changelog

New

  • reset the tokens
    button-focus-color
    link-text-color
    link-hover-text-color
    link-visited-text-color
    link-focus-text-color
    to initial in _slug.scss

Testing / Reviewing

added example links in ai-label story for demo purposes. which will be cleaned up after review. and can be tested in deploy preview storybook.

this change covers react and web-components too. pls verify.

PR Checklist

As the author of this PR, before marking ready for review, confirm you:

  • Reviewed every line of the diff
    - [ ] Updated documentation and storybook examples
    - [ ] Wrote passing tests that cover this change
  • Addressed any impact on accessibility (a11y)
  • Tested for cross-browser consistency
  • Validated that this code is ready for review and status checks should pass

More details can be found in the pull request guide

@netlify

netlify Bot commented Apr 10, 2026

Copy link
Copy Markdown

Deploy Preview for v11-carbon-react ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 900441d
🔍 Latest deploy log https://app.netlify.com/projects/v11-carbon-react/deploys/69d8d9b6c70736000807021a
😎 Deploy Preview https://deploy-preview-21991--v11-carbon-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify

netlify Bot commented Apr 10, 2026

Copy link
Copy Markdown

Deploy Preview for v11-carbon-web-components ready!

Name Link
🔨 Latest commit 900441d
🔍 Latest deploy log https://app.netlify.com/projects/v11-carbon-web-components/deploys/69d8d9b6e126870008d2659b
😎 Deploy Preview https://deploy-preview-21991--v11-carbon-web-components.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@codecov

codecov Bot commented Apr 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.90%. Comparing base (99a584f) to head (900441d).
⚠️ Report is 57 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #21991   +/-   ##
=======================================
  Coverage   94.90%   94.90%           
=======================================
  Files         541      541           
  Lines       45250    45250           
  Branches     6386     6386           
=======================================
  Hits        42946    42946           
  Misses       2172     2172           
  Partials      132      132           
Flag Coverage Δ
main-packages 89.16% <ø> (ø)
web-components 97.70% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@devadula-nandan devadula-nandan changed the title Fix/popover links colors fix(ai-label) React & WC link colors Apr 10, 2026
@devadula-nandan devadula-nandan changed the title fix(ai-label) React & WC link colors fix(ai-label): React & WC link colors Apr 10, 2026
@devadula-nandan devadula-nandan marked this pull request as ready for review April 10, 2026 11:27
@devadula-nandan devadula-nandan requested a review from a team as a code owner April 10, 2026 11:27

@maradwan26 maradwan26 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

React looks good 👍
Image

Web Components the link colours for <a> and <cds-link> are different for me

Image

@devadula-nandan

Copy link
Copy Markdown
Contributor Author

@maradwan26

Web Components the link colours for and are different for me

This fixes the cds-link common styles which seems to be the reported issue.

the normal link with the a tag gets its color from plex. which is imported in storybook preview and not part of any component styles.

href="https://1.www.s81c.com/common/carbon-for-ibm-dotcom/tag/v1/latest/plex.css" />

the dotcom cdn maybe outdated. and we should get rid of this by using a proper updated cdn.
this is a storybook setup only change and doesnt effect the component

Screenshot 2026-04-21 at 5 49 35 PM

@devadula-nandan

Copy link
Copy Markdown
Contributor Author

#22102

@maradwan26 opened a followup storybook issue.

@maradwan26

Copy link
Copy Markdown
Contributor

@devadula-nandan Oh I see okay thanks for clarifying!

@tay1orjones tay1orjones added this pull request to the merge queue Apr 22, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to no response for status checks Apr 22, 2026
@devadula-nandan devadula-nandan added this pull request to the merge queue Apr 23, 2026
Merged via the queue into carbon-design-system:main with commit 5bc8623 Apr 23, 2026
55 checks passed
@devadula-nandan devadula-nandan deleted the fix/popover-links-colors branch April 23, 2026 08:32
MarianaAa01 pushed a commit to MarianaAa01/carbon that referenced this pull request May 29, 2026
* fix: link colors in ai-label

* chore: add example links in stories
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Follow up on 4452, accessibility of links in AI explainer label, dark theme

3 participants