First commit
This commit is contained in:
37
application/demo/comment/edit/comment.deleteButton.js
Normal file
37
application/demo/comment/edit/comment.deleteButton.js
Normal file
@@ -0,0 +1,37 @@
|
||||
|
||||
import button from '/elements/button.js';
|
||||
|
||||
export default class deleteButton extends button {
|
||||
|
||||
label = "Delete";
|
||||
|
||||
#ifdef ANDROID
|
||||
|
||||
fontSize = 12;
|
||||
|
||||
width = "auto"
|
||||
|
||||
height = "auto"
|
||||
|
||||
#endif
|
||||
|
||||
async click() {
|
||||
|
||||
var sure = confirm("Are you sure you want to delete this Post");
|
||||
|
||||
if( sure ) {
|
||||
|
||||
this.parent.parent.delete();
|
||||
|
||||
this.parent.parent.remove();
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user