Skip to content

Conversation

@ashB100
Copy link
Contributor

@ashB100 ashB100 commented Jan 23, 2025

Description

Canopy lgShadow directive added a box-shadow to its host component. However, the box-shadow value was from an older design. Canopy designs has a new desgin for drop shadows. Navigation cards already has the updated drop shadow styles. However, it hardcodes the value in .lg-card--navigation class.

This PR:

  • Updates the --drop-shadow CSS custom property the latest Canopy design box-shadow value
  • Creates a new CSS custom property called --box-shadow-hover and sets its value to the latest Canopy drop shadow hover state value
  • Updates .lg-card--navigation to use the --drop-shadow CSS custom property, instead of hardcoding it in the class. box-shadow: var(--drop-shadow);
  • Updates .lg-card--navigation:hover to use the --box-shadow-hover CSS custom property, instead of hardcoding it in the class. box-shadow: var(--drop-shadow-hover);
  • Adds a hasHoverState input to LgShadowDirective. Users can opt in to add a hover state drop shadow to their component (typically a card), by setting the hasHoverState.
  • Adds unit tests for hasHoverState input in LgShadowDirective
  • Updates storybook guide and examples for Shadow
  • Updates storybook guide and examples for Promotions

Fixes # (issue)

Requirements

Please briefly outline any requirements for the work which may aid the testing and review process.

Design link: (link to design or delete if not required)
Screenshot: (if appropriate provide a quick screen grab of the changes)

Checklist:

  • The commit messages follow the convention for this project
  • I have provided an adequate amount of test coverage
  • I have added the functionality to the test app
  • I have provided a story in storybook to document the changes
  • I have added the documentation
  • I have added any new public feature modules to public-api.ts

@ashB100 ashB100 requested a review from a team as a code owner January 23, 2025 13:41
@github-actions github-actions bot added the deployed The branch is deployed to GitHub Pages label Jan 23, 2025
elenagarrone
elenagarrone previously approved these changes Jan 27, 2025
Copy link
Contributor

@elenagarrone elenagarrone left a comment

Choose a reason for hiding this comment

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

Looks good 👍 Thank you 🙏

Copy link
Contributor

@owensgit owensgit left a comment

Choose a reason for hiding this comment

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

Great work @ashB100, just a tiny suggestion from me

Copy link
Contributor

@Xinchro Xinchro left a comment

Choose a reason for hiding this comment

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

🚀

@ashB100 ashB100 requested a review from elenagarrone January 27, 2025 15:14
@ashB100 ashB100 enabled auto-merge (rebase) January 28, 2025 09:51
@ashB100 ashB100 merged commit 1a4835d into Legal-and-General:master Jan 28, 2025
3 checks passed
@github-actions
Copy link
Contributor

🎉 This PR is included in version 13.0.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

deployed The branch is deployed to GitHub Pages released

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants