1(function() { 2 3 Vue.component("settings-box", { 4 template: "#vue-component-settings-box", 5 props: ["selected", "title", "options", "type", "format"], 6 data: function() { 7 return { 8 box: { 9 hasFormat: (this.format && typeof this.format === "object" && this.format.name && this.format.value), 10 title: this.title, 11 options: this.options, 12 type: this.type, 13 selected: this.selected, 14 }, 15 addResizeClass: false 16 }; 17 }, 18 mounted: function() { 19 window.addEventListener("resize", this.checkWindowHeight); 20 this.checkWindowHeight(); 21 }, 22 beforeDestroy: function() { 23 window.removeEventListener("resize", this.checkWindowHeight); 24 }, 25 methods: { 26 checkWindowHeight: function() { 27 this.addResizeClass = this.$refs.modalContentBox.clientHeight > document.documentElement.clientHeight; 28 }, 29 getFormat: function(what, object) { 30 if(!this.box.hasFormat) return object; 31 return what === "name" ? object[this.format.name] : object[this.format.value]; 32 }, 33 save: function() { 34 this.$emit("change", this.box.selected); 35 }, 36 close: function() { 37 this.$emit("close", this.box.selected); 38 } 39 } 40 }); 41 42})();
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.