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 image stretched #773

Open
giuliastully opened this issue Apr 21, 2022 · 0 comments
Open

Crop image stretched #773

giuliastully opened this issue Apr 21, 2022 · 0 comments

Comments

@giuliastully
Copy link

giuliastully commented Apr 21, 2022

After the crop the image is stretched, it does not maintain the aspect ratio.

I use this:

$image_crop = $("#cover_image").croppie({
        enableExif: true,
        enableOrientation: true,
        viewport: {
            width: 360,
            height: 270,
            type: "square" //circle
        },

        boundary: {
            width: 360,
            height: 270
        }

    });


    $image_crop
            .croppie("result", {
                type: "canvas",
                size: 'original',
                circle: 'false',
            })

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