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

fix(legal-nav): fix adjunct links not showing #12064

Merged

Conversation

marcelojcs
Copy link
Contributor

@marcelojcs marcelojcs commented Oct 1, 2024

Related Ticket(s)

Closes #12037
Jira

Description

PR to solve the following:

The component defines an adjunctLinks property which allows users the ability to add adjunctLinks to the footer in Javascript, eg.

const adjunctLinks = [
  { "title": "link 1", "url": "abc" },
  { "title": "link 2", "url": "abc" },
  { "title": "link 3", "url": "abc" },
];

document.querySelector('c4d-footer-container').adjunctLinks = adjunctLinks;

However, when done in this way, the adjunct links, although added to the DOM and slotted into the correct place, remain hidden.

Changelog

Changed

  • Foced the method that determines if the links should be hidden or not to run when the adjunct links are updated.

Testing instructions

To test the changes open the default footer <storybook URL>?path=/story/components-footer--default and run the snippet from the example above in the devtools console

@marcelojcs marcelojcs requested a review from a team as a code owner October 1, 2024 18:36
@marcelojcs marcelojcs requested review from IgnacioBecerra, annawen1, m4olivei, bruno-amorim, andy-blum, Valentin-Sorin-Nicolae and a team and removed request for a team October 1, 2024 18:36
@ibmdotcom-bot
Copy link
Contributor

ibmdotcom-bot commented Oct 1, 2024

@ibmdotcom-bot
Copy link
Contributor

ibmdotcom-bot commented Oct 1, 2024

@m4olivei m4olivei added bug Something isn't working severity 2 Affects major functionality, has a workaround dev Needs some dev work package: web components Work necessary for the IBM.com Library web components package adopter: AEM used when component or pattern will be used by this adopter owner: Innovation Team used when the engineering work will be done by Hybrid Cloud with DDS engineers as consultants test: CDN preview used for generating @carbon/ibmdotcom-web-components CDN for testing labels Oct 1, 2024
@m4olivei m4olivei closed this Oct 1, 2024
@m4olivei m4olivei reopened this Oct 1, 2024
Copy link
Contributor

@m4olivei m4olivei left a comment

Choose a reason for hiding this comment

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

Working for the Storybook test case. Noticed some code clean up potentially needed. I also added the CDN label to be able to test it with the Stackblitz example.

@ibmdotcom-bot
Copy link
Contributor

ibmdotcom-bot commented Oct 1, 2024

Deploy preview created for package IBM.com Web Components Deploy Preview CDN:
https://ibmdotcom-cdn.s3.us-east.cloud-object-storage.appdomain.cloud/deploy-previews/12064/index.html

Built with commit: 0f4ae8de291f3f3a6cdffd3be9eb3b4055424008

Copy link
Member

@andy-blum andy-blum left a comment

Choose a reason for hiding this comment

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

One piece we forgot on our syncup

packages/web-components/src/components/footer/legal-nav.ts Outdated Show resolved Hide resolved
@m4olivei m4olivei requested review from m4olivei and andy-blum October 2, 2024 21:26
@kennylam kennylam added the Ready to merge Label for the pull requests that are ready to merge label Oct 10, 2024
@andy-blum andy-blum dismissed m4olivei’s stale review October 14, 2024 12:52

changes addressed

@kodiakhq kodiakhq bot merged commit f017f01 into carbon-design-system:main Oct 14, 2024
12 of 20 checks passed
Copy link
Contributor

github-actions bot commented Nov 6, 2024

Hey there! This issue/pull request was referenced in recently released v2.14.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
adopter: AEM used when component or pattern will be used by this adopter bug Something isn't working dev Needs some dev work owner: Innovation Team used when the engineering work will be done by Hybrid Cloud with DDS engineers as consultants package: web components Work necessary for the IBM.com Library web components package Ready to merge Label for the pull requests that are ready to merge severity 2 Affects major functionality, has a workaround test: CDN preview used for generating @carbon/ibmdotcom-web-components CDN for testing
Projects
None yet
6 participants