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

feat(ras-acc): add basic SVG handling? #3118

Merged
merged 4 commits into from
May 29, 2024

Conversation

laurelfulford
Copy link
Contributor

@laurelfulford laurelfulford commented May 15, 2024

All Submissions:

Changes proposed in this Pull Request:

I'm not sure we actually need this, but this PR takes a swing at consolidating all the SVGs used in the Newspack UI, and sets up a couple function to return or echo them.

This is a riff off of what's in the Newspack Theme, and might be overkill/clunky - it could also work to centralize and add on the individual functions that return the markup, like we're already doing in RAS-ACC -- open to feedback on that!

I haven't made any changes on the Newspack Blocks side yet; the duplication seems like an okay trade off for still having the SVGs work when the Newspack Plugin is disabled, but if this seems like a good plan we could do something similar there for the checkout-related SVGs.

How to test the changes in this Pull Request:

  1. Apply the PR.
  2. Check the ?ui-demo and make sure the SVGs are loading.
  3. View as a non-logged in user and confirm the Sign In link in the header still has the icon.

Other information:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes, as applicable?
  • Have you successfully ran tests with your changes locally?

@laurelfulford laurelfulford added the [Status] Needs Review The issue or pull request needs to be reviewed label May 24, 2024
@laurelfulford laurelfulford marked this pull request as ready for review May 24, 2024 16:42
@laurelfulford laurelfulford requested a review from a team as a code owner May 24, 2024 16:42
Copy link
Member

@adekbadek adekbadek left a comment

Choose a reason for hiding this comment

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

Nice! I think it's a needed change, makes the code much more readable and abstracts away the clunkiness of SVG markup.

@github-actions github-actions bot added [Status] Approved The pull request has been reviewed and is ready to merge and removed [Status] Needs Review The issue or pull request needs to be reviewed labels May 29, 2024
@laurelfulford
Copy link
Contributor Author

Thanks @adekbadek! 🙌

@laurelfulford laurelfulford merged commit 15e6df0 into epic/ras-acc May 29, 2024
8 checks passed
@laurelfulford laurelfulford deleted the feat/basic-svg-system branch May 29, 2024 17:34
@matticbot
Copy link
Contributor

🎉 This PR is included in version 4.1.0-epic-ras-acc.2 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@matticbot
Copy link
Contributor

🎉 This PR is included in version 4.2.0-epic-ras-acc.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
released on @epic/ras-acc [Status] Approved The pull request has been reviewed and is ready to merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants