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

Add new Social Icons widget and deprecate old Social Media Icons widget #8498

Merged
merged 3 commits into from
Mar 27, 2018

Conversation

thomasguillot
Copy link
Contributor

@thomasguillot thomasguillot commented Jan 10, 2018

Fixes #3776
Fixes #7433
Fixes #7601

Closing previous PR/branch (#7454) and opening a new one due to an issue with a rebase.

To keep in line with WPCOM, I’d like to add the new Social Icons
widget. You can add this widget to any site and you should have a new
widget as seen on its documentation page
(https://en.support.wordpress.com/widgets/social-media-icons-widget/).

The old widget should become unavailable to sites not using it. If they
do then we add a “(Deprecated)” to the label.

In social-icons.php, L72, we use the same social-menu.svg file as
the one used for the Social Menu.

…et. Closes #7454

Closing previous PR/branch and opening a new one due to an issue with a rebase.
@thomasguillot thomasguillot requested a review from a team as a code owner January 10, 2018 13:16
@jeherve jeherve changed the title Add new Social Icons widget and deprecate old Social Media Icons widg… Add new Social Icons widget and deprecate old Social Media Icons widget Jan 10, 2018
@jeherve jeherve added [Type] Enhancement Changes to an existing feature — removing, adding, or changing parts of it [Feature] Extra Sidebar Widgets [Status] Needs Review To request a review from fellow Jetpack developers. Label will be renamed soon. [Type] Dotcom Merge labels Jan 10, 2018
Copy link
Member

@zinigor zinigor left a comment

Choose a reason for hiding this comment

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

Found one minor problem.

}

// [DEPRECATION]: Only register widget if active widget exists already
if ( 1 === $has_widget ) {
Copy link
Member

Choose a reason for hiding this comment

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

I think there's some weird type handling going on - I was only able to get deprecated widgets shown on my site after I removed the strict type check from this if, and made it if( $has_widget) . Maybe get_transient or set_transient do something funny here?
Anyway, seems to be working with this one nitpick.

@zinigor zinigor added the [Status] Needs Author Reply We would need you to make some changes or provide some more details about your PR. Thank you! label Jan 29, 2018
@thomasguillot thomasguillot removed the [Status] Needs Author Reply We would need you to make some changes or provide some more details about your PR. Thank you! label Feb 1, 2018
@oskosk oskosk dismissed zinigor’s stale review February 14, 2018 13:35

change request has been addressed

Copy link
Member

@dereksmart dereksmart left a comment

Choose a reason for hiding this comment

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

@thomasguillot If the New Tab checkbox isn't checked, a notice is thrown on the front end with debug on.

( ! ) Notice: Undefined variable: new_tab in /home/dereksma/public_html/wp-content/plugins/jetpack/modules/widgets/social-icons.php on line 137

@dereksmart dereksmart added [Status] Needs Author Reply We would need you to make some changes or provide some more details about your PR. Thank you! and removed [Status] Needs Review To request a review from fellow Jetpack developers. Label will be renamed soon. labels Feb 20, 2018
@dereksmart
Copy link
Member

Will fix #7601 as well

Will set the target attribute to `_blank` or `_self` depending on the new tab option being ticked or not.
@thomasguillot
Copy link
Contributor Author

Hey @dereksmart, thanks for your review. The PHP error should now be fixed.

@thomasguillot thomasguillot removed the [Status] Needs Author Reply We would need you to make some changes or provide some more details about your PR. Thank you! label Feb 22, 2018
@nielslange nielslange added the [Status] Needs Review To request a review from fellow Jetpack developers. Label will be renamed soon. label Mar 11, 2018
@dereksmart
Copy link
Member

LGTM!

@dereksmart dereksmart added [Status] Ready to Merge Go ahead, you can push that green button! and removed [Status] Needs Review To request a review from fellow Jetpack developers. Label will be renamed soon. labels Mar 13, 2018
@zinigor zinigor merged commit 2905fa9 into master Mar 27, 2018
@ghost ghost removed the [Status] Ready to Merge Go ahead, you can push that green button! label Mar 27, 2018
@zinigor zinigor deleted the new-social-icon-widget branch March 27, 2018 19:15
@zinigor zinigor added this to the 6.0 milestone Mar 27, 2018
zinigor added a commit that referenced this pull request Mar 27, 2018
dereksmart pushed a commit that referenced this pull request Mar 27, 2018
* Changelog 6.0: create base for changelog.

* Add #8938 to changelog

* Add #8962 to changelog

* Add #8974 to changelog

* Add #8975 to changelog

* Add #8978 to changelog

* Add #8867 to changelog

* Add #8937 to changelog

* Add #8961 to changelog

* Add #8855 to changelog

* Add #8944 to changelog

* Add #8973 to changelog

* Add #8977 to changelog

* Add #8979 to changelog

* Add #8980 to changelog

* Add #8982 to changelog

* Add #8983 to changelog

* Add #8984 to changelog

* Add #8986 to changelog

* Add #9005 to changelog

* Add #9010 to changelog

* Add #9012 to changelog

* Add #9021 to changelog

* Add #9022 to changelog

* Add #9056 to changelog

* Add #9061 to changelog

* Add #9079 to changelog

* Add #9080 to changelog

* Add #9088 to changelog

* Add #9096 to changelog

* Add #9097 to changelog

* Add #9100 to changelog

* Add #9107 to changelog

* Add #8969 to changelog

* Add #8993 to changelog

* Add #9003 to changelog

* Add #9031 to changelog

* Add #8945 to changelog

* Add #9052 to changelog

* Add #9058 to changelog

* Add #9066 to changelog

* Add #9076 to changelog

* Add #9053 to changelog

* Add #9108 to changelog

* Add #9135 to changelog

* Add #9148 to changelog

* Add #9125 to changelog

* Add #9137 to changelog

* Added testing instructions for 6.0.

* Added IS testing instructions, huge props to @tiagonoronha.

* Added #8498 to changelog.

* Added #8954 to changelog.

* Added #8985 to changelog.

* add #9027

* add #9112 to changelog

* add #9136 to changelog

* add #9102 to changelog

* add #9093 to changelog

* add #9062 to changelog

* add #9172 to changelog
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Extra Sidebar Widgets [Type] Dotcom Merge [Type] Enhancement Changes to an existing feature — removing, adding, or changing parts of it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants