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(icons): add flag icons #493

Merged
merged 5 commits into from
Jan 26, 2021
Merged

Conversation

jorgemoya
Copy link
Contributor

@jorgemoya jorgemoya commented Jan 13, 2021

What

Add flag icons.

How

Added the flag-icon-css library to use their 4x3 SVG icons. Complete list of icons: https://flagicons.lipis.dev/.

Issues

Typescript has two issues with two of the flags, opened two PRs (1, 2) to solve this.

Ping @bigcommerce/frontend

Screenshot

new-image

Testing

My initial testing reveals tree shaking is working properly.

Importing icons doesn't return the flags.
Screen Shot 2021-01-14 at 12 29 30 PM

Screen Shot 2021-01-14 at 12 32 14 PM

I can import a single flag
Screen Shot 2021-01-14 at 12 34 44 PM

Or all the flags:
Screen Shot 2021-01-14 at 12 33 33 PM

@jorgemoya jorgemoya force-pushed the icon-falgs branch 3 times, most recently from dede4af to 8e83d06 Compare January 20, 2021 16:08
@jorgemoya jorgemoya marked this pull request as ready for review January 20, 2021 16:16
@jorgemoya jorgemoya requested a review from a team as a code owner January 20, 2021 16:16
@jorgemoya jorgemoya requested review from deini and a team January 20, 2021 16:17
@jorgemoya jorgemoya changed the title WIP: feat(icons): add flag icons feat(icons): add flag icons Jan 20, 2021
Copy link
Contributor

@chanceaclark chanceaclark 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, just have one commented line of code I noticed.

@@ -0,0 +1,80 @@
const { default: svgr } = require('@svgr/core');
// const camelcase = require('camelcase');
Copy link
Contributor

Choose a reason for hiding this comment

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

Intended comment?

@jorgemoya jorgemoya merged commit 0519c8a into bigcommerce:master Jan 26, 2021
@jorgemoya jorgemoya deleted the icon-falgs branch January 26, 2021 19:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants