]> BookStack Code Mirror - bookstack/blobdiff - resources/js/components/submit-on-change.js
Thumbnails: Fixed thumnail orientation
[bookstack] / resources / js / components / submit-on-change.js
index aeacae23213bd96b94290ed9ab6a4e9e131a4b78..52faa1d10d46d2b1fe9701b68fd779b603ba9667 100644 (file)
@@ -1,15 +1,15 @@
+import {Component} from './component';
+
 /**
  * Submit on change
  * Simply submits a parent form when this input is changed.
- * @extends {Component}
  */
-class SubmitOnChange {
+export class SubmitOnChange extends Component {
 
     setup() {
         this.filter = this.$opts.filter;
 
-        this.$el.addEventListener('change', (event) => {
-
+        this.$el.addEventListener('change', event => {
             if (this.filter && !event.target.matches(this.filter)) {
                 return;
             }
@@ -22,5 +22,3 @@ class SubmitOnChange {
     }
 
 }
-
-export default SubmitOnChange;
\ No newline at end of file