-
Notifications
You must be signed in to change notification settings - Fork 43
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
Feature/add crop screen #83
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @ajmaurya99 !
This is amazing and I love all the comments you've left throughout the code. Everything is very well explained and the code is easy to follow.
I've added some comments as per your request to review this which has mostly formatting things.
@@ -329,8 +330,7 @@ public function avatar_settings_field( $args ) { | |||
* | |||
* @param object $profileuser User object | |||
*/ | |||
public function edit_user_profile( $profileuser ) { | |||
?> | |||
public function edit_user_profile( $profileuser ) { ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
public function edit_user_profile( $profileuser ) { ?> | |
public function edit_user_profile( $profileuser ) { | |
?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ajmaurya99 please add this suggestion by Helen.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works great! Could you possibly take a pass to reduce/remove the whitespace and other unrelated changes, as well as extraneous code comments that aren't needed for this context?
@helen I have modified the PR based on your comments, Please have a look. |
Another general thing here is that |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ajmaurya99 Great work! the functionality is working as per the expectations.
- Can you please work on the suggestions by Helen?
- The
package.json
file was recently added via Introducing Package file #94. Please resolve the conflicts. - Few more suggestions below, it's negligible but good to be done now than later, please check.
@faisal-alvi I have replaced the |
@faisal-alvi the current feature branch is synced with the develop branch. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ajmaurya99 thanks for the changes, added a few small suggestions, can you please check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ajmaurya99 a couple of very tiny changes, everything else is good! Thanks for the efforts!
Then we are good to go 🚀.
private $user_id_being_edited, $avatar_upload_error, $remove_nonce, $avatar_ratings; | ||
public $options; | ||
|
||
/** | ||
* Set up the hooks and default values | ||
*/ | ||
public function __construct() { | ||
$this->options = (array) get_option( 'simple_local_avatars' ); | ||
$this->options = (array) get_option( 'simple_local_avatars' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove extra space from the beginning of the variable.
@@ -329,8 +330,7 @@ public function avatar_settings_field( $args ) { | |||
* | |||
* @param object $profileuser User object | |||
*/ | |||
public function edit_user_profile( $profileuser ) { | |||
?> | |||
public function edit_user_profile( $profileuser ) { ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ajmaurya99 please add this suggestion by Helen.
@faisal-alvi I have added the code indentation changes, Please have a look. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀
Description of the Change
Select Avatar
CTA is renamed toSelect Avatar and Crop
.Screenshots
Alternate Designs
None
Benefits
Now the users can crop their Avatar as they want it to appear on the website.
Possible Drawbacks
Currently i havent used the
api.CroppedImageControl
andapi.SiteIconControl
but these can be used, in order to make the code more robust.Verification Process
Checklist:
Applicable Issues
#65
Changelog Entry