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

Crop improvements and toolbar overlapped fix #666

Merged
merged 1 commit into from Aug 14, 2021

Conversation

tsahi-deri
Copy link

@tsahi-deri tsahi-deri commented Jun 14, 2021

  1. Added circle crop type
  2. Added crop overlay color configuration. Previously, the default one was white and barely visible (specially on top of light background photos)
  3. Added grid overlay configuration
  4. Fixed toolbar overlapped by image. Previously, for ratio less than 1 the image was overlapping the toolbar and its buttons

Note:
This is my first experience using Stevia, so I believe there are more convenient ways to layout YPCropView subviews rather than my implementation.

@justdan0227
Copy link

Has this been merged? When you crop do you now get an outline of the crop area (again very hard to use with standard white background)

@tsahi-deri
Copy link
Author

@justdan0227
The pull request is still open (not merged).
Yeah, now you can see the crop area specially for ratio less than 1. In addition you can customize the overlay color to match with you app design and needs using the property below.
/// Defines the crop overlay color. Default is label color with alpha of 0.4
public var cropOverlayColor: UIColor = .ypLabel.withAlphaComponent(0.4)

In the example below the showsCrop property was set to .rectangle(ratio: 0.4)
Simulator Screen Shot - iPhone 12 - 2021-07-05 at 21 50 02

@justdan0227
Copy link

Thanks until this is merged I can't find cropOverlayColor to try out your suggestion above?

@tsahi-deri
Copy link
Author

Try to checkout my fork: https://github.com/tsahi-deri/YPImagePicker

@justdan0227
Copy link

Bingo! Thanks!

@NikKovIos
Copy link
Collaborator

Take a look with this crop functional already merged 6c5460a

@tsahi-deri
Copy link
Author

@NikKovIos My implementation was indeed based on that pull request but I also added a couple necessary fixes on top of it. Please take a look in PR description.

@NikKovIos
Copy link
Collaborator

@tsahi-deri Sorry, I didn't find your PR first. Could you please pull from YPImagePicker master and test your implementation. If it is ok, I will merge it too.

@tsahi-deri
Copy link
Author

@NikKovIos Done, please check my PR. Thanks

@NikKovIos NikKovIos merged commit 440865b into Yummypets:master Aug 14, 2021
@tsahi-deri tsahi-deri deleted the feature/crop-improvements branch August 17, 2021 21:57
@tsahi-deri
Copy link
Author

@NikKovIos Will you create a new release soon with all latest changes ?

@NikKovIos
Copy link
Collaborator

@tsahi-deri think so. Now @s2mr gonna check spm and cocapods dependency and then we will ready to release.

@tsahi-deri
Copy link
Author

@s2mr Hey, any update about the next release ?

@justdan0227
Copy link

Why is it that cropOverlayColor is not found in master? Has this not been merged?

@tsahi-deri
Copy link
Author

@justdan0227 The branch is fully merged into master but a new version is not released yet.
So you probably checked out version 4.5.0 without this feature.

@s2mr any update about the next release ?

@s2mr
Copy link
Contributor

s2mr commented Sep 17, 2021

Sorry, I don't know this topic.
Did you make a mistake mention?

@tsahi-deri
Copy link
Author

@s2mr Please see NikKovIos comment above regarding the a new release with all latest changes.

@NikKovIos
Copy link
Collaborator

Check 5.0.0 release please.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants