SpyGuard/app/frontend/dist/js/chunk-0d175fb6.abef9fad.js.map
2022-11-06 15:51:33 +01:00

1 line
9.6 KiB
Plaintext

{"version":3,"sources":["webpack:///./src/views/save-capture.vue?3f48","webpack:///./src/views/save-capture.vue","webpack:///src/views/save-capture.vue","webpack:///./src/views/save-capture.vue?6c0a","webpack:///./src/views/save-capture.vue?e430"],"names":["render","_vm","this","_c","_self","staticClass","save_usb","init","class","saved","usb","on","$event","new_capture","_e","_v","_s","$t","attrs","download_url","staticRenderFns","name","components","data","props","capture_token","methods","check_usb","console","axios","timeout","then","clearInterval","save_capture","clearTimeout","router","created","component"],"mappings":"kHAAA,W,yCCAA,IAAIA,EAAS,WAAkB,IAAIC,EAAIC,KAAKC,EAAGF,EAAIG,MAAMD,GAAG,OAAOA,EAAG,MAAM,CAACE,YAAY,WAAW,CAAEJ,EAAIK,UAAYL,EAAIM,KAAMJ,EAAG,MAAM,CAACE,YAAY,UAAU,CAACF,EAAG,MAAM,CAACE,YAAY,cAAcG,MAAM,CAAC,gBAAiBP,EAAIQ,QAAUR,EAAIS,KAAKC,GAAG,CAAC,MAAQ,SAASC,GAAQ,OAAOX,EAAIY,iBAAiB,EAAGZ,EAAIQ,OAASR,EAAIS,IAAKP,EAAG,MAAM,CAACE,YAAY,iBAAiBJ,EAAIa,KAAMb,EAAIQ,MAAON,EAAG,MAAM,CAACE,YAAY,iBAAiBJ,EAAIa,KAAKX,EAAG,MAAM,CAACE,YAAY,aAAaF,EAAG,MAAM,CAACE,YAAY,oBAAsBJ,EAAIQ,OAAUR,EAAIS,IAAqGT,EAAIa,KAApGX,EAAG,IAAI,CAACE,YAAY,UAAU,CAACF,EAAG,MAAMF,EAAIc,GAAGd,EAAIe,GAAGf,EAAIgB,GAAG,oCAA8ChB,EAAIQ,OAASR,EAAIS,IAAKP,EAAG,IAAI,CAACE,YAAY,UAAU,CAACF,EAAG,MAAMF,EAAIc,GAAGd,EAAIe,GAAGf,EAAIgB,GAAG,kCAAkChB,EAAIa,KAAMb,EAAIQ,MAAON,EAAG,IAAI,CAACE,YAAY,UAAU,CAACF,EAAG,MAAMF,EAAIc,GAAGd,EAAIe,GAAGf,EAAIgB,GAAG,4BAA4BhB,EAAIa,QAASb,EAAIK,UAAYL,EAAIM,KAAMJ,EAAG,MAAM,CAACE,YAAY,UAAU,CAACF,EAAG,MAAM,CAACA,EAAG,IAAI,CAACE,YAAY,UAAU,CAACJ,EAAIc,GAAGd,EAAIe,GAAGf,EAAIgB,GAAG,mCAAmCd,EAAG,MAAMA,EAAG,MAAMA,EAAG,QAAQA,EAAG,SAAS,CAACE,YAAY,kBAAkBM,GAAG,CAAC,MAAQ,SAASC,GAAQ,OAAOX,EAAIY,iBAAiB,CAACZ,EAAIc,GAAGd,EAAIe,GAAGf,EAAIgB,GAAG,sCAAsCd,EAAG,SAAS,CAACE,YAAY,iBAAiBa,MAAM,CAAC,IAAMjB,EAAIkB,oBAAoBlB,EAAIa,QAE3xCM,EAAkB,G,6CC4CP,GACfC,oBACAC,cACAC,OACA,OACAb,OACAD,SACAH,YACAC,UAGAiB,OACAC,sBAEAC,SACAC,qBACAC,mEACAC,+BAAAC,cACAC,SACA,gBACA,YACAC,6BACA,wBAIAC,wBACA,yBACAL,4DACAC,2CAAAC,cACAC,SACA,gBACA,cACAH,yEACA,sDAIAf,uBACAe,+EACAM,2BACAC,aAAAd,uBAGAe,mBACAR,2DACA,8BACAA,0EACA,aACA,iBACA,uEAEAA,oEACA,aACA,iBACA,yDCrGsV,I,wBCQlVS,EAAY,eACd,EACArC,EACAoB,GACA,EACA,KACA,KACA,MAIa,aAAAiB,E","file":"js/chunk-0d175fb6.abef9fad.js","sourcesContent":["export * from \"-!../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--9-oneOf-1-0!../../node_modules/css-loader/dist/cjs.js??ref--9-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--9-oneOf-1-2!../../node_modules/sass-loader/dist/cjs.js??ref--9-oneOf-1-3!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./save-capture.vue?vue&type=style&index=0&id=52e6f598&prod&lang=scss&\"","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',{staticClass:\"wrapper\"},[(_vm.save_usb && _vm.init)?_c('div',{staticClass:\"center\"},[_c('div',{staticClass:\"canvas-anim\",class:{'anim-connect': !_vm.saved && !_vm.usb},on:{\"click\":function($event){return _vm.new_capture()}}},[(!_vm.saved && _vm.usb)?_c('div',{staticClass:\"icon-spinner\"}):_vm._e(),(_vm.saved)?_c('div',{staticClass:\"icon-success\"}):_vm._e(),_c('div',{staticClass:\"icon-usb\"}),_c('div',{staticClass:\"icon-usb-plug\"})]),(!_vm.saved && !_vm.usb)?_c('p',{staticClass:\"legend\"},[_c('br'),_vm._v(_vm._s(_vm.$t(\"save-capture.please_connect\")))]):_vm._e(),(!_vm.saved && _vm.usb)?_c('p',{staticClass:\"legend\"},[_c('br'),_vm._v(_vm._s(_vm.$t(\"save-capture.we_are_saving\")))]):_vm._e(),(_vm.saved)?_c('p',{staticClass:\"legend\"},[_c('br'),_vm._v(_vm._s(_vm.$t(\"save-capture.tap_msg\")))]):_vm._e()]):(!_vm.save_usb && _vm.init)?_c('div',{staticClass:\"center\"},[_c('div',[_c('p',{staticClass:\"legend\"},[_vm._v(_vm._s(_vm.$t(\"save-capture.capture_download\"))),_c('br'),_c('br'),_c('br')]),_c('button',{staticClass:\"btn btn-primary\",on:{\"click\":function($event){return _vm.new_capture()}}},[_vm._v(_vm._s(_vm.$t(\"save-capture.start_capture_btn\")))]),_c('iframe',{staticClass:\"frame-download\",attrs:{\"src\":_vm.download_url}})])]):_vm._e()])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<template>\r\n <div class=\"wrapper\">\r\n <div class=\"center\" v-if=\"save_usb && init\">\r\n <div class=\"canvas-anim\" :class=\"{'anim-connect': !saved && !usb}\" v-on:click=\"new_capture()\">\r\n <div class=\"icon-spinner\" v-if=\"!saved && usb\"></div>\r\n <div class=\"icon-success\" v-if=\"saved\"></div>\r\n <div class=\"icon-usb\"></div>\r\n <div class=\"icon-usb-plug\"></div> \r\n </div>\r\n <p class=\"legend\" v-if=\"!saved && !usb\"><br />{{ $t(\"save-capture.please_connect\") }}</p>\r\n <p class=\"legend\" v-if=\"!saved && usb\"><br />{{ $t(\"save-capture.we_are_saving\") }}</p>\r\n <p class=\"legend\" v-if=\"saved\"><br />{{ $t(\"save-capture.tap_msg\") }}</p>\r\n </div>\r\n <div class=\"center\" v-else-if=\"!save_usb && init\">\r\n <div>\r\n <p class=\"legend\">{{ $t(\"save-capture.capture_download\") }}<br /><br /><br /></p>\r\n <button class=\"btn btn-primary\" v-on:click=\"new_capture()\">{{ $t(\"save-capture.start_capture_btn\") }}</button>\r\n <iframe :src=\"download_url\" class=\"frame-download\"></iframe>\r\n </div>\r\n </div>\r\n </div>\r\n</template>\r\n\r\n<style lang=\"scss\">\r\n \r\n .canvas-anim {\r\n height: 120px;\r\n margin: 0 auto;\r\n position: relative;\r\n width: 205px;\r\n \r\n &.anim-connect {\r\n width: 300px;\r\n\r\n .icon-usb {\r\n -webkit-animation: slide-right 1s cubic-bezier(0.455, 0.030, 0.515, 0.955) infinite alternate both;\r\n animation: slide-right 1s cubic-bezier(0.455, 0.030, 0.515, 0.955) infinite alternate both;\r\n }\r\n }\r\n}\r\n</style>\r\n\r\n<script>\r\nimport axios from 'axios'\r\nimport router from '../router'\r\n\r\nexport default {\r\n name: 'save-capture',\r\n components: {},\r\n data() {\r\n return { \r\n usb: false,\r\n saved: false,\r\n save_usb: false,\r\n init: false\r\n }\r\n },\r\n props: {\r\n capture_token: String\r\n },\r\n methods: {\r\n check_usb: function() {\r\n console.log(\"[save-capture.vue] Checking connected USB device...\");\r\n axios.get(`/api/save/usb-check`, { timeout: 30000 })\r\n .then(response => {\r\n if(response.data.status) {\r\n this.usb = true\r\n clearInterval(this.interval)\r\n this.save_capture()\r\n }\r\n })\r\n },\r\n save_capture: function() {\r\n var capture_token = this.capture_token\r\n console.log(\"[save-capture.vue] Saving the capture on USB\");\r\n axios.get(`/api/save/save-capture/${capture_token}/usb`, { timeout: 30000 })\r\n .then(response => {\r\n if(response.data.status){\r\n this.saved = true\r\n console.log(\"[save-capture.vue] Capture saved, going back to main view\");\r\n this.timeout = setTimeout(() => router.push('/'), 60000);\r\n } \r\n })\r\n },\r\n new_capture: function() {\r\n console.log(\"[save-capture.vue] Capture saved, generating a new access point\");\r\n clearTimeout(this.timeout);\r\n router.push({ name: 'generate-ap' })\r\n }\r\n },\r\n created: function() {\r\n console.log(\"[save-capture.vue] Showing save-capture.vue\");\r\n if(window.config.download_links){\r\n console.log(\"[save-capture.vue] Using download links instead of USB key\");\r\n this.init = true\r\n this.save_usb = false\r\n this.download_url = `/api/save/save-capture/${this.capture_token}/url`\r\n } else {\r\n console.log(\"[save-capture.vue] Using USB key to save the capture\");\r\n this.init = true\r\n this.save_usb = true\r\n this.interval = setInterval(() => { this.check_usb() }, 500);\r\n }\r\n }\r\n}\r\n</script>","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./save-capture.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./save-capture.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./save-capture.vue?vue&type=template&id=52e6f598&\"\nimport script from \"./save-capture.vue?vue&type=script&lang=js&\"\nexport * from \"./save-capture.vue?vue&type=script&lang=js&\"\nimport style0 from \"./save-capture.vue?vue&type=style&index=0&id=52e6f598&prod&lang=scss&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports"],"sourceRoot":""}