{"version":3,"sources":["webpack:///./src/components/Widgets/GlNetworkTraffic.vue?a1bd","webpack:///./src/components/Widgets/GlNetworkTraffic.vue?f320","webpack:///src/components/Widgets/GlNetworkTraffic.vue","webpack:///./src/components/Widgets/GlNetworkTraffic.vue?c2eb","webpack:///./src/components/Widgets/GlNetworkTraffic.vue","webpack:///./src/mixins/GlancesMixin.js"],"names":["render","_vm","this","_h","$createElement","_c","_self","staticClass","attrs","chartId","staticRenderFns","mixins","components","data","computed","limit","endpoint","methods","processData","trafficData","upload","download","Object","preliminary","timeLabels","uploadData","downloadData","name","type","values","labels","datasets","getRoundedTime","date","makeTitle","startDate","generateChart","timeChartData","chartTitle","title","height","colors","truncateLegends","lineOptions","regionFill","hideDots","axisOptions","xIsSeries","xAxisMode","tooltipOptions","formatTooltipY","created","component","hostname","options","error","apiVersion","credentials","username","password","stringifiedUser","Authorization","window","btoa","fetchData","makeRequest","then","makeGlancesUrl","apiPath"],"mappings":"kHAAA,W,gECAA,IAAIA,EAAS,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,MAAM,CAACE,YAAY,+BAA+B,CAACF,EAAG,MAAM,CAACE,YAAY,mBAAmBC,MAAM,CAAC,GAAKP,EAAIQ,cAC3MC,EAAkB,G,wHCWP,GACfC,8BACAC,cACAC,KAHA,WAIA,UAEAC,UACAC,MADA,WAEA,gCAEAC,SAJA,WAKA,oEAGAC,SACAC,YADA,SACAC,GAAA,WACA,GACAC,UACAC,aAGAC,oCACA,WACA,yBACA,8BACAH,0BACA,6BACA,SACA,8BACAI,iBACA,aACA,kCACAA,0BAIA,SACA,KACA,KACA,2BACAD,2CACAE,0BACAC,uBAEAH,6CACAI,yBAEA,OACA,CAAAC,cAAAC,WAAAC,UACA,CAAAF,gBAAAC,WAAAC,WAEA,oBACA,oBAAAC,SAAAC,YAAA,IAEAC,eAxCA,SAwCAC,GACA,UACA,wDAEAC,UA5CA,SA4CAC,GACA,iFAEAC,cA/CA,SA+CAC,EAAAC,GACA,gDACAC,QACA1B,OACAe,kBACAY,wBACAC,6BACAC,mBACAC,aACAC,aACAC,YAEAC,aACAC,aACAC,kBAEAC,gBACAC,2BAAA,+BAMAC,QApFA,WAqFA,iCCjGyW,I,wBCQrWC,EAAY,eACd,EACApD,EACAU,GACA,EACA,KACA,WACA,MAIa,aAAA0C,E,6FClBA,QACbtC,SAAU,CAERuC,SAFQ,WAIN,OADKnD,KAAKoD,QAAQD,UAAUnD,KAAKqD,MAAM,6CAChCrD,KAAKoD,QAAQD,UAGtBG,WAPQ,WAQN,OAAOtD,KAAKoD,QAAQE,YAAc,GAGpCC,YAXQ,WAYN,GAAIvD,KAAKoD,QAAQI,UAAYxD,KAAKoD,QAAQK,SAAU,CAClD,IAAMC,EAAkB,GAAH,OAAM1D,KAAKoD,QAAQI,SAAnB,YAA+BxD,KAAKoD,QAAQK,UACjE,MAAO,CAAEE,cAAe,SAAF,OAAWC,OAAOC,KAAKH,KAE/C,OAAO,OAGX3C,QAAS,CAGP+C,UAHO,WAIL9D,KAAK+D,YAAY/D,KAAKc,SAAUd,KAAKuD,aAAaS,KAAKhE,KAAKgB,cAG9DiD,eAPO,SAOQC,GACb,MAAO,GAAP,OAAUlE,KAAKmD,SAAf,gBAA+BnD,KAAKsD,WAApC,YAAkDY","file":"js/chunk-b8d94e6a.eb7b92ff.js","sourcesContent":["export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./GlNetworkTraffic.vue?vue&type=style&index=0&id=0baa6091&scoped=true&lang=scss&\"","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"glances-cpu-history-wrapper\"},[_c('div',{staticClass:\"gl-history-chart\",attrs:{\"id\":_vm.chartId}})])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\n\n\n\n\n","import mod from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--12-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!./GlNetworkTraffic.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--12-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!./GlNetworkTraffic.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./GlNetworkTraffic.vue?vue&type=template&id=0baa6091&scoped=true&\"\nimport script from \"./GlNetworkTraffic.vue?vue&type=script&lang=js&\"\nexport * from \"./GlNetworkTraffic.vue?vue&type=script&lang=js&\"\nimport style0 from \"./GlNetworkTraffic.vue?vue&type=style&index=0&id=0baa6091&scoped=true&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 \"0baa6091\",\n null\n \n)\n\nexport default component.exports","/** Reusable mixin for all Glances widgets */\nexport default {\n computed: {\n /* Required, hostname (e.g. IP + port) for Glances instance */\n hostname() {\n if (!this.options.hostname) this.error('You must specify a \\'hostname\\' for Glances');\n return this.options.hostname;\n },\n /* Optionally specify the API version, defaults to V 3 */\n apiVersion() {\n return this.options.apiVersion || 3;\n },\n /* Optionally specify basic auth credentials for Glances instance */\n credentials() {\n if (this.options.username && this.options.password) {\n const stringifiedUser = `${this.options.username}:${this.options.password}`;\n return { Authorization: `Basic ${window.btoa(stringifiedUser)}` };\n }\n return null;\n },\n },\n methods: {\n /* Make the request to Glances API, and calls handler function with results\n * Requires endpoint attribute and processData method to be implemented by child */\n fetchData() {\n this.makeRequest(this.endpoint, this.credentials).then(this.processData);\n },\n /* Returns URL to Glances API endpoint */\n makeGlancesUrl(apiPath) {\n return `${this.hostname}/api/${this.apiVersion}/${apiPath}`;\n },\n },\n};\n"],"sourceRoot":""}