before remerve from turbo to master
This commit is contained in:
@ -1,34 +0,0 @@
|
||||
import { Controller } from '@hotwired/stimulus'
|
||||
import Swal from 'sweetalert2'
|
||||
|
||||
export default class extends Controller {
|
||||
static values = {
|
||||
cropImage: String
|
||||
}
|
||||
|
||||
connect() {
|
||||
console.log('crop', this.cropImageValue)
|
||||
window.CropAvatar = this
|
||||
}
|
||||
|
||||
open() {
|
||||
console.log('open crop')
|
||||
Swal.fire({
|
||||
title: 'Are you sure?',
|
||||
text: "You won't be able to revert this!",
|
||||
icon: 'warning',
|
||||
showCancelButton: true,
|
||||
confirmButtonColor: '#3085d6',
|
||||
cancelButtonColor: '#d33',
|
||||
confirmButtonText: 'Yes, delete it!',
|
||||
}).then((result) => {
|
||||
if (result.isConfirmed) {
|
||||
Swal.fire(
|
||||
'Deleted!',
|
||||
'Your file has been deleted.',
|
||||
'success',
|
||||
)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user