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

In Vue advanced cropper , the moving class (vue-rectangle-stencil--moving) is not removing automatically when I stop moving the mouse, but if I refresh the page once means , it is removing automatically and working as expected. #267

Open
pravkanth opened this issue Feb 12, 2024 · 1 comment

Comments

@pravkanth
Copy link

I am using vue 2, vue advanced cropper version 1.11.6, there is no error message in console.

<template>
    <div>
    <b-sidebar  id="car-all-details" title="Sidebar with backdrop" backdrop right no-header prop no-close-on-esc no-close-on-backdrop>
        <div class="cropper_container d-flex w-100 mt-5">
            <div class="ml-3 w-50">
                <cropper
                    ref="cropper"
                    class="upload-example-cropper cropper"
                    :src="image"
                    @change="cropperChangedNew"
                    :maxWidth="sizeRestriction.maxWidth"
                    :minWidth="sizeRestriction.minWidth"
                    :maxHeight="sizeRestriction.maxHeight"
                    :minHeight="sizeRestriction.minHeight"
         />
            </div>
       </div>
    </b-sidebar>
</div>
<script> import Vue from "vue"; import { Cropper } from 'vue-advanced-cropper' import 'vue-advanced-cropper/dist/style.css'; Vue.use(Cropper); export default { data(){ return { croppedFinalImg : '' } }, props: ["image", "sizeRestriction"], components: { Cropper }, methods:{ cropperChangedNew({ canvas }) { this.croppedFinalImg = canvas.toDataURL() }, }, mounted(){ this.$refs.cropper.refresh() this.$root.$emit('bv::toggle::collapse', 'car-all-details') }, } </script>

I tried to remove the class manually both by code and removing in dev tools , even removing the class, it is not working.

Uploading Screenshot 2024-02-12 at 4.05.09 PM.png…

@Norserium
Copy link
Collaborator

@pravkanth, could you provide the codesandbox to reproduce this issue?

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

2 participants