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

Framework: use social-logos package #9399

Merged
merged 3 commits into from
Nov 16, 2016
Merged

Framework: use social-logos package #9399

merged 3 commits into from
Nov 16, 2016

Conversation

gwwar
Copy link
Contributor

@gwwar gwwar commented Nov 15, 2016

Instead of manually copying from https://github.com/Automattic/social-logos this PR pairs with Automattic/social-logos#42 to use it as an external dependency.

Note that this component assumes that react and classnames are available in the parent project.

import SocialLogo from 'social-logos';
<SocialLogo icon="twitter" size={ 48 } />

Misc changes have snuck into the Calypso SocialLogo file over time, so keep an eye out for any breakages. For example, using service names directly eg google_plus and failing to transform the value into kebobCase google-plus

Testing

Tasks

cc @aduth @obenland @lamosty @retrofox

@gwwar gwwar added Framework [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. labels Nov 15, 2016
@matticbot
Copy link
Contributor

@@ -1,12 +1,12 @@
Social Logo
========

Component that renders a single socail-logo svg based on an `icon` prop. It takes a size property but defaults to 24px. For greater sharpness, the icons should only be shown at either 18, 24, 36 or 48px. There's a gallery with all the available icons in devdocs/design.
Copy link
Contributor

@lamosty lamosty Nov 16, 2016

Choose a reason for hiding this comment

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

Could we maybe add a link to https://github.com/Automattic/social-logos in the README? I wouldn't know we are speaking about that package if I didn't see this PR.

Maybe just adding a link to the text: "...renders a single [social-logo](link here) svg based...".

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sounds good 👍 I'll try to follow up in a later PR to show examples in devdocs directly from the package vs here.

@@ -1,12 +1,12 @@
Social Logo
========

Component that renders a single socail-logo svg based on an `icon` prop. It takes a size property but defaults to 24px. For greater sharpness, the icons should only be shown at either 18, 24, 36 or 48px. There's a gallery with all the available icons in devdocs/design.
Component that renders a single social-logo svg based on an `icon` prop. It takes a size property but defaults to 24px. For greater sharpness, the icons should only be shown at either 18, 24, 36 or 48px. There's a gallery with all the available icons in devdocs/design.
Copy link
Contributor

@retrofox retrofox Nov 16, 2016

Choose a reason for hiding this comment

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

stupid comment but should we add px to each size:

18px, 24px, 36px or 48px

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks I'll add this to the social-logo readme

@lamosty
Copy link
Contributor

lamosty commented Nov 16, 2016

Nice work!

LGTM 🚢.

@lamosty lamosty added [Status] Ready to Merge and removed [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. labels Nov 16, 2016
@gwwar
Copy link
Contributor Author

gwwar commented Nov 16, 2016

Thanks for the reviews!

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.

4 participants