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

Able to crop image but images in style format are getting saved as black block images. #60

Open
akshay-dhobale opened this issue Mar 4, 2021 · 0 comments

Comments

@akshay-dhobale
Copy link

I followed all steps required but sometimes when I resize the cropper and save image it crops image correctly and saves correct "Original" image but small, thumbnail, large this variants of same image are getting saved as black color block.
image style types: small, medium, large, thumbnail

has_attached_file :header_image, styles: { small: "720x300#", medium: "1440x600#", large: "2880x1200#",thumbnail: "360x360#", original: {convert_options: '-strip'} }, default_url: "/assets/missing1.png", hash_data: ":class/:attachment/:id/:style", path: '/:class/:attachment/:id_partition/:style/:hash', hash_secret: PAPERCLIP_HASH_SECRET crop_attached_file :header_image, :aspect => "12:5" validates_attachment_content_type :header_image, :content_type => ["image/jpg", "image/jpeg", "image/png", "image/gif"]

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

No branches or pull requests

1 participant