Server : Apache/2.4.43 (Win64) OpenSSL/1.1.1g PHP/7.4.6 System : Windows NT USER-PC 6.1 build 7601 (Windows 7 Professional Edition Service Pack 1) AMD64 User : User ( 0) PHP Version : 7.4.6 Disable Function : NONE Directory : C:/Program Files/Avast Software/Avast/gui_resources/default_av/ |
//{"name":"Scans","version":"1.2.578","created":"2021-03-09T09:14:59.577Z"} import t from"./ractive.js";import{EventEmitter as e,serviceRequest as n,eventer as s,napiTracker as a,moduleManager as i,onlineChecker as o,windowApi as c}from"./napi.js";import{productModel as r,soundService as l,napiUtils as d,features as u,settingsService as h,ipmService as p}from"./napiExtensions.js";import{logger as m,stringUtils as f,svelte3Adapter as g,Router as b,deepExtend as w}from"./libs.js";import{nls as _,moment as v}from"./i18n.js";import{objectFromEntriesPolyfill as y}from"./plugins.js";const S="{7C4966F0-D502-412D-A636-ACCC39A24BB2}",x=["auto","delete","repair","chest","nothing"],T={QUICK:"quick",FULL:"full",FOLDER:"folder",EXPLORER:"explorer"},k=["Label","Job","SchedulerEnabled","SchedType","SchedDays","SchedTime","ScanAreas"],C="running",D="ready",A="paused",P="canceled",I="done",L="suspended",R="resolving";class E extends e{constructor(t){super(),this.setData(t),this._status={},this._changed=!1}setData(t){(t=t||{}).type=t.type||t.scanType,this._scanData=t,this._scanId=t.id,this._scanType=t.type}getData(){return JSON.parse(JSON.stringify(this._scanData))}startScan(t={}){if(this._status.status===C)return Promise.resolve(this._status.sessionId);{let e;return e="folder"===this._scanType&&t.path?{guid:this._scanId,path:t.path}:this._scanId,n("app.scanViruses.Start",e).then((t=>null==t?this.getStatus().then((t=>(this.startPolling(t.sessionId),t.sessionId))):(this.startPolling(t),t)))}}stopScan(){return this._status.status===C?n("app.scanViruses.Stop",this._scanId).catch((t=>console.error("Stopping scan "+this._scanId+" failed; error:",t))):Promise.resolve()}isInstalled(){return"boottime"!==this._scanType||r.isInstalled("boottime")}startPolling(t){clearTimeout(this.pollingTimer);const e=n=>{clearTimeout(this.pollingTimer),this.pollingTimer=setTimeout((()=>{this.getStatus(t).then((t=>{this.emit("change",t),t.status===C?e(1e3):this.stopPolling()})).catch((t=>{this.emit("error",t)}))}),n)};return this.pollingTimer||e(1e3),this.getStatus(t)}stopPolling(){return clearTimeout(this.pollingTimer),delete this.pollingTimer,Promise.resolve()}getStatus(t){return n("app.scanViruses.GetStatus",{id:this._scanId,session:t}).then((t=>(this._status=t,t)))}getThreats(t){return n("app.scanViruses.GetResult",{id:this._scanId,session:t}).then((t=>t.page))}resolveThreats(t,e){return n("app.scanViruses.Resolve",{id:this._scanId,session:t,actions:e})}loadProp(t){return n("app.settings.Get",this.getPropPath(t))}saveProp(t,e){const s=this.getPropPath(t),a=Object.assign({value:e},s);return this._changed=!0,n("app.settings.Set",a).then((()=>{k.includes(t)&&this.updateData()}))}saveProps(t){const e=t.map((t=>{const e=this.getPropPath(t.name),s=Object.assign({value:t.value},e);return n("app.settings.Set",s)}));return this._changed=!0,Promise.all(e).then((()=>{t.some((t=>k.includes(t.name)))&&this.updateData()}))}getPropPath(t){return{name:"avcfg://settings/***TaskGUID***/"+t,objectId:this._scanId}}getPropTestAttr(t,e){return void 0!==e?{name:"avcfg://settings/***TaskGUID***/"+t,param:e,objectId:this._scanId}:{name:"avcfg://settings/***TaskGUID***/"+t,objectId:this._scanId}}getId(){return this._scanId}isChanged(){return this._changed}updateData(){Promise.all([n("app.scans.GetScanProps",{id:this._scanId}),this.loadProp("ScanAreas")]).then((t=>{const e=t[1].value.split(";"),n={id:this._scanId,job:t[0].job,label:t[0].label,scanAreas:e,schedule:t[0].schedule,type:t[0].scanType};this.setData(n),this.emit("dataChange",n)}))}}const N=m.createLogger("scans.serviceProxy");const $=new class extends e{constructor(){super(),this._MAIN_SCANS=["full","folder","boottime"],this._scanList=null,this._scans={},this._scanHistory={},this._runningScanIds=[],this._runningScanTypes=[],this._getHistoryPromise=null,this._scansPromise=null,this._runningScansPromise=null,this._brandedComponents={},this._onScanDataChangeRef=this._onScanDataChange.bind(this),s.on("scans.onStatusChanged.ASW_NOTIF_SESSION_CHANGED",this.updateRunningScans.bind(this)),s.on("app.settings.onStatusChanged",this._loadAndUpdateScans.bind(this,!0)),this._loadAndUpdateScans(!0),this.loadRunningScans().then((t=>this.updateRunningScans(t)))}_loadAndUpdateScans(t){return N.debug("_loadAndUpdateScans"),N.debug("...update",t),N.debug("...scan promise already exists",Boolean(this._scansPromise)),N.debug("...scan list",this._scanList),this._scanList&&!t?(N.debug("scan list already loaded"),Promise.resolve(this._scanList)):this._scansPromise&&!t?(N.debug("scan promise exists.. waiting for it"),this._scansPromise):(this._scanList=null,this._scansPromise=n("app.scanViruses.GetScans").then((t=>{this._scansPromise=null;const e=[];return this._scanList=t,t.forEach((t=>{e.push(t.id);let n=this._scans[t.id];n?n.setData(t):(n=new E(t),n.on("dataChange",this._onScanDataChangeRef),this._scans[t.id]=n)})),Object.keys(this._scans).forEach((t=>{e.includes(t)||delete this._scans[t]})),N.debug("scans",this._scans),N.debug("scanList",this._scanList),this.emit("scans",this._scanList),Promise.resolve(this._scanList)})).catch((t=>{this._scansPromise=null,N.error("getting scans failed",t)})))}_scanHistoryUpdate(t){const e={};t.forEach((t=>{const n=Object.assign({},t);e[n.scanId]||(e[n.scanId]={}),e[n.scanId][n.sessionId]=n})),this._scanHistory=e}loadRunningScans(){return this._runningScansPromise||(this._runningScansPromise=n("app.scans.GetStatus").then((t=>(this._runningScansPromise=null,t.runningScans))).catch((t=>{this._runningScansPromise=null,N.error("getting running scans failed",t)}))),this._runningScansPromise}updateRunningScans(t){this._runningScanIds=t.map((t=>t.id)),this._runningScanTypes=t.map((t=>t.type)),this._runningScans=t,this.getScans().then((t=>{t.forEach((t=>{const e=this._runningScanIds.includes(t.id);e&&(this.removeScanAsDone(t.id),this.emit("scanStarted",t.id)),this.emit("running."+t.id,e),this.emit("running."+t.type,e)}))})),this.isSmartScanRunning().then((t=>this.emit("running.smartScan",t)))}getScans(){return N.debug("getScans"),this._loadAndUpdateScans()}getScan(t){return N.debug("getScan",t),t?this.getScans().then((()=>this._scans[t]?(N.debug("scan already exists",this._scans[t]),this._scans[t]):(N.debug("scan does not exists.. creating a new one"),n("app.scans.GetScanProps",{id:t}).then((e=>""===e.label||"????"===e.label?Promise.reject("scan "+t+" not found"):(e.id=t,new E(e))))))):Promise.reject("missing scanId")}getRunningScanIds(){return this._runningScansPromise?this._runningScansPromise.then((()=>this._runningScanIds)):Promise.resolve(this._runningScanIds)}getRunningScanTypes(){return this._runningScansPromise?this._runningScansPromise.then((()=>this._runningScanTypes)):Promise.resolve(this._runningScanTypes)}getRunningScans(){return this._runningScansPromise?this._runningScansPromise.then((()=>this._runningScans)):Promise.resolve(this._runningScans)}createScan(){return n("app.scanViruses.CreateScanOnly").then((t=>t))}deleteScan(t){return this.getScans().then((e=>{const s=this._scans[t],a=e.findIndex((e=>e.id===t));return e.splice(a,1),delete this._scans[t],this.emit("scans",e),n("app.scanViruses.DeleteScan",{id:t}).catch((n=>{throw N.error("deleting scan failed, rolling back",s,n),this._scans[t]=s,e.splice(a,0,s),this.emit("scans",e),n}))}))}unscheduleScan(t){return this.getScan(t).then((t=>t.saveProp("SchedulerEnabled",0)))}getScanHistory(){return this.getHistory().then((t=>(this._scanHistoryUpdate(t),t.sort(((t,e)=>e.startTime-t.startTime))))).catch((t=>{console.error("Getting scan history failed; error:",t)}))}getScanHistoryDetail(t,e){return void 0===this._scanHistory[t]||void 0===this._scanHistory[t][e]?this.getHistory().then((n=>(this._scanHistoryUpdate(n),this._scanHistory[t]&&this._scanHistory[t][e]))).catch((t=>{console.error("Getting scan history failed; error:",t)})):Promise.resolve(this._scanHistory[t]&&this._scanHistory[t][e])}getRunScans(){return this.getHistory().then((t=>{this._scanHistoryUpdate(t);const e={};return t.forEach((t=>{e[t.scanId]=!0})),e})).catch((t=>{console.error("Getting scan history failed; error:",t)}))}getScanRoute(t={}){let e;return e=t.scan?Promise.resolve(t.scan):t.scanId?this.getScans().then((e=>e.find((e=>e.id===t.scanId)))):t.scanType?"custom"===t.scanType?Promise.reject('"custom" scan type is not accepted'):this.getScans().then((e=>e.find((e=>e.type===t.scanType)))):Promise.reject("no scan identificator"),e.then((e=>{if(!e)return;let n;return"SmartScan"===e.job?n="#SmartScan/scan/"+e.id:(n="#Scans/scan/"+e.id,t.scanPath&&(n+="/path/"+t.scanPath)),n}))}openScan(t){this.getScanRoute({scan:t}).then((t=>window.location.hash=t))}openScanSettings(t){this._MAIN_SCANS.includes(t.scanType)?window.location.hash="Settings/Scans/"+t.scanType:window.location.hash="Scans/customScans/"+t.scanId+"/settings"}openScanScheduleDialog(t){this._MAIN_SCANS.includes(t.scanType)?console.warn("schedule dialog not supported for",t):window.location.hash="Scans/customScans/"+t.scanId+"/settings"}isCustomScan(t){return n("app.scans.GetScanProps",{id:t}).then((t=>"custom"===t.scanType))}isScanStoredAsDone(t){return this._getScansStoredAsDone().indexOf(t)>-1}storeScanAsDone(t){const e=this._getScansStoredAsDone();e.indexOf(t)<0&&(e.push(t),localStorage.scansDone=JSON.stringify(e))}removeScanAsDone(t){const e=this._getScansStoredAsDone();if(e.indexOf(t)>-1){const n=e.filter((e=>e!==t));localStorage.scansDone=JSON.stringify(n)}}isSmartScanRunning(){return this.getRunningScanIds().then((t=>!(!t.includes("smart_scan")&&!this._runningScans.find((t=>"SmartScan"===t.job)))))}getSmartScanStatus(){return n("app.smartScan.GetStatus")}setBrandedComponents(t){this._brandedComponents=t}getBrandedComponent(t){if(t)return this._brandedComponents[t]}hasSmartScanReport(){return this.getSmartScanStatus().then((t=>"scan_report"===t.statusPrimary))}_getScansStoredAsDone(){return localStorage.scansDone&&JSON.parse(localStorage.scansDone)||[]}_onScanDataChange(t){N.debug("_onScanDataChange",t),this.getScans().then((e=>{e.find(((n,s)=>{if(n.id===t.id)return e[s]=t,N.debug("..scan list updated",e),this.emit("scans",e),!0}))}))}getHistory(){return this._getHistoryPromise||(this._getHistoryPromise=n("app.scanViruses.GetHistory").then((t=>(this._getHistoryPromise=null,t.forEach((t=>{t.startTimeMs=1e3*t.startTime})),t)))),this._getHistoryPromise}hasVerdictIssue(t){if(!t)return;const e=t.found_resolved,n=t.found_unresolved,s=t.found_resolved_with_error;return e||n||s}};const F=/^\d+(px|%)?$/,O=/^\d+$/i,M=t.extend({template:{v:3,t:[{t:7,e:"span",a:{class:"smartTextTrim__container",style:["width: ",{t:2,r:"width"}]},f:[{t:7,e:"span",a:{"data-content-start":[{t:2,r:"textPartA"}],"data-content-end":[{t:2,r:"textPartB"}]}}]}]},css:".smartTextTrim__container {\n display: inline-block;\n position: relative;\n top: 5px;\n direction: ltr;\n}\n.smartTextTrim__container span:before,\n.smartTextTrim__container span:after {\n display: inline-block;\n max-width: 50%;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.smartTextTrim__container span:before {\n content: attr(data-content-start);\n text-overflow: clip;\n}\n.smartTextTrim__container span:after {\n content: attr(data-content-end);\n direction: rtl;\n unicode-bidi: bidi-override;\n}\n",data:()=>({text:"",width:"",textPartA:"",textPartB:""}),oninit(){this.observe("text",((t,e)=>{t&&t!==e&&(this.set("text",t),this._splitText())})),this._setWidth()},_reverseText(t){if(t){const e=function(t){const e={"(":")",")":"(","[":"]","]":"[","{":"}","}":"{","<":">",">":"<"};return void 0!==e[t]?e[t]:t};return t.split("").reverse().map(e).join("")}return""},_splitText(){const t=this.get("text");try{const e=Math.floor(t.length/2);this.set({textPartA:t.substr(0,e),textPartB:this._reverseText(t.substr(e))})}catch(e){this.set({textPartA:"",textPartB:""}),console.error("SmartTextTrim failed on splitText, error:",e)}},_setWidth(){const t=this.get("width");F.test(t)?O.test(t)&&this.set("width",t+"px"):(console.info("SmartTextTrim was initialized with nonInteger value:",t,"setting to default value:","100%"),this.set("width","100%"))}});var W="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function B(t,e,n){return t(n={path:e,exports:{},require:function(t,e){return U(null==e&&n.path)}},n.exports),n.exports}function U(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var H=B((function(t){(function(){var e={langLocaleCode:"bg",cultureCode:"bg",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"И",million:"А",billion:"M",trillion:"T"},ordinal:function(){return"."},currency:{symbol:"лв.",code:"BGN"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&this.numbro.culture("bg",e)}).call("undefined"==typeof window?W:window)})),j=B((function(t){(function(){var e={langLocaleCode:"cs-CZ",cultureCode:"cs-CZ",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"tis.",million:"mil.",billion:"mld.",trillion:"bil."},ordinal:function(){return"."},currency:{symbol:"Kč",position:"postfix",spaceSeparated:!0,code:"CZK"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),V=B((function(t){(function(){var e={langLocaleCode:"da-DK",cultureCode:"da-DK",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mio",billion:"mia",trillion:"b"},ordinal:function(){return"."},currency:{symbol:"kr",position:"postfix",code:"DKK"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),G=B((function(t){(function(){var e={langLocaleCode:"de-AT",cultureCode:"de-AT",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"€",code:"EUR"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),K=B((function(t){(function(){var e={langLocaleCode:"de-CH",cultureCode:"de-CH",delimiters:{thousands:"'",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"CHF",position:"postfix",code:"CHF"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),z=B((function(t){(function(){var e={langLocaleCode:"de-DE",cultureCode:"de-DE",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"€",position:"postfix",spaceSeparated:!0,code:"EUR"},defaults:{currencyFormat:",4"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),q=B((function(t){(function(){var e={langLocaleCode:"de-LI",cultureCode:"de-LI",delimiters:{thousands:"'",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"CHF",position:"postfix",code:"CHF"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Z=B((function(t){(function(){var e={langLocaleCode:"el",cultureCode:"el",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"χ",million:"ε",billion:"δ",trillion:"τ"},ordinal:function(){return"."},currency:{symbol:"€",code:"EUR"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("el",e)}).call("undefined"==typeof window?W:window)})),J=B((function(t){(function(){var e={langLocaleCode:"en-AU",cultureCode:"en-AU",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1==~~(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th"},currency:{symbol:"$",position:"prefix",code:"AUD"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:"$ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:"$ ,0"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),X=B((function(t){(function(){var e={langLocaleCode:"en-GB",cultureCode:"en-GB",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1==~~(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th"},currency:{symbol:"£",position:"prefix",code:"GBP"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:"$ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:"$ ,0"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Y=B((function(t){(function(){var e={langLocaleCode:"en-IE",cultureCode:"en-IE",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1==~~(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th"},currency:{symbol:"€",code:"EUR"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("en-gb",e)}).call("undefined"==typeof window?W:window)})),Q=B((function(t){(function(){var e={langLocaleCode:"en-NZ",cultureCode:"en-NZ",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1==~~(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th"},currency:{symbol:"$",position:"prefix",code:"NZD"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:"$ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:"$ ,0"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),tt=B((function(t){(function(){var e={langLocaleCode:"en-ZA",cultureCode:"en-ZA",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1==~~(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th"},currency:{symbol:"R",position:"prefix",code:"ZAR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:"$ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:"$ ,0"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),et=B((function(t){(function(){var e={langLocaleCode:"es-AR",cultureCode:"es-AR",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"$",position:"postfix",code:"ARS"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),nt=B((function(t){(function(){var e={langLocaleCode:"es-CL",cultureCode:"es-CL",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"$",position:"prefix",code:"CLP"},defaults:{currencyFormat:"$0,0"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),st=B((function(t){(function(){var e={langLocaleCode:"es-CO",cultureCode:"es-CO",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),at=B((function(t){(function(){var e={langLocaleCode:"es-CR",cultureCode:"es-CR",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"₡",position:"postfix",code:"CRC"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),it=B((function(t){(function(){var e={langLocaleCode:"es-ES",cultureCode:"es-ES",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),ot=B((function(t){(function(){var e={langLocaleCode:"es-MX",cultureCode:"es-MX",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"$",position:"postfix",code:"MXN"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),ct=B((function(t){(function(){var e={langLocaleCode:"es-NI",cultureCode:"es-NI",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"C$",position:"prefix",code:"NIO"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),rt=B((function(t){(function(){var e={langLocaleCode:"es-PE",cultureCode:"es-PE",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"S/.",position:"prefix",code:"PEN"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),lt=B((function(t){(function(){var e={langLocaleCode:"es-PR",cultureCode:"es-PR",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"$",position:"prefix",code:"USD"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),dt=B((function(t){(function(){var e={langLocaleCode:"es-SV",cultureCode:"es-SV",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1===e||3===e?"er":2===e?"do":7===e||0===e?"mo":8===e?"vo":9===e?"no":"to"},currency:{symbol:"$",position:"prefix",code:"SVC"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),ut=B((function(t){(function(){var e={langLocaleCode:"et-EE",cultureCode:"et-EE",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:" tuh",million:" mln",billion:" mld",trillion:" trl"},ordinal:function(){return"."},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),ht=B((function(t){(function(){var e={langLocaleCode:"fa-IR",cultureCode:"fa-IR",delimiters:{thousands:"،",decimal:"."},abbreviations:{thousand:"هزار",million:"میلیون",billion:"میلیارد",trillion:"تریلیون"},ordinal:function(){return"ام"},currency:{symbol:"﷼",code:"IRR"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),pt=B((function(t){(function(){var e={langLocaleCode:"fi-FI",cultureCode:"fi-FI",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"M",billion:"G",trillion:"T"},ordinal:function(){return"."},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),mt=B((function(t){(function(){var e={langLocaleCode:"fil-PH",cultureCode:"fil-PH",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1==~~(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th"},currency:{symbol:"₱",code:"PHP"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),ft=B((function(t){(function(){var e={langLocaleCode:"fr-CA",cultureCode:"fr-CA",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"M",billion:"G",trillion:"T"},ordinal:function(t){return 1===t?"er":"ème"},currency:{symbol:"$",position:"postfix",spaceSeparated:!0,code:"USD"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:"$ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:"$ ,0"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),gt=B((function(t){(function(){var e={langLocaleCode:"fr-CH",cultureCode:"fr-CH",delimiters:{thousands:" ",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(t){return 1===t?"er":"ème"},currency:{symbol:"CHF",position:"postfix",code:"CHF"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),bt=B((function(t){(function(){var e={langLocaleCode:"fr-FR",cultureCode:"fr-FR",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(t){return 1===t?"er":"ème"},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),wt=B((function(t){(function(){var e={langLocaleCode:"he-IL",cultureCode:"he-IL",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"אלף",million:"מליון",billion:"בליון",trillion:"טריליון"},currency:{symbol:"₪",position:"prefix",code:"ILS"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:"₪ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:"₪ ,0"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),_t=B((function(t){(function(){var e={langLocaleCode:"hu-HU",cultureCode:"hu-HU",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"E",million:"M",billion:"Mrd",trillion:"T"},ordinal:function(){return"."},currency:{symbol:" Ft",position:"postfix",code:"HUF"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),vt=B((function(t){(function(){var e={langLocaleCode:"id",cultureCode:"id",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"r",million:"j",billion:"m",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"Rp",code:"IDR"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("id",e)}).call("undefined"==typeof window?W:window)})),yt=B((function(t){(function(){var e={langLocaleCode:"it-CH",cultureCode:"it-CH",delimiters:{thousands:"'",decimal:"."},abbreviations:{thousand:"mila",million:"mil",billion:"b",trillion:"t"},ordinal:function(){return"°"},currency:{symbol:"CHF",code:"CHF"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("it-CH",e)}).call("undefined"==typeof window?W:window)})),St=B((function(t){(function(){var e={langLocaleCode:"it-IT",cultureCode:"it-IT",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"mila",million:"mil",billion:"b",trillion:"t"},ordinal:function(){return"º"},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),xt=B((function(t){(function(){var e={langLocaleCode:"ja-JP",cultureCode:"ja-JP",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"千",million:"百万",billion:"十億",trillion:"兆"},ordinal:function(){return"."},currency:{symbol:"¥",position:"prefix",code:"JPY"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:"$ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:"$ ,0"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Tt=B((function(t){(function(){var e={langLocaleCode:"ko-KR",cultureCode:"ko-KR",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"천",million:"백만",billion:"십억",trillion:"일조"},ordinal:function(){return"."},currency:{symbol:"₩",code:"KPW"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),kt=B((function(t){(function(){var e={langLocaleCode:"lv-LV",cultureCode:"lv-LV",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:" tūkst.",million:" milj.",billion:" mljrd.",trillion:" trilj."},ordinal:function(){return"."},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Ct=B((function(t){(function(){var e={langLocaleCode:"nb-NO",cultureCode:"nb-NO",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"t",million:"M",billion:"md",trillion:"t"},currency:{symbol:"kr",position:"postfix",code:"NOK"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Dt=B((function(t){(function(){var e={langLocaleCode:"nb",cultureCode:"nb",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"t",million:"mil",billion:"mia",trillion:"b"},ordinal:function(){return"."},currency:{symbol:"kr",code:"NOK"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("nb",e)}).call("undefined"==typeof window?W:window)})),At=B((function(t){(function(){var e={langLocaleCode:"nl-BE",cultureCode:"nl-BE",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"mln",billion:"mld",trillion:"bln"},ordinal:function(t){var e=t%100;return 0!==t&&e<=1||8===e||e>=20?"ste":"de"},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Pt=B((function(t){(function(){var e={langLocaleCode:"nl-NL",cultureCode:"nl-NL",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mln",billion:"mrd",trillion:"bln"},ordinal:function(t){var e=t%100;return 0!==t&&e<=1||8===e||e>=20?"ste":"de"},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),It=B((function(t){var e;e={langLocaleCode:"nn",cultureCode:"nn",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"t",million:"mil",billion:"mia",trillion:"b"},ordinal:function(){return"."},currency:{symbol:"kr",code:"NOK"}},t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.language&&window.numbro.language("nn",e)})),Lt=B((function(t){(function(){var e={langLocaleCode:"pl-PL",cultureCode:"pl-PL",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"tys.",million:"mln",billion:"mld",trillion:"bln"},ordinal:function(){return"."},currency:{symbol:" zł",position:"postfix",code:"PLN"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Rt=B((function(t){(function(){var e={langLocaleCode:"pt-BR",cultureCode:"pt-BR",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"mil",million:"milhões",billion:"b",trillion:"t"},ordinal:function(){return"º"},currency:{symbol:"R$",position:"prefix",code:"BRL"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Et=B((function(t){(function(){var e={langLocaleCode:"pt-PT",cultureCode:"pt-PT",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(){return"º"},currency:{symbol:"€",position:"postfix",code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Nt=B((function(t){(function(){var e={langLocaleCode:"ro-RO",cultureCode:"ro-RO",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"mii",million:"mil",billion:"mld",trillion:"bln"},ordinal:function(){return"."},currency:{symbol:" lei",position:"postfix",code:"RON"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),$t=B((function(t){(function(){var e={langLocaleCode:"ro",cultureCode:"ro",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"mie",million:"mln",billion:"mld",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"RON",code:"RON"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("ro",e)}).call("undefined"==typeof window?W:window)})),Ft=B((function(t){(function(){var e={langLocaleCode:"ru-RU",cultureCode:"ru-RU",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"тыс.",million:"млн",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"руб.",position:"postfix",code:"RUB"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Ot=B((function(t){(function(){var e={langLocaleCode:"ru-UA",cultureCode:"ru-UA",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"тыс.",million:"млн",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"₴",position:"postfix",code:"UAH"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Mt=B((function(t){(function(){var e={langLocaleCode:"sk-SK",cultureCode:"sk-SK",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"tis.",million:"mil.",billion:"mld.",trillion:"bil."},ordinal:function(){return"."},currency:{symbol:"€",position:"postfix",spaceSeparated:!0,code:"EUR"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Wt=B((function(t){var e;e={langLocaleCode:"sl",cultureCode:"sl",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"tis.",million:"mil.",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"€",code:"EUR"}},t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("sl",e)})),Bt=B((function(t){var e;e={langLocaleCode:"sr-Cyrl-RS",cultureCode:"sr-Cyrl-RS",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"тыс.",million:"млн",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"RSD",code:"RSD"}},t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("sr-Cyrl-RS",e)})),Ut=B((function(t){(function(){var e={langLocaleCode:"sv-SE",cultureCode:"sv-SE",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"t",million:"M",billion:"md",trillion:"tmd"},currency:{symbol:"kr",position:"postfix",code:"SEK"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Ht=B((function(t){(function(){var e={langLocaleCode:"th-TH",cultureCode:"th-TH",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"พัน",million:"ล้าน",billion:"พันล้าน",trillion:"ล้านล้าน"},ordinal:function(){return"."},currency:{symbol:"฿",position:"postfix",code:"THB"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),jt=B((function(t){(function(){var e={1:"'inci",5:"'inci",8:"'inci",70:"'inci",80:"'inci",2:"'nci",7:"'nci",20:"'nci",50:"'nci",3:"'üncü",4:"'üncü",100:"'üncü",6:"'ncı",9:"'uncu",10:"'uncu",30:"'uncu",60:"'ıncı",90:"'ıncı"},n={langLocaleCode:"tr-TR",cultureCode:"tr-TR",delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"bin",million:"milyon",billion:"milyar",trillion:"trilyon"},ordinal:function(t){if(0===t)return"'ıncı";var n=t%10;return e[n]||e[t%100-n]||e[t>=100?100:null]},currency:{symbol:"₺",position:"postfix",code:"TRY"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=n),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(n.cultureCode,n)}).call("undefined"==typeof window?W:window)})),Vt=B((function(t){(function(){var e={langLocaleCode:"uk-UA",cultureCode:"uk-UA",delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"тис.",million:"млн",billion:"млрд",trillion:"блн"},ordinal:function(){return""},currency:{symbol:"₴",position:"postfix",code:"UAH"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:",0.00 $",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:",0 $"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Gt=B((function(t){(function(){var e={langLocaleCode:"zh-CN",cultureCode:"zh-CN",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"千",million:"百万",billion:"十亿",trillion:"兆"},ordinal:function(){return"."},currency:{symbol:"¥",position:"prefix",code:"CNY"},defaults:{currencyFormat:",4 a"},formats:{fourDigits:"4 a",fullWithTwoDecimals:"$ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00",fullWithNoDecimals:"$ ,0"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Kt=B((function(t){var e;e={langLocaleCode:"zh-MO",cultureCode:"zh-MO",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"千",million:"百萬",billion:"十億",trillion:"兆"},ordinal:function(){return"."},currency:{symbol:"MOP",code:"MOP"}},t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("zh-MO",e)})),zt=B((function(t){(function(){var e={langLocaleCode:"zh-SG",cultureCode:"zh-SG",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"千",million:"百万",billion:"十亿",trillion:"兆"},ordinal:function(){return"."},currency:{symbol:"$",code:"SGD"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture("zh-SG",e)}).call("undefined"==typeof window?W:window)})),qt=B((function(t){(function(){var e={langLocaleCode:"zh-TW",cultureCode:"zh-TW",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"千",million:"百萬",billion:"十億",trillion:"兆"},ordinal:function(){return"第"},currency:{symbol:"NT$",code:"TWD"}};t.exports&&(t.exports=e),"undefined"!=typeof window&&window.numbro&&window.numbro.culture&&window.numbro.culture(e.cultureCode,e)}).call("undefined"==typeof window?W:window)})),Zt=B((function(t,e){e.bg=H,e["cs-CZ"]=j,e["da-DK"]=V,e["de-AT"]=G,e["de-CH"]=K,e["de-DE"]=z,e["de-LI"]=q,e.el=Z,e["en-AU"]=J,e["en-GB"]=X,e["en-IE"]=Y,e["en-NZ"]=Q,e["en-ZA"]=tt,e["es-AR"]=et,e["es-CL"]=nt,e["es-CO"]=st,e["es-CR"]=at,e["es-ES"]=it,e["es-MX"]=ot,e["es-NI"]=ct,e["es-PE"]=rt,e["es-PR"]=lt,e["es-SV"]=dt,e["et-EE"]=ut,e["fa-IR"]=ht,e["fi-FI"]=pt,e["fil-PH"]=mt,e["fr-CA"]=ft,e["fr-CH"]=gt,e["fr-FR"]=bt,e["he-IL"]=wt,e["hu-HU"]=_t,e.id=vt,e["it-CH"]=yt,e["it-IT"]=St,e["ja-JP"]=xt,e["ko-KR"]=Tt,e["lv-LV"]=kt,e["nb-NO"]=Ct,e.nb=Dt,e["nl-BE"]=At,e["nl-NL"]=Pt,e.nn=It,e["pl-PL"]=Lt,e["pt-BR"]=Rt,e["pt-PT"]=Et,e["ro-RO"]=Nt,e.ro=$t,e["ru-RU"]=Ft,e["ru-UA"]=Ot,e["sk-SK"]=Mt,e.sl=Wt,e["sr-Cyrl-RS"]=Bt,e["sv-SE"]=Ut,e["th-TH"]=Ht,e["tr-TR"]=jt,e["uk-UA"]=Vt,e["zh-CN"]=Gt,e["zh-MO"]=Kt,e["zh-SG"]=zt,e["zh-TW"]=qt})),Jt=B((function(t){(function(){var e,n=["B","KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"],s=["B","KB","MB","GB","TB","PB","EB","ZB","YB"],a={general:{scale:1024,suffixes:s,marker:"bd"},binary:{scale:1024,suffixes:n,marker:"b"},decimal:{scale:1e3,suffixes:s,marker:"d"}},i=[a.general,a.binary,a.decimal],o={},c=o,r="en-US",l=null,d="0,0",u="0$",h=t.exports;function p(t){this._value=t}function m(t){return 0===t?1:Math.floor(Math.log(Math.abs(t))/Math.LN10)+1}function f(t){var e,n="";for(e=0;e<t;e++)n+="0";return n}function g(t,e,n,s){var a,i,o=Math.pow(10,e);return t.toString().indexOf("e")>-1?"-"===(i=function(t,e){var n,s,a,i,o,c;return n=(c=t.toString()).split("e")[0],i=c.split("e")[1],s=n.split(".")[0],a=n.split(".")[1]||"",+i>0?c=s+a+f(i-a.length):(o=+s<0?"-0":"0",e>0&&(o+="."),c=o+(f(-1*i-1)+Math.abs(s)+a).substr(0,e)),+i>0&&e>0&&(c+="."+f(e)),c}(t,e)).charAt(0)&&+i>=0&&(i=i.substr(1)):i=(n(t+"e+"+e)/o).toFixed(e),s&&(a=new RegExp("0{1,"+s+"}$"),i=i.replace(a,"")),i}function b(t,e,n){var s=e.replace(/\{[^\{\}]*\}/g,"");return s.indexOf("$")>-1?_(t,o[r].currency.symbol,e,n):s.indexOf("%")>-1?function(t,e,n){var s,a="",i=100*t._value;e.indexOf(" %")>-1?(a=" ",e=e.replace(" %","")):e=e.replace("%","");(s=y(i,e,n)).indexOf(")")>-1?((s=s.split("")).splice(-1,0,a+"%"),s=s.join("")):s=s+a+"%";return s}(t,e,n):s.indexOf(":")>-1?function(t){var e=Math.floor(t._value/60/60),n=Math.floor((t._value-60*e*60)/60),s=Math.round(t._value-60*e*60-60*n);return e+":"+(n<10?"0"+n:n)+":"+(s<10?"0"+s:s)}(t):y(t._value,e,n)}function w(t,e){var a,i,c,d,u,h=e,p=!1;if(e.indexOf(":")>-1)t._value=function(t){var e=t.split(":"),n=0;3===e.length?(n+=60*Number(e[0])*60,n+=60*Number(e[1]),n+=Number(e[2])):2===e.length&&(n+=60*Number(e[0]),n+=Number(e[1]));return Number(n)}(e);else if(e===l)t._value=0;else{for("."!==o[r].delimiters.decimal&&(e=e.replace(/\./g,"").replace(o[r].delimiters.decimal,".")),a=new RegExp("[^a-zA-Z]"+o[r].abbreviations.thousand+"(?:\\)|(\\"+o[r].currency.symbol+")?(?:\\))?)?$"),i=new RegExp("[^a-zA-Z]"+o[r].abbreviations.million+"(?:\\)|(\\"+o[r].currency.symbol+")?(?:\\))?)?$"),c=new RegExp("[^a-zA-Z]"+o[r].abbreviations.billion+"(?:\\)|(\\"+o[r].currency.symbol+")?(?:\\))?)?$"),d=new RegExp("[^a-zA-Z]"+o[r].abbreviations.trillion+"(?:\\)|(\\"+o[r].currency.symbol+")?(?:\\))?)?$"),u=1;u<n.length&&!p;++u)e.indexOf(n[u])>-1?p=Math.pow(1024,u):e.indexOf(s[u])>-1&&(p=Math.pow(1e3,u));var m=e.replace(/[^0-9\.]+/g,"");""===m?t._value=NaN:(t._value=(p||1)*(h.match(a)?Math.pow(10,3):1)*(h.match(i)?Math.pow(10,6):1)*(h.match(c)?Math.pow(10,9):1)*(h.match(d)?Math.pow(10,12):1)*(e.indexOf("%")>-1?.01:1)*((e.split("-").length+Math.min(e.split("(").length-1,e.split(")").length-1))%2?1:-1)*Number(m),t._value=p?Math.ceil(t._value):t._value)}return t._value}function _(t,e,n,s){var a,i,c=n,l=c.indexOf("$"),d=c.indexOf("("),u=c.indexOf("+"),h=c.indexOf("-"),p="",m="";if(-1===c.indexOf("$")?"infix"===o[r].currency.position?(m=e,o[r].currency.spaceSeparated&&(m=" "+m+" ")):o[r].currency.spaceSeparated&&(p=" "):c.indexOf(" $")>-1?(p=" ",c=c.replace(" $","")):c.indexOf("$ ")>-1?(p=" ",c=c.replace("$ ","")):c=c.replace("$",""),i=y(t._value,c,s,m),-1===n.indexOf("$"))switch(o[r].currency.position){case"postfix":i.indexOf(")")>-1?((i=i.split("")).splice(-1,0,p+e),i=i.join("")):i=i+p+e;break;case"infix":break;case"prefix":i.indexOf("(")>-1||i.indexOf("-")>-1?(i=i.split(""),a=Math.max(d,h)+1,i.splice(a,0,e+p),i=i.join("")):i=e+p+i;break;default:throw Error('Currency position should be among ["prefix", "infix", "postfix"]')}else l<=1?i.indexOf("(")>-1||i.indexOf("+")>-1||i.indexOf("-")>-1?(a=1,(l<d||l<u||l<h)&&(a=0),(i=i.split("")).splice(a,0,e+p),i=i.join("")):i=e+p+i:i.indexOf(")")>-1?((i=i.split("")).splice(-1,0,p+e),i=i.join("")):i=i+p+e;return i}function v(t,e,n){var s,a,i,o=e[0],c=Math.abs(t);if(c>=n){for(s=1;s<e.length;++s)if(a=Math.pow(n,s),i=Math.pow(n,s+1),c>=a&&c<i){o=e[s],t/=a;break}o===e[0]&&(t/=Math.pow(n,e.length-1),o=e[e.length-1])}return{value:t,suffix:o}}function y(t,e,n,s){var a,c,d,u,h,p,b,w,_,y,S,x,T,k,C,D=!1,A=!1,P=!1,I="",L=!1,R=!1,E=!1,N=!1,$=!1,F="",O="",M=Math.abs(t),W="",B=!1,U=!1;if(0===t&&null!==l)return l;if(!isFinite(t))return""+t;if(0===e.indexOf("{")){var H=e.indexOf("}");if(-1===H)throw Error('Format should also contain a "}"');y=e.slice(1,H),e=e.slice(H+1)}else y="";if(e.indexOf("}")===e.length-1&&e.length){var j=e.indexOf("{");if(-1===j)throw Error('Format should also contain a "{"');S=e.slice(j+1,-1),e=e.slice(0,j+1)}else S="";for(T=null===(C=-1===e.indexOf(".")?e.match(/([0-9]+).*/):e.match(/([0-9]+)\..*/))?-1:C[1].length,-1!==e.indexOf("-")&&(B=!0),e.indexOf("(")>-1?(D=!0,e=e.slice(1,-1)):e.indexOf("+")>-1&&(A=!0,e=e.replace(/\+/g,"")),e.indexOf("a")>-1&&(w=e.split(".")[0].match(/[0-9]+/g)||["0"],w=parseInt(w[0],10),L=e.indexOf("aK")>=0,R=e.indexOf("aM")>=0,E=e.indexOf("aB")>=0,N=e.indexOf("aT")>=0,$=L||R||E||N,e.indexOf(" a")>-1?(I=" ",e=e.replace(" a","")):e=e.replace("a",""),h=0===(h=(d=m(t))%3)?3:h,w&&0!==M&&(p=3*~~((Math.min(w,d)-h)/3),M/=Math.pow(10,p)),d!==w&&(M>=Math.pow(10,12)&&!$||N?(I+=o[r].abbreviations.trillion,t/=Math.pow(10,12)):M<Math.pow(10,12)&&M>=Math.pow(10,9)&&!$||E?(I+=o[r].abbreviations.billion,t/=Math.pow(10,9)):M<Math.pow(10,9)&&M>=Math.pow(10,6)&&!$||R?(I+=o[r].abbreviations.million,t/=Math.pow(10,6)):(M<Math.pow(10,6)&&M>=Math.pow(10,3)&&!$||L)&&(I+=o[r].abbreviations.thousand,t/=Math.pow(10,3))),u=m(t),w&&u<w&&-1===e.indexOf(".")&&(e+="[.]",e+=f(w-u))),k=0;k<i.length;++k)if(a=i[k],e.indexOf(a.marker)>-1){e.indexOf(" "+a.marker)>-1&&(F=" "),e=e.replace(F+a.marker,""),t=(c=v(t,a.suffixes,a.scale)).value,F+=c.suffix;break}if(e.indexOf("o")>-1&&(e.indexOf(" o")>-1?(O=" ",e=e.replace(" o","")):e=e.replace("o",""),o[r].ordinal&&(O+=o[r].ordinal(t))),e.indexOf("[.]")>-1&&(P=!0,e=e.replace("[.]",".")),_=e.split(".")[1],x=e.indexOf(","),_){var V=[];if(-1!==_.indexOf("*")?(V=(W=t.toString()).split(".")).length>1&&(W=g(t,V[1].length,n)):W=_.indexOf("[")>-1?g(t,(_=(_=_.replace("]","")).split("["))[0].length+_[1].length,n,_[1].length):g(t,_.length,n),b=(V=W.split("."))[0],V.length>1&&V[1].length)W=(s?I+s:o[r].delimiters.decimal)+V[1];else W="";P&&0===Number(W.slice(1))&&(W="")}else b=g(t,0,n);return b.indexOf("-")>-1&&(b=b.slice(1),U=!0),b.length<T&&(b=f(T-b.length)+b),x>-1&&(b=b.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1"+o[r].delimiters.thousands)),0===e.indexOf(".")&&(b=""),y+(e.indexOf("(")<e.indexOf("-")?(D&&U?"(":"")+(B&&U||!D&&U?"-":""):(B&&U||!D&&U?"-":"")+(D&&U?"(":""))+(!U&&A&&0!==t?"+":"")+b+W+(O||"")+(I&&!s?I:"")+(F||"")+(D&&U?")":"")+S}function S(t,e){o[t]=e}function x(t){r=t;var n=o[t].defaults;n&&n.format&&e.defaultFormat(n.format),n&&n.currencyFormat&&e.defaultCurrencyFormat(n.currencyFormat)}function T(t){var e=t.toString().split(".");return e.length<2?1:Math.pow(10,e[1].length)}function k(){var t=Array.prototype.slice.call(arguments);return t.reduce((function(t,e){var n=T(t),s=T(e);return n>s?n:s}),-1/0)}(e=function(t){return t=e.isNumbro(t)?t.value():"string"==typeof t||"number"==typeof t?e.fn.unformat(t):NaN,new p(Number(t))}).version="1.11.1",e.isNumbro=function(t){return t instanceof p},e.setLanguage=function(t,e){console.warn("`setLanguage` is deprecated since version 1.6.0. Use `setCulture` instead");var n=t,s=t.split("-")[0],a=null;c[n]||(Object.keys(c).forEach((function(t){a||t.split("-")[0]!==s||(a=t)})),n=a||e||"en-US"),x(n)},e.setCulture=function(t,e){var n=t,s=t.split("-")[1],a=null;o[n]||(s&&Object.keys(o).forEach((function(t){a||t.split("-")[1]!==s||(a=t)})),n=a||e||"en-US"),x(n)},e.language=function(t,n){if(console.warn("`language` is deprecated since version 1.6.0. Use `culture` instead"),!t)return r;if(t&&!n){if(!c[t])throw new Error("Unknown language : "+t);x(t)}return!n&&c[t]||S(t,n),e},e.culture=function(t,n){if(!t)return r;if(t&&!n){if(!o[t])throw new Error("Unknown culture : "+t);x(t)}return!n&&o[t]||S(t,n),e},e.languageData=function(t){if(console.warn("`languageData` is deprecated since version 1.6.0. Use `cultureData` instead"),!t)return c[r];if(!c[t])throw new Error("Unknown language : "+t);return c[t]},e.cultureData=function(t){if(!t)return o[r];if(!o[t])throw new Error("Unknown culture : "+t);return o[t]},e.culture("en-US",{delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(t){var e=t%10;return 1==~~(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th"},currency:{symbol:"$",position:"prefix"},defaults:{currencyFormat:",0000 a"},formats:{fourDigits:"0000 a",fullWithTwoDecimals:"$ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00"}}),e.languages=function(){return console.warn("`languages` is deprecated since version 1.6.0. Use `cultures` instead"),c},e.cultures=function(){return o},e.zeroFormat=function(t){l="string"==typeof t?t:null},e.defaultFormat=function(t){d="string"==typeof t?t:"0.0"},e.defaultCurrencyFormat=function(t){u="string"==typeof t?t:"0$"},e.validate=function(t,n){var s,a,i,o,c,r,l,d;if("string"!=typeof t&&(t+="",console.warn&&console.warn("Numbro.js: Value is not string. It has been co-erced to: ",t)),(t=(t=t.trim()).replace(/^[+-]?/,"")).match(/^\d+$/))return!0;if(""===t)return!1;try{l=e.cultureData(n)}catch(u){l=e.cultureData(e.culture())}return i=l.currency.symbol,c=l.abbreviations,s=l.delimiters.decimal,a="."===l.delimiters.thousands?"\\.":l.delimiters.thousands,(null===(d=t.match(/^[^\d\.\,]+/))||(t=t.substr(1),d[0]===i))&&((null===(d=t.match(/[^\d]+$/))||(t=t.slice(0,-1),d[0]===c.thousand||d[0]===c.million||d[0]===c.billion||d[0]===c.trillion))&&(r=new RegExp(a+"{2}"),!t.match(/[^\d.,]/g)&&(!((o=t.split(s)).length>2)&&(o.length<2?!!o[0].match(/^\d+.*\d$/)&&!o[0].match(r):""===o[0]?!o[0].match(r)&&!!o[1].match(/^\d+$/):1===o[0].length?!!o[0].match(/^\d+$/)&&!o[0].match(r)&&!!o[1].match(/^\d+$/):!!o[0].match(/^\d+.*\d$/)&&!o[0].match(r)&&!!o[1].match(/^\d+$/)))))},e.loadLanguagesInNode=function(){console.warn("`loadLanguagesInNode` is deprecated since version 1.6.0. Use `loadCulturesInNode` instead"),e.loadCulturesInNode()},e.loadCulturesInNode=function(){var t=Zt;for(var n in t)n&&e.culture(n,t[n])},"function"!=typeof Array.prototype.reduce&&(Array.prototype.reduce=function(t,e){if(null==this)throw new TypeError("Array.prototype.reduce called on null or undefined");if("function"!=typeof t)throw new TypeError(t+" is not a function");var n,s,a=this.length>>>0,i=!1;for(1<arguments.length&&(s=e,i=!0),n=0;a>n;++n)this.hasOwnProperty(n)&&(i?s=t(s,this[n],n,this):(s=this[n],i=!0));if(!i)throw new TypeError("Reduce of empty array with no initial value");return s}),e.fn=p.prototype={clone:function(){return e(this)},format:function(t,e){return b(this,t||d,void 0!==e?e:Math.round)},formatCurrency:function(t,e){return _(this,o[r].currency.symbol,t||u,void 0!==e?e:Math.round)},formatForeignCurrency:function(t,e,n){return function(t,e,n,s){return _(t,e,n,s)}(this,t,e||u,void 0!==n?n:Math.round)},unformat:function(t){if("number"==typeof t)return t;if("string"==typeof t){var e=w(this,t);return isNaN(e)?void 0:e}},binaryByteUnits:function(){return v(this._value,a.binary.suffixes,a.binary.scale).suffix},byteUnits:function(){return v(this._value,a.general.suffixes,a.general.scale).suffix},decimalByteUnits:function(){return v(this._value,a.decimal.suffixes,a.decimal.scale).suffix},value:function(){return this._value},valueOf:function(){return this._value},set:function(t){return this._value=Number(t),this},add:function(t){var e=k.call(null,this._value,t);return this._value=[this._value,t].reduce((function(t,n){return t+e*n}),0)/e,this},subtract:function(t){var e=k.call(null,this._value,t);return this._value=[t].reduce((function(t,n){return t-e*n}),this._value*e)/e,this},multiply:function(t){return this._value=[this._value,t].reduce((function(t,e){var n=k(t,e),s=t*n;return s*=e*n,s/=n*n}),1),this},divide:function(t){return this._value=[this._value,t].reduce((function(t,e){var n=k(t,e);return t*n/(e*n)})),this},difference:function(t){return Math.abs(e(this._value).subtract(t).value())}},"undefined"!=typeof process&&void 0===process.browser&&process.title&&(-1!==process.title.indexOf("node")||process.title.indexOf("meteor-tool")>0||"grunt"===process.title||"gulp"===process.title)&&e.loadCulturesInNode(),h?t.exports=e:"undefined"==typeof ender&&(this.numbro=e)}).call("undefined"==typeof window?W:window)}));const Xt={ThreatsList:function(e){return t.extend({template:e,twoway:!1,data:()=>({scanId:null,sessionId:null,showActions:null,cta:null,preselectAll:null,loading:!0,threats:[],selectedThreatsIds:[],selectableThreats:[],resolving:!1,allResolved:!1,progress:0,THREAT_ACTIONS:x}),computed:{allResolved:function(){return!this.get("resolving")&&this.get("threats").length>0&&0===this.get("selectableThreats").length},resolvedWithError:function(){return this.get("threats").filter((t=>"err"===t.statusCode)).length},selectableThreatsCount:function(){let t;return t=this.get("allResolved")?this.get("threats").length:this.get("selectableThreats").length,t}},oninit(){$.getScan(this.get("scanId")).then((t=>{this._teardowning||(this._scan=t,this.loadThreats())})),this._setListeners()},_updateData(){this.fire("data",{loading:this.get("loading"),threatsCount:this.get("selectableThreatsCount"),threatsCountTotal:this.get("threats").length,allResolved:this.get("allResolved"),resolvedWithError:this.get("resolvedWithError")})},_setListeners(){this.on("selectAllThreats",((t,e)=>{const n=this.get("selectableThreats");if(this.set("selectedThreatsIds",[]),e||t.node.checked){const t=n.map((t=>t.id));this.set("selectedThreatsIds",t)}this._updateData()})),this.on("selectThreat",((t,e)=>{const n=this.get("selectedThreatsIds");t.node.checked?n.includes(e.id)||n.push(e.id):n.splice(n.indexOf(e.id),1),this.set("selectedThreatsIds",n),this._updateData()})),this.deselectAll=function(){this.set("selectedThreatsIds",[]),this._updateData()},this._deselectAllBind=this.deselectAll.bind(this),window.addEventListener("kin-deselectAll",this._deselectAllBind),this.on("doAction",((t,e)=>{this.set("resolving",!0);const n=this.get("selectedThreatsIds"),s=this.get("threats"),a=this.get("sessionId"),i=[];s.forEach((t=>{n.includes(t.id)?i.push({id:t.id,action:e}):""===t.statusCode&&i.push({id:t.id,action:"nothing"})})),setTimeout((()=>{this._scan.resolveThreats(a,i).then((()=>{this.set("progress",100),this._updateData(),setTimeout((()=>{this.set("preselectAll",!1),this.loadThreats()}),400)}))}),1e3),this._updateData()}))},_isThreatSelectable:t=>"ok"!==t.statusCode&&"err"!==t.statusCode&&"warning"!==t.statusCode,loadThreats(){return this._scan.getThreats(this.get("sessionId")).then((t=>{const e=t.filter((t=>this._isThreatSelectable(t))),n=this.get("preselectAll")?e.map((t=>t.id)):[];this.set({threats:t,selectableThreats:e,selectedThreatsIds:n,resolving:!1,loading:!1,progress:0}),this._updateData()})).catch((t=>{console.error("Getting threats failed; error: "+t)}))},onteardown(){this._teardowning=!0,window.removeEventListener("kin-deselectAll",this._deselectAllBind),this._deselectAllBind=void 0}})}({v:3,t:[{t:7,e:"div",a:{slot:"view-content"},f:[{t:7,e:"kin-table",a:{datalength:[{t:2,r:"threats.length"}],selecteditems:[{t:2,x:{r:["selectedThreatsIds.length","threats.length"],s:"_0||_1"}}],inactive:[{t:2,r:"resolving"}],loading:[{t:2,r:"loading"}]},f:[{t:7,e:"div",a:{slot:"table-header",role:"row",class:"kin_table__header -threatslist"},f:[{t:7,e:"input",v:{click:"selectAllThreats"},a:{type:"checkbox",class:["checkbox ",{t:4,f:["-some-checked"],n:50,x:{r:["allResolved","selectableThreatsCount","selectedThreatsIds.length"],s:"!_0&&_1!==_2&&_2>0"}}," ",{t:4,f:["-checked"],n:50,x:{r:["allResolved","selectableThreatsCount","selectedThreatsIds.length"],s:"_0||(_1===_2&&_2>0)"}}],disabled:[{t:2,x:{r:["selectableThreatsCount.length","allResolved"],s:"_0===0||_1"}}],checked:[{t:2,x:{r:["allResolved","selectedThreatsIds.length"],s:"_0||_1>0"}}],title:[{t:2,x:{r:["nls"],s:'_0("global.selectAllItems")'}}]}}," ",{t:7,e:"div"}," ",{t:7,e:"div",f:[{t:3,x:{r:["nls"],s:'_0("scans.threatName")'}}]}," ",{t:7,e:"div",f:[{t:3,x:{r:["nls"],s:'_0("viruschest.tableHeader.infectedFile")'}}]}," ",{t:7,e:"div"}]}," ",{t:4,f:[{t:7,e:"div",a:{slot:"table-body"},f:[{t:4,f:[{t:7,e:"div",a:{role:"row",class:"kin_table__row -threatslist","data-test":["table-row-",{t:2,r:"@index"}],"aria-rowindex":[{t:2,r:"@index"}]},f:[{t:7,e:"input",a:{class:"checkbox",type:"checkbox",checked:[{t:2,x:{r:["selectedThreatsIds","./id","./statusCode"],s:'_0.includes(_1)||_2==="ok"'}}],disabled:[{t:2,x:{r:["./statusCode"],s:"!!_0"}}],id:["scn-threatlist-item-",{t:2,r:"@index"}],title:[{t:2,x:{r:["nls","global.selectItem"],s:"_0(_1)"}}]},v:{click:{n:"selectThreat",d:[{t:2,r:"."}]}}}," ",{t:7,e:"div",a:{class:["kin_table__icon ",{t:4,f:["-disabled"],n:50,x:{r:["./statusCode"],s:'_0==="err"||_0==="warning"'}}]},f:[{t:7,e:"Icon",a:{name:"virus"}}," ",{t:4,f:[{t:7,e:"kin-icon",a:{class:"scn_sub-icon",name:"badge-critical",size:"16"}}],n:50,x:{r:["./statusCode"],s:'_0!=="ok"'}},{t:4,n:51,f:[{t:7,e:"kin-icon",a:{class:"scn_sub-icon",name:"badge-ok",size:"16"}}],x:{r:["./statusCode"],s:'_0!=="ok"'}}]}," ",{t:7,e:"div",a:{class:[{t:4,f:["-disabled"],n:50,x:{r:["./statusCode"],s:'_0==="err"||_0==="warning"'}}]},f:[{t:7,e:"label",a:{for:["scn-threatlist-item-",{t:2,r:"@index"}],id:["threat-tooltip-opener-",{t:2,r:"@index"}],class:"g-ellipsis g-rtl-fix"},f:[{t:2,r:"./threat"}]}," ",{t:7,e:"Tooltip",a:{openerSelector:["#threat-tooltip-opener-",{t:2,r:"@index"}],showOnEllipsis:"true",cssCls:"-link",position:"bottom",alignment:"left"},f:[{t:2,r:"./threat"}]}]}," ",{t:7,e:"div",a:{class:[{t:4,f:["-disabled"],n:50,x:{r:["./statusCode"],s:'_0==="err"||_0==="warning"'}}]},f:[{t:7,e:"p",a:{id:["path-tooltip-opener-",{t:2,r:"@index"}],class:"g-ellipsis g-ltr"},f:[{t:2,r:"./path"}]}," ",{t:7,e:"Tooltip",a:{openerSelector:["#path-tooltip-opener-",{t:2,r:"@index"}],showOnEllipsis:"true",cssCls:"-link",position:"bottom",alignment:"left"},f:[{t:2,r:"./path"}]}]}," ",{t:7,e:"div",a:{class:"kin_table__end"},f:[{t:4,f:[{t:7,e:"p",a:{class:"p text -secondary"},f:[{t:7,e:"span",a:{class:"spinner -tiny g-margin-right--5"}}," ",{t:3,x:{r:["nls"],s:'_0("global.resolvingEllipsis")'}}]}],n:50,x:{r:["resolving","selectedThreatsIds","./id"],s:"_0&&_1.includes(_2)"}},{t:4,n:51,f:[{t:4,n:50,x:{r:["./statusCode"],s:'_0==="ok"'},f:[{t:7,e:"p",a:{id:["action-tooltip-",{t:2,r:"@index"}],class:"p g-ellipsis text color-ok -text g-margin-right--5"},f:[{t:3,x:{r:["nls","./action"],s:'_0("detection.status."+_1)'}}]}," ",{t:7,e:"Tooltip",a:{showOnEllipsis:"true",openerSelector:["#action-tooltip-",{t:2,r:"@index"}],cssCls:"-link",position:"top",alignment:"center"},f:[{t:3,x:{r:["nls","./action"],s:'_0("detection.status."+_1)'}}]}]},{t:4,n:50,x:{r:["./statusCode"],s:'(!(_0==="ok"))&&(_0==="err"||_0==="warning")'},f:[" ",{t:7,e:"kin-tooltip",f:[{t:7,e:"div",a:{slot:"tooltip-activator"},f:[{t:7,e:"kin-icon",a:{name:"icon-m-action-info",size:"20",id:["error-tooltip-",{t:2,r:"@index"}]}}]}," ",{t:7,e:"div",a:{slot:"tooltip"},f:[{t:7,e:"p",a:{class:"p -small"},f:[{t:2,x:{r:["nls"],s:'_0("detection.status.resolved.error.tooltip")'}}]}]}]}]}],x:{r:["resolving","selectedThreatsIds","./id"],s:"_0&&_1.includes(_2)"}}]}]}],n:52,r:"threats"}]}],n:50,x:{r:["threats.length"],s:"_0>0"}}]}]}," ",{t:4,f:[{t:7,e:"div",a:{slot:"view-actions"},f:[{t:8,r:"actions"}]}],n:50,x:{r:["loading"],s:"!_0"}}],p:{actions:[{t:4,f:[{t:7,e:"div",f:[{t:7,e:"Progress",a:{asymptotic:"true",percentage:[{t:2,r:"progress"}],cssCls:"kin_actions__progress"}}," ",{t:7,e:"h4",a:{class:"h4"},f:[{t:3,x:{r:["nls","selectedThreatsIds.length"],s:'_0("scans.ss2.resolveInProgress.desc",_1)'}}]}]}],n:50,r:"resolving"},{t:4,n:51,f:[{t:4,f:[{t:7,e:"div",f:[{t:7,e:"kin-button",v:{click:"threatsResolved"},a:{size:"small","data-test":"scn_progress_doneBtn"},f:[{t:2,x:{r:["nls","cta"],s:'_0(_1==="done"?"global.done":"global.next")'}}]}]}],n:50,r:"allResolved"},{t:4,n:51,f:[{t:4,n:50,x:{r:["selectedThreatsIds.length"],s:"_0===0"},f:[{t:7,e:"div",a:{class:"kin_actions__left"},f:[{t:3,x:{r:["nls","selectedThreatsIds.length"],s:'_0("viruschest.threatsSelected",_1)'}}]}," ",{t:7,e:"div",f:[{t:7,e:"kin-button",v:{click:{n:"selectAllThreats",d:[{t:2,x:{r:[],s:"true"}}]}},a:{size:"small","data-test":"scn_table_mainCTA"},f:[{t:3,x:{r:["nls"],s:'_0("global.selectAll")'}}]}]}," ",{t:7,e:"div",a:{class:"kin_actions__right"},f:[{t:7,e:"button",a:{class:"a","data-test":"scn_progress_skipBtn"},v:{click:"threatsSkip"},f:[{t:3,x:{r:["nls"],s:'_0("global.skipForNow")'}}]}]}]},{t:4,n:50,x:{r:["selectedThreatsIds.length"],s:"!(_0===0)"},f:[" ",{t:7,e:"div",a:{class:"kin_actions__left"},f:[{t:3,x:{r:["nls","selectedThreatsIds.length"],s:'_0("viruschest.threatsSelected",_1)'}}]}," ",{t:7,e:"div",f:[{t:7,e:"kin-button",v:{click:{n:"doAction",a:"auto"}},a:{size:"small","data-test":"scn_table_mainCTA"},f:[{t:2,x:{r:["nls","selectableThreatsCount","selectedThreatsIds.length"],s:'_0(_1===_2?"global.resolveAll":"global.resolveSelected")'}}]}," ",{t:4,f:[{t:7,e:"kin-dropdown",f:[{t:7,e:"div",a:{slot:"dropdown-activator"},f:[{t:7,e:"kin-button",a:{type:"secondary",size:"small",icononly:"true"},f:[{t:7,e:"kin-icon",a:{name:"icon-s-controls-menu-more",size:"16"}}]}]}," ",{t:7,e:"div",f:[{t:4,f:[{t:4,f:[{t:7,e:"kin-dropdown-item",v:{click:{n:"doAction",d:[{t:2,r:"."}]}},a:{"data-test":["scn_action-",{t:2,r:"."}]},f:[{t:2,x:{r:["nls","."],s:'_0("scans.threatAction."+_1)'}}]}],n:50,x:{r:["."],s:'_0!=="auto"&&_0!="nothing"'}}],n:52,r:"THREAT_ACTIONS"}]}]}],n:50,r:"showActions"}]}," ",{t:4,f:[{t:7,e:"div",a:{class:"kin_actions__right"},f:[{t:7,e:"button",a:{class:"a","data-test":"scn_progress_skipBtn"},v:{click:"threatsSkip"},f:[{t:3,x:{r:["nls"],s:'_0("global.skipForNow")'}}]}]}],n:50,r:"showSkipOnSelected"},{t:4,n:51,f:[{t:7,e:"div",a:{class:"kin_actions__right"},f:[{t:3,x:{r:["nls"],s:'_0("global.escToDeselect")'}}]}],r:"showSkipOnSelected"}]}],r:"allResolved"}],r:"resolving"}]}}),Scan:function(e){return t.extend({template:e,css:".scn_shutdown {\n position: absolute;\n height: 36px;\n display: flex;\n align-content: center;\n left: 40px;\n bottom: -10px;\n}\n.scn_shutdown__label {\n max-width: 250px;\n}\n.scn_page__title {\n display: block;\n max-width: 100%;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.scn_loader {\n text-align: center;\n position: absolute;\n left: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: visible;\n z-index: 2;\n top: 0;\n bottom: 128px;\n right: 0;\n}\n.scn_loader__banner {\n position: absolute;\n left: 0;\n right: 0;\n bottom: 0;\n height: 128px;\n}\n",components:{SmartTextTrim:M},data:()=>({stripHtml:f.stripHtml,section:null,moduleId:null,scanId:null,sessionId:null,path:null,scanData:null,scanStatus:null,scanProgress:0,scanProblemsCount:0,showShutdownMachine:!1,shutdownMachine:!1,allResolved:!1,resolvedWithError:-1,threatsCount:-1,threatsLoaded:!1,scanStopped:!1,modalDialog:null}),computed:{pageStatus:function(){switch(this.get("scanStatus")){case C:case A:case L:return"scanning";case P:case I:case D:case R:return"report";default:return"load"}},kinPageHeading:function(){const t=this.get("pageStatus");if("report"===t){const t=this.get("threatsCount"),e=this.get("allResolved"),n=this.get("resolvedWithError");return e?n>0?_("scans.ss2.resolvedWithError.title",n):_("scans.ss2.allResolved.title"):t>0?_("scans.ss2.results.title",t):""}if("scanning"===t){const t=this.get("scanData");return"custom"===t.type?f.escapeHtml(t.label):_("scans.scanType."+t.type)}return""},customBreadcrumbs:function(){return[{title:this.get("scanData.label")}]}},oninit(){this.components.ThreatsList=$.getBrandedComponent("ThreatsList"),this.listeners=[],this.on("Modal.close",(()=>{this.set("modalDialog",null)})),this.on("stopScan",(()=>{this.scan?this.scan.stopScan().then((()=>{this.set({scanStatus:P,scanStopped:!0}),this.update(),this.setTempShutDownMachine(!1),$.storeScanAsDone(this.scan.getId())})):this.goBack()})),this.on("done ThreatsList.threatsResolved",(()=>{$.storeScanAsDone(this.get("scanId")),this.fire("goBack")})),this.on("ThreatsList.threatsSkip",(()=>{this.set("modalDialog","confirmSkipModal")})),this.on("ThreatsList.data",(({threatsCount:t,loading:e,allResolved:n,resolvedWithError:s})=>{"report"===this.get("pageStatus")&&this.set({threatsCount:t,threatsLoaded:!e,allResolved:n,resolvedWithError:s})})),this.on("runScanAgain",(()=>{this.scan&&(this.set({scanStatus:C}),this.set({sessionId:null,scanProgress:0,scanProblemsCount:0,scanStopped:!1,threatsLoaded:!1,allResolved:!1,threatsCount:-1,resolvedWithError:-1}),this.startScan())})),this.on("shutdownMachineChanged",(t=>{this.setTempShutDownMachine(t.node.checked)})),this.on("backClick",this.backClicked.bind(this)),this.observe("pageStatus",(()=>{const t=this.get("scanStatus");if((t===I||t===P)&&this.firstReport){const e=t===I?"results":"stopped";a.view("Scans/scan/"+this.get("scanData.type")+"/"+e),a.event("Virus Scan","Number of Issues",this.get("scanData.type")+"-"+this.get("scanProblemsCount"),"Scans/scan/"+this.get("scanData.type")+"/"+e),this.firstReport=!1}})),this.initScan()},backClicked(){if("report"!==this.get("pageStatus")||this.get("scanStopped"))return void this.fire("goBack");const t=0===this.get("threatsCount"),e=this.get("allResolved");t||e?this.fire("done"):e||this.set("modalDialog","confirmLeaveModal")},initShutDownCheckbox(t){this.getTempShutDownMachine().then((e=>{void 0!==e&&"performance"!==this.get("scanId")?t?this.set({showShutdownMachine:!0,selected:e}):this.getShutDownMachine().then((n=>{this.set({showShutdownMachine:!0,selected:n||e}),n===e||t||this.setTempShutDownMachine(n)})).catch((()=>{this.set({showShutdownMachine:!0,selected:e})})):this.set({showShutdownMachine:!1})})).catch((()=>{this.set({showShutdownMachine:!1})}))},getTempShutDownMachine(){return n("app.settings.Get",{name:"avcfg://settings/***TaskGUID***/TempShutDownMachine",objectId:this.get("scanId")}).then((t=>{if(t)return!!+t.value}))},getShutDownMachine(){return n("app.settings.Get",{name:"avcfg://settings/***TaskGUID***/ShutDownMachine",objectId:this.get("scanId")}).then((t=>{if(t)return!!+t.value}))},setTempShutDownMachine(t){return n("app.settings.Set",{name:"avcfg://settings/***TaskGUID***/TempShutDownMachine",objectId:this.get("scanId"),value:t?"1":"0"})},initScan(){const t=this.get("scanId"),e=this.get("sessionId");$.getScan(t).then((s=>{this.scan=s,this.set("scanData",this.scan.getData()),this.listeners.push(this.scan.on("change",(t=>{t.status===I&&this.get("scanStatus")!==t.status&&this.playDone(),this.set({scanStatus:t.status,scanProgress:t.progress,scanProblemsCount:t.problemsCount,scanLastScanned:t.lastScanned})}))),this.scan.getStatus(e).then((s=>{this.initShutDownCheckbox(s.status===C),null!=e&&(e<s.sessionId||s.status!==C)?n("app.scanViruses.GetResult",{id:t,session:e}).then((t=>{this.set({scanStatus:I,scanProgress:100,scanProblemsCount:t.totalCount}),this.screenReady(),this.playDone()})).catch((t=>{console.error("Getting scan results failed; error: ",t),this.screenError(_("global.error"))})):($.isScanStoredAsDone(s.scanId)&&($.removeScanAsDone(s.scanId),s.status=D),null!=e&&s.sessionId===e&&s.status===D&&(s.status=I,this.playDone()),s.status===D||s.status===P?this.startScan():(this.firstReport=!0,this.scan.startPolling(e),this.screenReady()))})).catch((()=>{this.goBack()}))})).catch((e=>{console.error("Loading scan "+t+" failed; error:",e),this.goBack()}))},startScan(){this.scan&&(a.view("Scans/scan/"+this.get("scanData.type")+"/start"),this.scanStartTs=Date.now(),this.scan.startScan({path:this.get("path")}).then((t=>{this.set("sessionId",t),this.firstReport=!0,this.screenReady()})).catch((()=>{$.storeScanAsDone(this.get("scanId")),this.goBack()})))},goBack(){this.fire("goBack")},playDone(){(!this.scanStartTs||Date.now()-this.scanStartTs>1e4)&&(l.play("done"),delete this.scanStartTs)},onteardown(){this.scan&&this.scan.stopPolling(),this.listeners.forEach((t=>{t()}))}})}({v:3,t:[{t:7,e:"Screen",f:[{t:7,e:"Page",a:{heading:[{t:2,r:"kinPageHeading"}],cssCls:"-center-header",loading:[{t:2,x:{r:["pageStatus"],s:'_0==="load"'}}],backEvent:"true"},v:{backClick:"backClick"},f:[{t:7,e:"div",a:{slot:"breadcrumbs"},f:[{t:7,e:"Crumbs",a:{section:[{t:2,r:"section"}],moduleId:[{t:2,r:"moduleId"}],customBreadcrumbs:[{t:2,r:"customBreadcrumbs"}]}}]}," ",{t:7,e:"div",a:{slot:"page-content",class:[{t:4,f:["kin_page-content -scan"],n:50,x:{r:["pageStatus"],s:'_0==="scanning"'}}]},f:[{t:4,f:[{t:8,r:"Progress"}],n:50,x:{r:["pageStatus"],s:'_0==="scanning"'}},{t:4,n:51,f:[{t:4,n:50,x:{r:["pageStatus"],s:'_0==="report"'},f:[{t:8,r:"ScanReport"}]}],x:{r:["pageStatus"],s:'_0==="scanning"'}}]}]}]}," ",{t:4,f:[{t:7,e:"Modal",a:{title:[{t:2,x:{r:["nls"],s:'_0("scans.leaveModal.title")'}}],subtitle:[{t:2,x:{r:["nls"],s:'_0("scans.leaveModal.desc")'}}]},f:[{t:7,e:"div",a:{class:"modal__actions"},f:[{t:7,e:"button",a:{autofocus:0,class:"btn -critical"},v:{click:"done"},f:[{t:2,x:{r:["nls"],s:'_0("scans.leaveModal.ignore")'}}]}," ",{t:7,e:"button",a:{class:"btn -secondary g-margin-left--5"},v:{click:"Modal.close"},f:[{t:2,x:{r:["nls"],s:'_0("scans.leaveModal.dontExit")'}}]}]}]}],n:50,x:{r:["modalDialog"],s:'_0==="confirmLeaveModal"'}},{t:4,f:[{t:7,e:"Modal",a:{title:[{t:2,x:{r:["nls"],s:'_0("scans.skipModal.title")'}}],subtitle:[{t:2,x:{r:["nls"],s:'_0("scans.skipModal.desc")'}}]},f:[{t:7,e:"div",a:{class:"modal__actions"},f:[{t:7,e:"button",a:{autofocus:0,class:"btn -critical"},v:{click:"done"},f:[{t:2,x:{r:["nls"],s:'_0("global.skip")'}}]}," ",{t:7,e:"button",a:{class:"btn -secondary g-margin-left--5"},v:{click:"Modal.close"},f:[{t:2,x:{r:["nls"],s:'_0("scans.skipModal.dontSkip")'}}]}]}]}],n:50,x:{r:["modalDialog"],s:'_0==="confirmSkipModal"'}}," "],p:{Progress:[{t:4,f:[{t:7,e:"div",a:{class:"kin_scan"},f:[{t:7,e:"div",a:{slot:"description"},f:[{t:7,e:"p",a:{class:"kin_description__text -center"},f:[{t:4,f:[{t:2,x:{r:["nls","scanData.label"],s:'_0("scans.runningScan",_1)'}}],n:50,x:{r:["scanData.type"],s:'_0==="custom"||_0==="quick"||_0==="menu"'}},{t:4,n:51,f:[{t:2,x:{r:["nls","scanData.type"],s:'_0("scans.scanType."+_1+".caption")'}}],x:{r:["scanData.type"],s:'_0==="custom"||_0==="quick"||_0==="menu"'}}]}]}," ",{t:7,e:"div",a:{class:"kin_scan__progress"},f:[{t:7,e:"kin-progress",a:{percentage:[{t:2,r:"scanProgress"}],dotted:"true"}}]}," ",{t:7,e:"div",a:{class:"kin_scan__subtitle -overlay"},f:[{t:4,f:[{t:7,e:"SmartTextTrim",a:{text:[{t:2,r:"scanLastScanned"}],width:"60%"}}],n:50,r:"scanLastScanned"}]}," ",{t:7,e:"div",a:{class:"kin_scan__actions"},f:[{t:7,e:"button",a:{class:"btn -secondary -medium -submit","data-test":"scn_progress_stopBtn"},v:{click:"stopScan"},f:[{t:2,x:{r:["nls"],s:'_0("global.stopScan")'}}]}," ",{t:4,f:[{t:7,e:"div",a:{class:"scn_shutdown"},f:[{t:7,e:"input",a:{id:"tempShutDownMachine",type:"checkbox",class:"checkbox",checked:[{t:2,r:"selected"}]},v:{change:"shutdownMachineChanged"}}," ",{t:7,e:"label",a:{for:"tempShutDownMachine",class:"scn_shutdown__label span -secondary -small g-align--left g-margin-left--5"},f:[{t:2,x:{r:["nls"],s:'_0("scans.settings.shutDownAfterScan")'}}]}]}],n:50,r:"showShutdownMachine"}]}]}],n:50,x:{r:["scanProgress"],s:"_0<100"}}],ScanReport:[{t:4,f:[{t:7,e:"div",a:{class:"scn_loader"},f:[{t:7,e:"div",a:{class:"kin_scan__result"},f:[{t:7,e:"kin-icon",a:{name:"circle-critical",class:"kin_scan__icon",size:"96"}}," ",{t:7,e:"h1",a:{class:"h1 kin_scan__title"},f:[{t:3,x:{r:["nls"],s:'_0("smartscan.ss2.scanStopped.title")'}}]}," ",{t:7,e:"p",a:{class:"kin_scan__subtitle"},f:[{t:3,x:{r:["nls"],s:'_0("smartscan.ss2.scanStopped.subtitle")'}}]}]}," ",{t:7,e:"div",a:{class:"kin_scan__actions"},f:[{t:7,e:"button",a:{class:"btn -medium -submit","data-test":"scn_progress_scanAgainBtn"},v:{click:"runScanAgain"},f:[{t:3,x:{r:["nls"],s:'_0("smartscan.ss2.scanStopped.scanAgain")'}}]}," ",{t:7,e:"button",a:{class:"btn -medium -submit -secondary g-margin-left--10","data-test":"scn_progress_doneBtn"},v:{click:"done"},f:[{t:3,x:{r:["nls"],s:'_0("global.goBack")'}}]}]}]}],n:50,r:"scanStopped"},{t:4,n:51,f:[{t:4,n:50,x:{r:["threatsLoaded","threatsCount"],s:"_0&&_1===0"},f:[{t:7,e:"div",a:{class:"scn_loader"},f:[{t:7,e:"div",a:{class:"kin_scan__result"},f:[{t:7,e:"kin-icon",a:{name:"circle-ok",class:"kin_scan__icon",size:"96"}}," ",{t:7,e:"h1",a:{class:"h1 kin_scan__title"},f:[{t:3,x:{r:["nls"],s:'_0("scans.ss2.noIssues.title")'}}]}," ",{t:7,e:"p",a:{class:"kin_scan__subtitle"},f:[{t:3,x:{r:["nls"],s:'_0("scans.ss2.noIssues.subtitle")'}}]}]}," ",{t:7,e:"div",a:{class:"kin_scan__actions"},f:[{t:7,e:"button",a:{class:"btn -medium -submit","data-test":"scn_progress_doneBtn"},v:{click:"done"},f:[{t:3,x:{r:["nls"],s:'_0("global.done")'}}]}]}]}," ",{t:7,e:"div",a:{class:"scn_loader__banner"},f:[{t:7,e:"Ipm",a:{id:"157"}}]}]},{t:4,n:50,x:{r:["threatsLoaded","threatsCount"],s:"!(_0&&_1===0)"},f:[" ",{t:7,e:"kin-view",a:{actionbar:"true"},f:[{t:4,f:[{t:7,e:"div",a:{slot:"description",class:"kin_description__text -center"},f:[{t:4,f:[{t:4,f:[{t:2,x:{r:["nls","resolvedWithError"],s:'_0("scans.ss2.resolvedWithError.subtitle",_1)'}}],n:50,r:"resolvedWithError"},{t:4,n:51,f:[{t:2,x:{r:["nls"],s:'_0("scans.ss2.allResolved.subtitle")'}}],r:"resolvedWithError"}],n:50,r:"allResolved"},{t:4,n:51,f:[{t:2,x:{r:["nls"],s:'_0("scans.ss2.results.subtitle")'}}],r:"allResolved"}]}],n:50,r:"threatsLoaded"}," ",{t:7,e:"ThreatsList",a:{scanId:[{t:2,r:"scanId"}],sessionId:[{t:2,r:"sessionId"}],cta:"done"}}]}]}],r:"scanStopped"}]}}),BoottimeScan:function(e){return t.extend({template:e,data:()=>({scanId:null,label:"Boottime Scan",installing:!1,installed:r.isInstalled("boottime"),scheduled:!1}),computed:{customBreadcrumbs:function(){return[{title:this.get("label")}]}},oninit(){this.installer=r.getInstaller("boottime"),$.getScan(this.get("scanId")).then((t=>{const e=t.getData();this.set("label",e.label),this.set("scheduled",e.boottimeScanScheduled),this.installer.getStatus().then((t=>{"installing"===t.task&&(this.set("installing",!0),this.setInstalledObserver()),this.screenReady()})).catch((()=>{this.screenReady()}))})).catch((()=>{this.screenError()})),this.on("scheduleScan",(()=>{n("app.scanViruses.ScheduleBoottimeScan",!0).then((()=>{this.set("scheduled",!0)}))})),this.on("unscheduleScan",(()=>{n("app.scanViruses.ScheduleBoottimeScan",!1).then((()=>{this.set("scheduled",!1)}))})),this.on("installScan",(()=>{this.set("installing",!0),this.installer.install().then(this.setInstalledObserver.bind(this)).catch((()=>{this.set("installing",!1)}))}))},onteardown(){this.installer.close()},setInstalledObserver(){this.installer.once("done",(t=>{"installed"===t&&this.set("installed",!0),this.set("installing",!1)}))}})}({v:3,t:[{t:7,e:"Page",a:{cssCls:"-center-header",heading:[{t:2,x:{r:["nls"],s:'_0("scans.scanType.boottime")'}}],backHash:"#Scans",settingsUrl:"#Settings/Scans/boottime"},f:[{t:7,e:"div",a:{slot:"breadcrumbs"},f:[{t:7,e:"Crumbs",a:{section:"security",moduleId:"scans",customBreadcrumbs:[{t:2,r:"customBreadcrumbs"}]}}]}," ",{t:7,e:"div",a:{slot:"page-content",class:"kin_page-content -center"},f:[{t:7,e:"p",a:{class:"kin_description__text scn_boot-time__desc"},f:[{t:3,x:{r:["nls"],s:'_0("scans.boottime.desc")'}}]}," ",{t:7,e:"div",a:{class:"scn_install"},f:[{t:4,f:[{t:7,e:"kin-icon",a:{name:"circle-ok",size:"32",class:"g-margin-bottom--10"}}," ",{t:7,e:"p",a:{class:"p"},f:[{t:3,x:{r:["nls"],s:'_0("scans.boottime.installed.info")'}}]}],n:50,r:"installed"},{t:4,n:51,f:[{t:4,n:50,x:{r:["installing"],s:"_0"},f:[{t:7,e:"Progress",a:{percentage:"unknown",cssCls:"-standalone"}}," ",{t:7,e:"p",a:{class:"p g-margin-top--15"},f:[{t:3,x:{r:["nls"],s:'_0("scans.boottime.installing.info")'}}]}]},{t:4,n:50,x:{r:["installing"],s:"!(_0)"},f:[" ",{t:7,e:"p",a:{class:"p"},f:[{t:3,x:{r:["nls"],s:'_0("scans.boottime.install.info")'}}]}," ",{t:7,e:"div",a:{class:"g-margin-top--10"},f:[{t:7,e:"button",a:{class:"a","data-test":"scn_boot-install"},v:{click:"installScan"},f:[{t:3,x:{r:["nls"],s:'_0("scans.boottime.install")'}}]}]}]}],r:"installed"}]}," ",{t:7,e:"div",a:{class:"scn_boot-time__cta"},f:[{t:4,f:[{t:7,e:"p",a:{class:"p -margins"},f:[{t:3,x:{r:["nls"],s:'_0("scans.boottime.scheduled.info")'}}]}," ",{t:7,e:"p",a:{class:"p -small -secondary"},f:[{t:7,e:"button",v:{click:"unscheduleScan"},a:{class:"a","data-test":"scn_boot-unschedule"},f:[{t:3,x:{r:["nls"],s:'_0("scans.boottime.unschedule")'}}]}]}],n:50,r:"scheduled"},{t:4,n:51,f:[{t:7,e:"Button",v:{domClick:"scheduleScan"},a:{cssCls:"-large",dataTest:"scnBootSchedule"},f:[{t:2,x:{r:["nls"],s:'_0("scans.boottime.schedule")'}}]}],r:"scheduled"}]}]}]}]}),ScanHistoryDetail:function(e){return t.extend({template:e,components:{},data:()=>({scanId:null,sessionId:null,scanData:null,scanTitle:null,loadingScan:!0,loadingThreats:!0}),oninit(){this.components.ThreatsList=$.getBrandedComponent("ThreatsList"),this.on("ThreatsList.data",(t=>{this.set("loadingThreats",t.loading)})),$.getScanHistoryDetail(this.get("scanId"),this.get("sessionId")).then((t=>{if(t){const e=t.label+" ("+v(t.startTimeMs).format("LLL")+")";this.set({scanTitle:e,scanData:t})}this.set("loadingScan",!1)}))}})}({v:3,t:[{t:7,e:"kin-view",a:{loading:[{t:2,x:{r:["loadingScan","loadingThreats"],s:"_0||_1"}}],actionbar:"true"},f:[{t:7,e:"div",a:{slot:"description"},f:[{t:7,e:"p",a:{class:"kin_description__text"},f:[{t:2,r:"scanTitle"}]}]}," ",{t:4,f:[{t:7,e:"ThreatsList",a:{scanId:[{t:2,r:"scanData.scanId"}],sessionId:[{t:2,r:"scanData.sessionId"}],showActions:"true",cta:"done"}}],n:50,r:"scanData"}]}]}),ScanHistoryRow:function(e){return t.extend({template:e,data:()=>({scan:null,isExpanded:!1,numbro:Jt}),computed:{hasIssue:function(){const t=this.get("scan")||{};if("object"!=typeof t.scanVerdict)return"virus"===t.scanVerdict;const e=t.scanVerdict.found_resolved,n=t.scanVerdict.found_unresolved,s=t.scanVerdict.found_resolved_with_error;return e||n||s},hasIssueScanError:function(){const t=this.get("scan")||{};return"object"!=typeof t.scanVerdict?"error"===t.scanVerdict:t.scanVerdict.found_scanned_with_error},hasIssueUnresolved:function(){const t=this.get("scan")||{};return"object"!=typeof t.scanVerdict?"virus"===t.scanVerdict:!0===t.scanVerdict.found_unresolved},hasIssueError:function(){const t=this.get("scan")||{};return"object"==typeof t.scanVerdict&&!0===t.scanVerdict.found_resolved_with_error}},oninit(){this.on("toggleExpansion",(()=>{this.toggle("isExpanded")})),this.on("runScanAgain",((t,e)=>{window.location.hash="Scans/scan/"+e}))}})}({v:3,t:[{t:4,f:[{t:7,e:"div",a:{role:"row",class:"kin_table__row scn_history__row","data-test":["table-row-",{t:2,r:"@index"}]},f:[{t:7,e:"div",a:{class:"kin_table__icon"},f:[{t:4,f:[{t:7,e:"kin-icon",a:{name:"icon-m-virus",size:"24"}}," ",{t:4,f:[{t:7,e:"kin-icon",a:{class:"scn_sub-icon",name:"badge-critical",size:"16"}}],n:50,x:{r:["hasIssueUnresolved","hasIssueError","hasIssueScanError","hasIssue"],s:"_0||_1||(_2&&!_3)"}},{t:4,n:51,f:[{t:7,e:"kin-icon",a:{class:"scn_sub-icon",name:"badge-ok",size:"16"}}],x:{r:["hasIssueUnresolved","hasIssueError","hasIssueScanError","hasIssue"],s:"_0||_1||(_2&&!_3)"}}],n:50,x:{r:["hasIssue","hasIssueScanError"],s:"_0||_1"}}]}," ",{t:7,e:"div",a:{class:"kin_table__name"},f:[{t:2,r:"label"}]}," ",{t:7,e:"div",f:[{t:2,x:{r:["moment","scan.startTimeMs"],s:'_0(_1).format("LLL")'}}]}," ",{t:7,e:"div",a:{class:"kin_table__actions"},f:[{t:4,f:[{t:7,e:"kin-tooltip",a:{class:"g-margin-right--10"},f:[{t:7,e:"div",a:{slot:"tooltip-activator"},f:[{t:7,e:"kin-icon",a:{name:"icon-m-action-info",size:"24"}}]}," ",{t:7,e:"div",a:{slot:"tooltip"},f:[{t:7,e:"p",a:{class:"p -small"},f:[{t:2,x:{r:["nls"],s:'_0("scans.scanHistory.unresolved.tooltip")'}}]}]}]}],n:50,r:"hasIssueError"}," ",{t:7,e:"kin-button",v:{click:"toggleExpansion"},a:{"data-test":"scn_history-row-details-button",type:"blank",size:"small",icononly:0,title:[{t:2,x:{r:["isExpanded","nls"],s:'_0?_1("global.clickToHide"):_1("global.clickToExpand")'}}]},f:[{t:7,e:"kin-icon",a:{name:[{t:2,x:{r:["isExpanded"],s:'_0?"icon-s-controls-arrow-up":"icon-s-controls-arrow-down"'}}],size:"16"}}]}]}]}," ",{t:4,f:[{t:7,e:"div",a:{role:"row",class:"kin_table__row -details scn_history__row","data-test":["table-row-details-",{t:2,r:"@index"}],"aria-rowindex":[{t:2,r:"@index"}]},f:[{t:4,f:[{t:7,e:"kin-button",v:{click:{n:"showThreats",d:[{t:2,r:"scan.scanId"},",",{t:2,r:"scan.sessionId"}]}},a:{type:"secondary",class:"scn_history__report","data-test":"scn_history-report-button"},f:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory.detailedReport")'}}]}],n:50,r:"hasIssue"}," ",{t:7,e:"div"}," ",{t:7,e:"div",f:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory.runTime")'}},":"]}," ",{t:7,e:"div",f:[{t:2,x:{r:["moment","scan.runTime"],s:'_0.duration(_1*1000,"milliseconds").humanize()'}}]}," ",{t:7,e:"div"}," ",{t:7,e:"div"}," ",{t:7,e:"div",f:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory.testedFiles")'}},":"]}," ",{t:7,e:"div",f:[{t:2,r:"scan.filesCount"}]}," ",{t:7,e:"div"}," ",{t:7,e:"div"}," ",{t:7,e:"div",f:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory.testedFolders")'}},":"]}," ",{t:7,e:"div",f:[{t:2,r:"scan.foldersCount"}]}," ",{t:7,e:"div"}," ",{t:7,e:"div"}," ",{t:7,e:"div",f:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory.testedBytes")'}},":"]}," ",{t:7,e:"div",f:[{t:2,x:{r:["numbro","scan.bytesCount"],s:'_0(_1).format("0.0 b")'}}]}," ",{t:7,e:"div"}," ",{t:7,e:"div"}," ",{t:7,e:"div",f:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory.infectedFiles")'}},":"]}," ",{t:7,e:"div",f:[{t:2,r:"scan.infectedCount"}]}," ",{t:7,e:"div"}]}],n:50,r:"isExpanded"}],n:53,r:"scan"}]})},Yt={v:3,t:[{t:4,f:[{t:8,x:{r:["getPage"],s:"_0()"}}," ",{t:4,f:[{t:8,x:{r:["getOverlay"],s:"_0()"}}],n:50,r:"overlay"}],n:50,r:"initialized"}]};var Qt=".scn_count {\n margin: 5px 5px 0 0;\n position: absolute;\n top: 3px;\n right: 3px;\n}\n";const te=t.extend({template:{v:3,t:[{t:7,e:"div",a:{class:"eightpack__2"},f:[" ",{t:7,e:"a",a:{href:[{t:2,r:"data.url"}],class:"cube -full -blank","data-test":["scn_scan-",{t:2,r:"data.scanType"},"-start"]},f:[{t:7,e:"Icon",a:{name:["scan-",{t:2,r:"data.scanType"}],cssCls:"cube__icon"}}," ",{t:4,f:[{t:7,e:"span",a:{class:"btn -secondary -running"},f:[{t:3,x:{r:["nls"],s:'_0("global.running")'}}]}],n:50,r:"running"},{t:4,n:51,f:[{t:7,e:"span",a:{class:"btn -secondary"},f:[{t:3,x:{r:["data.scanType","nls"],s:'_0==="boottime"?_1("scans.openNow"):_1("global.scanNow")'}}]}],r:"running"}," ",{t:7,e:"span",a:{class:"cube__label"},f:[{t:3,x:{r:["nls","data.scanType"],s:'_0("scans.scanType."+_1)'}}," ",{t:7,e:"span",a:{class:"cube__desc"},f:[{t:3,x:{r:["nls","data.scanType"],s:'_0("scans.scanType."+_1+".caption")'}}]}]}]}]}]},css:Qt,data:()=>({data:null,running:!1}),oninit(){this.observe("data",(t=>{t&&(this.removeListeners(),this.runningObserverOff=$.on("running."+t.scanId,(t=>{this.set("running",t)})),$.getRunningScanIds().then((e=>{this.set("running",e.includes(t.scanId))})))}))},removeListeners(){this.runningObserverOff&&this.runningObserverOff()},onteardown(){this.removeListeners()}}),ee=t.extend({template:{v:3,t:[{t:7,e:"div",a:{class:"eightpack__2"},f:[" ",{t:7,e:"a",a:{href:[{t:2,r:"data.url"}],class:"cube -full -blank","data-test":["scn_scan-",{t:2,r:"data.name"},"-start"]},f:[{t:7,e:"Icon",a:{name:["scan-",{t:2,r:"data.icon"}],cssCls:"cube__icon"}}," ",{t:4,f:[{t:7,e:"span",a:{class:"btn -secondary -running"},f:[{t:3,x:{r:["nls"],s:'_0("global.running")'}}]}],n:50,r:"running"},{t:4,n:51,f:[{t:7,e:"span",a:{class:"btn -secondary"},f:[{t:3,x:{r:["nls"],s:'_0("scans.openNow")'}}]}],r:"running"}," ",{t:7,e:"span",a:{class:"cube__label"},f:[{t:3,x:{r:["nls","data.name"],s:'_0("scans."+_1)'}}," ",{t:7,e:"span",a:{class:"cube__desc"},f:[{t:3,x:{r:["nls","data.name"],s:'_0("scans."+_1+".caption")'}}]}]}," ",{t:4,f:[{t:7,e:"span",a:{class:"badge -small cube__badge","data-test":"scn_custom-count"},f:[{t:2,r:"data.count"}]}],n:50,r:"data.count"}]}]}]},css:Qt,data:()=>({data:null,runningTypes:{}}),computed:{running:function(){const t=this.get("runningTypes");return Object.keys(t).some((e=>t[e]))}},oninit(){const t=this.get("data.scanTypes");this.runningObserverOffs=[],t.forEach((t=>{this.runningObserverOffs.push($.on("running."+t,(e=>{this.set("runningTypes."+t,e)})))})),$.getRunningScanTypes().then((e=>{const n={};t.forEach((t=>{n[t]=e.includes(t)})),this.set("runningTypes",n)}))},onteardown(){this.runningObserverOffs&&this.runningObserverOffs.length&&this.runningObserverOffs.forEach((t=>{t()}))}}),ne={full:0,folder:1,boottime:2,custom:3,quick:3},se=["custom","quick"],ae=t.extend({template:{v:3,t:[{t:7,e:"Page",a:{heading:[{t:3,x:{r:["nls"],s:'_0("scans")'}}],cssCls:"scn",settingsUrl:"#Settings/Scans",backHash:"#security"},f:[{t:7,e:"div",a:{slot:"breadcrumbs"},f:[{t:7,e:"Crumbs",a:{section:"security",moduleId:"scans",customBreadcrumbs:[{t:2,r:"customBreadcrumbs"}]}}]}," ",{t:7,e:"div",a:{slot:"page-content"},f:[{t:7,e:"kin-view",f:[{t:7,e:"div",a:{slot:"description"},f:[{t:7,e:"p",a:{class:"kin_description__text"},f:[{t:3,x:{r:["nls"],s:'_0("scans.module.desc")'}}]}]}," ",{t:7,e:"div",a:{slot:"cta"},f:[{t:4,f:[{t:7,e:"kin-button",a:{link:"#SmartScan",processing:"true","data-test":"smartScan_open",title:[{t:3,x:{r:["nls"],s:'_0("dashboard.smartScanShowProgress")'}}]},f:[{t:3,x:{r:["nls"],s:'_0("dashboard.smartScanRunning")'}}]}],n:50,r:"isSmartScanRunning"},{t:4,n:51,f:[{t:4,n:50,x:{r:["isSmartScanDone"],s:"_0"},f:[{t:7,e:"p",a:{class:"kin_cta__text p -small -secondary"},f:[{t:3,x:{r:["nls"],s:'_0("dashboard.smartScanFinished")'}}]}," ",{t:7,e:"kin-button",a:{link:"#SmartScan","data-test":"smartScan_open"},f:[{t:3,x:{r:["nls"],s:'_0("dashboard.smartScanShowResults")'}}]}]},{t:4,n:50,x:{r:["isSmartScanDone"],s:"!(_0)"},f:[" ",{t:7,e:"kin-button",a:{link:"#SmartScan",size:"large","data-test":"smartScan_open"},f:[{t:2,x:{r:["nls"],s:'_0("scans.startSmartScan")'}}]}]}],r:"isSmartScanRunning"}," ",{t:7,e:"div",a:{class:"kin_cta__links"},f:[{t:4,f:[{t:7,e:"a",a:{href:"#RescueDisk",class:"a -small -secondary","data-test":"avr_go-to-rescuedisk",title:[{t:3,x:{r:["nls"],s:'_0("rescuedisk")'}}]},f:[{t:7,e:"Icon",a:{name:"rescuedisk"}},{t:3,x:{r:["nls"],s:'_0("rescuedisk")'}}]}],n:50,r:"showRescueDisk"}," ",{t:7,e:"a",a:{href:"#Scans/scanHistory",class:"a -small -secondary","data-test":"avr_show-scan-history",title:[{t:3,x:{r:["nls"],s:'_0("antivirus.viewScanHistory")'}}]},f:[{t:7,e:"Icon",a:{name:"history"}},{t:3,x:{r:["nls"],s:'_0("antivirus.viewScanHistory")'}}]}]}]}," ",{t:7,e:"div",a:{slot:"view-content"},f:[{t:7,e:"h3",a:{class:"h3 g-margin-top--60 g-margin-bottom--20"},f:[{t:3,x:{r:["nls"],s:'_0("scans.otherScans")'}}]}," ",{t:7,e:"div",a:{class:"eightpack"},f:[{t:4,f:[{t:4,f:[{t:7,e:"ScanListTile",a:{data:[{t:2,r:"."}]}}],n:50,x:{r:[".","scanTypes"],s:"_0&&_1"}},{t:4,n:51,f:[{t:4,n:50,x:{r:["."],s:"_0"},f:[{t:7,e:"ScanTile",a:{data:[{t:2,r:"."}]}}]}],x:{r:[".","scanTypes"],s:"_0&&_1"}}],n:52,r:"scanTiles"}]}]}]}]}]}]},components:{ScanTile:te,ScanListTile:ee},data:()=>({scanTiles:[null,null,null,{name:"customScans",icon:"custom",scanTypes:se,url:"#Scans/customScans",count:0}],isSmartScanRunning:!1,isSmartScanDone:!1,customBreadcrumbs:[],showRescueDisk:!1}),oninit(){$.getScans().then((t=>{this.updateScans(t),this.screenReady()})).catch((()=>{this.screenError()})),this._scansOff=$.on("scans",this.updateScans.bind(this)),this._smartscanRunningOff=$.on("running.smartScan",(t=>this.set("isSmartScanRunning",t))),$.isSmartScanRunning().then((t=>this.set("isSmartScanRunning",t))),this.observe("isSmartScanRunning",(t=>{t||$.getSmartScanStatus().then((t=>{this.set("isSmartScanDone","scan_report"===t.statusPrimary)}))})),this.rescuediskChangeOff=s.on("product.change.feature.rescuedisk",this.updateRescueDiskVisibility.bind(this)),this.updateRescueDiskVisibility()},onteardown(){this._scansOff&&this._scansOff(),this._smartscanRunningOff&&this._smartscanRunningOff(),this.rescuediskChangeOff&&this.rescuediskChangeOff()},updateScans(t){this.set("scanTiles."+ne.custom+".count",0),t.forEach(this.setScanTile.bind(this))},setScanTile(t){const e=ne[t.type];let n,s="#Scans/";if(null!=e)if(se.includes(t.type))n=this.get("scanTiles."+e+".count")+1,this.set("scanTiles."+e+".count",n);else{switch(t.type){case"full":case"folder":s+="scan/"+t.id;break;case"boottime":s+="boottimeScan/"+t.id}this.set("scanTiles."+e,{scanId:t.id,scanType:t.type,schedule:t.schedule,boottimeScanScheduled:t.boottimeScanScheduled,url:s})}},updateRescueDiskVisibility(){let t=r.isInstalled("rescuedisk"),e=r.isLicensed("rescuedisk");null==t&&(t=!0),null==e&&(e=!0),this.set("showRescueDisk",t&&e||!t&&!e)}}),ie=t.extend({template:{v:3,t:[{t:4,f:[{t:7,e:"Scan",a:{scanId:[{t:2,r:"scanId"}],sessionId:[{t:2,r:"sessionId"}],path:[{t:2,r:"path"}],section:"security",moduleId:"scans"}}],n:50,r:"loaded"}]},components:{},data:()=>({scanId:null,sessionId:null,path:null,loaded:!1}),onrender(){this.components.Scan=$.getBrandedComponent("Scan"),this.set("loaded",!0)},oninit(){this.on("*.goBack",(()=>{window.location.hash="#Scans"}))}});function oe(t){return t&&Object.keys(t).length}function ce(t){const e=864e5,n=1e3*t.launchTime,s=t.days;let a,i,o;switch(t.type){case"Once":o=_("scans.schedule.once",v(n).format("MMMM Do YYYY"),v(n).format("H:mm"));break;case"Daily":if(s&&s.length)if(7===s.length)o=_("scans.schedule.daily",v.utc(n).format("H:mm"));else{const t=s.map((function(t){return v().isoWeekday(t-1).format("dd")}));o=_("scans.schedule.specificDays",t.join(", "),v.utc(n).format("H:mm"))}break;case"Weekly":a=parseInt(n/e),o=_("scans.schedule.weekly",v.weekdays()[a],v.utc(n).format("H:mm"));break;case"Monthly":i=parseInt(n/e)+1,o=_("scans.schedule.monthly",i+".",v.utc(n).format("H:mm"))}return o}const re=Object.freeze({__proto__:null,isScanScheduled:oe,getScanScheduledTimeString:ce}),le=t.extend({template:{v:3,t:[{t:7,e:"div",a:{role:"row",class:"kin_table__row scn_custom__row","data-test":["table-row-",{t:2,r:"@index"}],"aria-rowindex":[{t:2,r:"@index"}]},f:[{t:7,e:"div",a:{class:"kin_table__name","data-test":"scn_scan-custom-name"},f:[{t:2,r:"scan.label"}]}," ",{t:7,e:"div",a:{"data-test":"scn_scan-custom-launch"},f:[{t:2,r:"scheduledTime"}]}," ",{t:7,e:"div",a:{class:"kin_table__end"},f:[{t:7,e:"button",a:{class:["btn -small -terciary ",{t:2,x:{r:["running"],s:'_0?"-running":""'}}],"data-test":"scn_scan-custom-start"},v:{click:"startScan"},f:[{t:4,f:[{t:2,x:{r:["nls"],s:'_0("global.running")'}}],n:50,r:"running"},{t:4,n:51,f:[{t:2,x:{r:["nls","scan.showResult"],s:'_0(_1?"scans.seeResults":"global.scanNow")'}}],r:"running"}]}]}," ",{t:7,e:"div",a:{class:"kin_table__actions"},f:[{t:4,f:[{t:7,e:"kin-dropdown",f:[{t:7,e:"span",a:{slot:"dropdown-activator"},f:[{t:7,e:"kin-button",a:{icononly:0,type:"blank",size:"small",class:["more-options-tooltip-opener-",{t:2,r:"@index"}],title:[{t:2,x:{r:["nls"],s:'_0("global.moreOptions")'}}],"data-test":"kin_table-item-options"},f:[{t:7,e:"kin-icon",a:{name:"icon-s-controls-menu-more",size:"14"}}]}]}," ",{t:7,e:"div",f:[{t:4,f:[{t:7,e:"kin-dropdown-item",v:{click:"configureScan"},a:{"data-test":"scn_scan-custom-settings"},f:[{t:3,x:{r:["nls"],s:'_0("scans.scanSettings")'}}]}],n:50,x:{r:["scan.type"],s:'_0==="custom"||_0==="quick"'}}," ",{t:7,e:"kin-dropdown-item",v:{click:"deleteScan"},a:{"data-test":"scn_scan-custom-delete"},f:[{t:3,x:{r:["nls"],s:'_0("scans.deleteScan")'}}]}]}]}," ",{t:7,e:"Tooltip",a:{openerSelector:["more-options-tooltip-opener-",{t:2,r:"@index"}],position:"top",alignment:"center"},f:[{t:3,x:{r:["nls"],s:'_0("global.more")'}}]}],n:50,x:{r:["running"],s:"!_0"}}]}]}]},data:()=>({scan:null,running:!1}),computed:{scheduledTime:function(){const t=this.get("scan.schedule");return oe(t)?ce(t):""}},oninit(){this.on("startScan",(()=>{$.openScan(this.get("scan"))})),this.on("configureScan",(()=>{$.openScanSettings({scanId:this.get("scan.id"),scanType:this.get("scan.type")})})),this.on("scheduleScan",(()=>{$.openScanScheduleDialog({scanId:this.get("scan.id"),scanType:this.get("scan.type")})})),this.on("deleteScan",(()=>{const t=this.get("scan");"custom"===t.type||"quick"===t.type?$.deleteScan(t.id):$.unscheduleScan(t.id)})),this.runningObserverOff=$.on("running."+this.get("scan.id"),(t=>{this.set("running",t)})),$.getRunningScanIds().then((t=>{this.set("running",t.includes(this.get("scan.id")))}))},onteardown(){this.runningObserverOff&&this.runningObserverOff()}}),de=m.createLogger("scans.customScans"),ue=t.extend({template:{v:3,t:[{t:7,e:"Page",a:{heading:[{t:3,x:{r:["nls"],s:'_0("scans.customScans")'}}],cssCls:"scn",backHash:"#Scans"},f:[{t:7,e:"div",a:{slot:"breadcrumbs"},f:[{t:7,e:"Crumbs",a:{section:"security",moduleId:"scans"}}]}," ",{t:7,e:"div",a:{slot:"page-content"},f:[{t:7,e:"kin-view",a:{loading:[{t:2,r:"scansLoading"}]},f:[{t:7,e:"div",a:{slot:"description"},f:[{t:7,e:"p",a:{class:"kin_description__text"},f:[{t:3,x:{r:["nls"],s:'_0("scans.customScans.desc")'}}]}]}," ",{t:7,e:"div",a:{slot:"cta"},f:[{t:7,e:"kin-button",v:{click:"createScan"},a:{"data-test":"scn_scan-custom-new"},f:[{t:3,x:{r:["nls"],s:'_0("scans.customScans.create")'}}]}]}," ",{t:7,e:"div",a:{slot:"view-content"},f:[{t:7,e:"kin-table",a:{datalength:[{t:2,r:"scans.length"}]},f:[{t:7,e:"div",a:{slot:"table-header",role:"row",class:"scn_custom__row"},f:[{t:7,e:"div",a:{role:"columnheader"},f:[{t:3,x:{r:["nls"],s:'_0("scans.scanName")'}}]}," ",{t:7,e:"div",a:{role:"columnheader"},f:[{t:3,x:{r:["nls"],s:'_0("scans.scanLaunch")'}}]}," ",{t:7,e:"div"}," ",{t:7,e:"div"}]}," ",{t:4,f:[{t:7,e:"div",a:{slot:"table-body"},f:[{t:4,f:[{t:7,e:"ScanRow",a:{scan:[{t:2,r:"."}]}}],n:52,r:"scans"}]}],n:50,x:{r:["scans","scans.length"],s:"_0&&_1"}},{t:4,n:51,f:[{t:7,e:"div",a:{slot:"table-empty-icon",class:"svg -empty-table"}}," ",{t:7,e:"div",a:{slot:"table-empty"},f:[{t:3,x:{r:["nls"],s:'_0("scans.customScans.noScans")'}}]}],x:{r:["scans","scans.length"],s:"_0&&_1"}}]}]}]}]}]}]},components:{ScanRow:le},data:()=>({scansLoading:!0,scans:[]}),oninit(){de.debug("oninit"),this.runScans={},this.initialize(),this.listeners=[$.on("scans",this.updateScans.bind(this))],this.listeners.push($.on("scanStarted",(t=>{this.runScans[t]=!0,this.get("scans").find(((e,n)=>{e.id===t&&this.set("scans["+n+"].showResult",!0)}))}))),this.on("configureScan",(()=>{$.openScanSettings({scanId:this.get("scan.id"),scanType:this.get("scan.type")})})),this.on("scheduleScan",(()=>{$.openScanScheduleDialog({scanId:this.get("scan.id"),scanType:this.get("scan.type")})})),this.on("deleteScan",(()=>{$.deleteScan(this.get("scan.id"))})),this.on("createScan",(()=>{window.location.hash="Scans/customScans/new/settings"}))},onteardown(){this.listeners.forEach((t=>{t()}))},initialize(){de.debug("initialize"),Promise.all([$.getScans(),$.getRunScans()]).then((t=>{function e(){this.updateScans(t[0]),this.set("scansLoading",!1)}de.debug("scans",t[0]),de.debug("run scans",t[1]),this.runScans=t[1],t[0].find((function(t){return"SmartScan"===t.job}))?n("app.smartScan.GetStatus").then((n=>{"scan_report"===n.statusPrimary&&t[0].forEach((t=>{"SmartScan"===t.job&&(this.runScans[t.id]=!0)})),e.call(this)})):e.call(this)})).catch((t=>{de.error("Scans: loading custom scans failed",t)}))},updateScans(t){de.debug("updating scans",t),this.merge("scans",t.filter((t=>{if("custom"===t.type||"quick"===t.type||oe(t.schedule))return t.showResult=this.runScans[t.id]&&!$.isScanStoredAsDone(t.id),!0})),{compare:"id"})}}),he={title:"scans",desc:"scans.settings.desc",scans:{full:"scans.scanType.full",folder:"scans.scanType.folder",explorer:"scans.scanType.explorer",boottime:"scans.scanType.boottime"},sensitivity:"global.sensitivity",scanPup:"settings.pup",scanPupDesc:"settings.pup.desc",scanTools:"settings.pup.tools",scanToolsDesc:"settings.pup.tools.desc",scanLinks:"scans.settings.scanLinks",scanFullFiles:"scans.settings.scanFullFiles",priority:{label:"scans.settings.priority",high:"scans.settings.priority.high",medium:"scans.settings.priority.medium",low:"scans.settings.priority.low"},scanPackers:{label:"scans.settings.scanPackers.label",mostCommonTypes:"scans.settings.scanPackers.mostCommonTypes",mostCommonTypesDesc:"scans.settings.scanPackers.mostCommonTypes.desc",allTypes:"scans.settings.scanPackers.allTypes",allTypesDesc:"scans.settings.scanPackers.allTypes.desc",dontScanArchives:"scans.settings.scanPackers.dontScanArchives",dontScanArchivesDesc:"scans.settings.scanPackers.dontScanArchives.desc"},unpackArchives:"scans.settings.unpackArchives",scanAreas:{label:"scans.settings.scanAreas",allHardDisks:"scans.settings.scanAreas.allHardDisks",systemDisk:"scans.settings.scanAreas.systemDisk",allRemovableMedia:"scans.settings.scanAreas.allRemovableMedia",rootkits:"scans.settings.scanAreas.rootkits",uefi:"scans.settings.scanAreas.uefi",cdDvd:"scans.settings.scanAreas.cdDvd",memory:"scans.settings.scanAreas.memory",startup:"scans.settings.scanAreas.startup"},useAutomaticActions:"scans.settings.useAutomaticActions",actions:{fix:"scans.settings.actions.fix",fixDesc:"scans.settings.actions.fix.desc",chest:"scans.settings.actions.chest",delete:"scans.settings.actions.delete"},shutDownAfterScan:"scans.settings.shutDownAfterScan",generateReport:"scans.settings.generateReport",generateReportDesc:"scans.settings.generateReport.desc",scanTypes:{label:"scans.settings.scanTypes",content:"scans.settings.scanTypes.content",contentDesc:"scans.settings.scanTypes.content.desc",extensions:"scans.settings.scanTypes.extensions",extensionsDesc:"scans.settings.scanTypes.extensions.desc",allFiles:"scans.settings.scanTypes.allFiles"},viewExceptions:"scans.settings.viewExceptions"},pe=m.createLogger("scans.settings.scan"),me=null==localStorage.newPup?d.isVersionSupported("21.1"):1==localStorage.newPup;function fe(t){const e={sensitivity:{id:"stg-scans-"+t+"-sensitivity",desc:_(he.sensitivity),options:[{value:"40",label:_("settings.sensitivity.low")},{value:"80",label:_("settings.sensitivity.medium")},{value:"100",label:_("settings.sensitivity.high")}],track:{subject:"Sensitivity",valueMap:{40:"Low",80:"Medium",100:"High"}},search:he.sensitivity},scanPup:{id:"stg-scans-"+t+"-scanPup",label:_(he.scanPup),desc:_(he.scanPupDesc),track:{subject:"Scan PUP"},search:{title:he.scanPup,desc:he.scanPupDesc}},scanLinks:{id:"stg-scans-"+t+"-scanLinks",label:_(he.scanLinks),track:{subject:"Scan links"},search:he.scanLinks},scanFullFiles:{id:"stg-scans-"+t+"-scanFullFiles",label:_(he.scanFullFiles),track:{subject:"Scan whole files"},search:he.scanFullFiles},priority:{id:"stg-scans-"+t+"-priority",label:_(he.priority.label),options:[{label:_(he.priority.high),value:"2"},{label:_(he.priority.medium),value:"1"},{label:_(he.priority.low),value:"0"}],track:{subject:"Priority",valueMap:{2:"High",1:"Medium",0:"Low"}},search:he.priority.label},scanPackers:{id:"stg-scans-"+t+"-scanPackers",label:_(he.scanPackers.label),options:[{label:_(he.scanPackers.mostCommonTypes),desc:_(he.scanPackers.mostCommonTypesDesc),value:"EXE;WinExec;Drop;Install;Streams",recommended:t!==T.FOLDER&&t!==T.EXPLORER},{label:_(he.scanPackers.allTypes),desc:_(he.scanPackers.allTypesDesc),value:"All",recommended:t===T.FOLDER||t===T.EXPLORER},{label:_(he.scanPackers.dontScanArchives),desc:_(he.scanPackers.dontScanArchivesDesc),value:""}],track:{subject:"Scan packers and archives",valueMap:{"EXE;WinExec;Drop;Install;Streams":"Most common types","":"Do not scan archives"}},search:{title:he.scanPackers.label,others:[he.scanPackers.mostCommonTypes,he.scanPackers.mostCommonTypesDesc,he.scanPackers.allTypes,he.scanPackers.allTypesDesc,he.scanPackers.dontScanArchives,he.scanPackers.dontScanArchivesDesc]}},scanTypes:{id:"stg-scans-"+t+"-scanTypes",label:_(he.scanTypes.label),options:[{label:_(he.scanTypes.content),desc:_(he.scanTypes.contentDesc),value:"Content",recommended:t!==T.FOLDER&&t!==T.EXPLORER},{label:_(he.scanTypes.extensions),desc:_(he.scanTypes.extensionsDesc),value:"Extensions"},{label:_(he.scanTypes.allFiles),value:"AllFiles",recommended:t===T.FOLDER||t===T.EXPLORER}],track:{subject:"Scan types"},search:{title:he.scanTypes.label,others:[he.scanTypes.content,he.scanTypes.contentDesc,he.scanTypes.extensions,he.scanTypes.extensionsDesc,he.scanTypes.allFiles]}},useAutomaticActions:{id:"stg-scans-"+t+"-useAutomaticActions",label:_(he.useAutomaticActions),track:{subject:"Use automatic actions"},search:{title:he.useAutomaticActions,others:[he.actions.fix,he.actions.fixDesc,he.actions.chest,he.actions.delete]}},automaticActions:{id:"stg-scans-"+t+"-automaticActions",options:[{label:_(he.actions.fix),desc:_(he.actions.fixDesc),value:"fix",recommended:!0},{label:_(he.actions.chest),value:"trezor"},{label:_(he.actions.delete),value:"delete"}],track:{subject:"Automatic actions"}},shutdown:{id:"stg-scans-"+t+"-shutDownAfterScan",label:_(he.shutDownAfterScan),track:{subject:"Shutdown after scan"},search:he.shutDownAfterScan},generateReport:{id:"stg-scans-"+t+"-generateReport",label:_(he.generateReport),descAsPromise:()=>i.importModule("Settings","common").then((t=>t.getReportDestination())).then((t=>_(he.generateReportDesc,t,"NAPI.request('app.utils.BrowseFolder', '"+t.replace(/\\/g,"\\\\")+"')"))),track:{subject:"Generate report file"},search:{title:he.generateReport,desc:he.generateReportDesc}}};return me&&Object.assign(e,{scanTools:{id:"stg-scans-"+t+"-scanTools",label:_(he.scanTools),desc:_(he.scanToolsDesc),track:{subject:"Scan Tools"},search:{title:he.scanTools,desc:he.scanToolsDesc}}}),t===T.FULL&&Object.assign(e,{scanAreas:{id:t+"Scan_scanAreas",label:_(he.scanAreas.label),options:[{label:_(he.scanAreas.allHardDisks),value:"AllHarddisks",recommended:!0},{label:_(he.scanAreas.systemDisk),value:"SystemDisk"}],track:{subject:"Scan areas"},search:{title:he.scanAreas.label,others:[he.scanAreas.allHardDisks,he.scanAreas.systemDisk,he.scanAreas.allRemovableMedia,he.scanAreas.rootkits,he.scanAreas.uefi,he.scanAreas.cdDvd,he.scanAreas.memory]}},scanAllRemovableMedia:{id:t+"Scan_scanAllRemovableMedia",label:_(he.scanAreas.allRemovableMedia),track:{subject:"Scan all removable media"}},scanRootkits:{id:t+"Scan_scanRootkits",label:_(he.scanAreas.rootkits),track:{subject:"Scan rootkits"}},scanUEFI:{id:t+"Scan_scanUEFI",label:_(he.scanAreas.uefi),track:{subject:"Scan UEFI"}},scanCdDvd:{id:t+"Scan_scanCdDvd",label:_(he.scanAreas.cdDvd),track:{subject:"Scan CD/DVD"}},scanMemory:{id:t+"Scan_scanMemory",label:_(he.scanAreas.memory),track:{subject:"Scan quick memory"}}}),t!==T.FOLDER&&Object.assign(e,{viewExceptions:{id:"settings-scans-"+t+"-viewExceptions",label:_(he.viewExceptions),testAttr:"openGlobalExceptions",search:he.viewExceptions}}),e}const ge=t.extend({template:{v:3,t:[{t:4,f:[{t:7,e:"div",a:{class:"g-margin-bottom--20"},f:[{t:7,e:"SettingsRange",a:{property:[{t:2,r:"properties.sensitivity"}]}}]}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanPup"}]},f:[{t:4,f:[{t:7,e:"div",a:{class:"settings__indent"},f:[{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanTools"}]},f:[]}]}],n:50,r:"scanToolsSupported"}]}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanLinks"}]}}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanFullFiles"}]}}," ",{t:7,e:"div",a:{class:"g-margin-top--20"},f:[{t:7,e:"SettingsSelect",a:{property:[{t:2,r:"properties.priority"}],labelSmall:0}}]}," ",{t:4,f:[{t:7,e:"div",a:{class:"g-margin-top--20",id:[{t:2,r:"properties.scanAreas.id"},"__container"]},f:[{t:7,e:"SettingsRadio",a:{property:[{t:2,r:"properties.scanAreas"}]}}," ",{t:7,e:"div",a:{class:"g-margin-top--20"},f:[{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanAllRemovableMedia"}]}}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanRootkits"}]}}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanUEFI"}]}}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanCdDvd"}]}}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanMemory"}]}}]}]}],n:50,x:{r:["scanType","SCAN_TYPE.FULL"],s:"_0===_1"}}," ",{t:7,e:"div",a:{class:"g-margin-top--20"},f:[{t:7,e:"SettingsRadio",a:{property:[{t:2,r:"properties.scanPackers"}]}}]}," ",{t:7,e:"div",a:{class:"g-margin-top--20"},f:[{t:7,e:"SettingsRadio",a:{property:[{t:2,r:"properties.scanTypes"}]}}]}," ",{t:7,e:"div",a:{class:"g-margin-top--20"},f:[{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.useAutomaticActions"}]},f:[{t:7,e:"div",a:{class:"settings__indent"},f:[{t:7,e:"SettingsRadio",a:{property:[{t:2,r:"properties.automaticActions"}]}}]}]}]}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.shutdown"}]}}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.generateReport"}]}}," ",{t:4,f:[{t:7,e:"button",a:{class:"a -small -secondary",id:[{t:2,r:"properties.viewExceptions.id"}],"data-test":[{t:2,r:"properties.viewExceptions.testAttr"}]},v:{click:"openGlobalExceptions"},f:[{t:2,r:"properties.viewExceptions.label"}]}],n:50,r:"properties.viewExceptions"}],n:50,x:{r:["loading"],s:"!_0"}}]},data:()=>({SCAN_TYPE:T,scanId:null,scanType:null,loading:!0,properties:null,dontSave:null,propertiesToSave:{},scanToolsSupported:me}),oninit(){this.observe("properties.scanPup.value",(t=>{this.set("properties.scanTools.disabled",!t)})),this.observe("properties.useAutomaticActions.value",(t=>{this.set("properties.automaticActions.disabled",!t)}),{init:!1}),this.on("openGlobalExceptions",(()=>{location.hash="Settings/exceptions"})),$.getScan(this.get("scanId")).then((t=>{this.scan=t,this.get("scanType")||this.set("scanType",t.getData().type),this.setProperties(),this.set("loading",!1)})).catch((t=>{pe.error("getting scan failed",t)}))},setProperties(){const t=this.get("scanId"),e=this.get("scanType"),n=fe(e),s={sensitivity:{load:this.loadScanProp.bind(this,"TaskSensitivity"),change:this.changeScanProp.bind(this,"TaskSensitivity")},scanPup:{load:()=>this.loadScanProp("ScanPUP").then((t=>({locked:t.locked,value:t.value>0}))),change:t=>this.changeScanProp("ScanPUP",t?1:0),changeEvent:"scan."+t+".scanPup"},scanLinks:{load:this.loadScanProp.bind(this,"ScanLinks"),change:this.changeScanProp.bind(this,"ScanLinks")},scanFullFiles:{load:this.loadScanProp.bind(this,"ScanFullFiles"),change:this.changeScanProp.bind(this,"ScanFullFiles")},priority:{load:this.loadScanProp.bind(this,"Priority"),change:this.changeScanProp.bind(this,"Priority")},scanPackers:{load:this.getScanPackers.bind(this),change:this.changeScanProp.bind(this,"ScanPackers"),testAttr:this.scan.getPropTestAttr("ScanPackers")},scanTypes:{load:this.getScanTypes.bind(this),change:this.changeScanTypes.bind(this),testAttr:[this.scan.getPropTestAttr("ScanTypes"),this.scan.getPropTestAttr("ScanType")]},useAutomaticActions:{load:this.loadScanProp.bind(this,"AutomaticallyApplyActionsDuringScan"),change:this.changeScanProp.bind(this,"AutomaticallyApplyActionsDuringScan")},automaticActions:{load:this.loadScanProp.bind(this,"VirusAction"),change:this.changeAutomaticActions.bind(this),testAttr:[this.scan.getPropTestAttr("VirusAction"),this.scan.getPropTestAttr("SuspiciousAction"),this.scan.getPropTestAttr("PUPAction")]},shutdown:{load:this.loadScanProp.bind(this,"ShutDownMachine"),change:this.changeScanProp.bind(this,"ShutDownMachine")},generateReport:{load:this.loadGenerateReport.bind(this),change:this.changeGenerateReport.bind(this),testAttr:this.scan.getPropTestAttr("Report")}};me&&Object.assign(s,{scanTools:{load:()=>{const t=this.get("propertiesToSave.ScanPUP");let e;return e=this.get("dontSave")&&void 0!==t?Promise.resolve({locked:s.scanPup.locked,value:t}):this.loadScanProp("ScanPUP"),e.then((t=>({locked:t.locked,value:2==t.value})))},change:t=>this.changeScanProp("ScanPUP",t?2:1),updateOnEvent:"settings.change.scan."+t+".scanPup"}}),e===T.FULL&&Object.assign(s,{scanAreas:{load:this.getScanAreaForRadio.bind(this,["AllHarddisks","SystemDisk"]),change:this.changeScanArea.bind(this,["AllHarddisks","SystemDisk"]),testAttr:[this.scan.getPropTestAttr("ScanAreas","AllHarddisks"),this.scan.getPropTestAttr("ScanAreas","SystemDisk")]},scanAllRemovableMedia:{load:this.getScanArea.bind(this,["AllMedia"]),change:this.changeScanArea.bind(this,["AllMedia"]),testAttr:this.scan.getPropTestAttr("ScanAreas","AllMedia")},scanRootkits:{load:this.getScanArea.bind(this,["*RTK-FULL"]),change:this.changeScanArea.bind(this,["*RTK-FULL"]),testAttr:this.scan.getPropTestAttr("ScanAreas","*RTK-FULL")},scanUEFI:{load:this.getScanArea.bind(this,["*RTK-UEFI"]),change:this.changeScanArea.bind(this,["*RTK-UEFI"]),testAttr:this.scan.getPropTestAttr("ScanAreas","*RTK-UEFI")},scanCdDvd:{load:this.getScanArea.bind(this,["MediaCDDVD"]),change:this.changeScanArea.bind(this,["MediaCDDVD"]),testAttr:this.scan.getPropTestAttr("ScanAreas","MediaCDDVD")},scanMemory:{load:this.getScanArea.bind(this,["QuickStartupMem"]),change:this.changeScanArea.bind(this,["QuickStartupMem"]),testAttr:this.scan.getPropTestAttr("ScanAreas","QuickStartupMem")}}),Object.keys(n).forEach((t=>{s[t]=s[t]||{},Object.assign(s[t],n[t])})),this.set("properties",s)},getScanPackers(){const t="ScanPackers";return this.scan.loadProp(t).then((e=>(["","All"].includes(e.value)||(e.value="EXE;WinExec;Drop;Install;Streams"),this.handleNewScanCreation(t,e.value),e)))},getScanAreas(t){const e="ScanAreas";return this.getScanAreasPromise&&!t||(this.getScanAreasPromise=this.scan.loadProp(e).then((t=>(this.scanAreas={locked:t.locked,areas:{}},t.value.replace(/"/g,"").split(";").forEach((t=>{this.scanAreas.areas[t]=!0})),delete this.getScanAreasPromise,this.handleNewScanCreation(e,t.value),this.scanAreas)))),this.getScanAreasPromise},changeScanAreas(){const t=Object.keys(this.scanAreas.areas).map((t=>'"'+t+'"')).join(";");return this.changeScanProp("ScanAreas",t)},getScanAreaForRadio(t,e){return this.getScanAreas(e).then((e=>({locked:e.locked,value:t.find((t=>e.areas[t]))})))},getScanArea(t,e){return this.getScanAreas(e).then((e=>({locked:e.locked,value:t.every((t=>e.areas[t]))})))},changeScanArea(t,e){return t.forEach((t=>{t===e||!0===e?this.scanAreas.areas[t]=!0:delete this.scanAreas.areas[t]})),this.changeScanAreas()},getScanTypes(){return Promise.all([this.loadScanProp("ScanTypes"),this.loadScanProp("ScanType")]).then((t=>{const e=t[0]||{},n=t[1]||{};let s="";return s="AllFiles"===e.value?e.value:n.value,{value:s,locked:e.locked||n.locked}}))},changeScanTypes(t){let e="",n="";return"AllFiles"===t?e=t:(n=t,"Extensions"===t&&(e="exe;bat;com")),Promise.all([this.changeScanProp("ScanTypes",e),this.changeScanProp("ScanType",n)])},changeAutomaticActions(t){return Promise.all([this.changeScanProp("VirusAction",t),this.changeScanProp("SuspiciousAction",t),this.changeScanProp("PUPAction",t)])},loadGenerateReport(){const t="Report";return this.scan.loadProp(t).then((e=>(this.handleNewScanCreation(t,e.value),{locked:e.locked,value:"None"!==e.value})))},changeGenerateReport(t){return this.changeScanProp("Report",t?"TXT":"None")},loadScanProp(t){return this.scan.loadProp(t).then((e=>(this.handleNewScanCreation(t,e.value),e)))},changeScanProp(t,e){return this.get("dontSave")?(this.set("propertiesToSave."+t,e),this.fire("scanPropertyToSave",t,e),Promise.resolve()):this.scan.saveProp(t,e)},handleNewScanCreation(t,e){this.get("isNewScan")&&this.fire("scanPropertyToSave",t,e)}}),be=m.createLogger("scans.customScanSettings"),we=/"/g,_e=["SystemDisk","*RTK-SUPERQUICK","QuickStartup"],ve=t.extend({template:{v:3,t:[{t:7,e:"Overlay",a:{cssCls:"-page -overlay",title:[{t:2,x:{r:["nls"],s:'_0("global.close")'}}],txt:["{close:'",{t:2,x:{r:["nls"],s:'_0("global.close")'}},"'}"]},f:[{t:7,e:"kin-view",a:{loading:[{t:2,r:"loading"}],actionbar:"true",csscls:"-actions"},f:[{t:7,e:"div",a:{slot:"view-content"},f:[{t:4,f:[{t:7,e:"SettingsTextInput",a:{property:[{t:2,r:"label"}],labelSmall:0,placeholderText:[{t:2,x:{r:["nls"],s:'_0("scans.scanName.placeholder")'}}]}}," ",{t:7,e:"p",a:{class:"g-margin-top--10 g-margin-bottom--10"},f:[{t:3,x:{r:["nls"],s:'_0("scans.settings.customizeYourScan.title")'}}]}," ",{t:7,e:"div",a:{class:"scn_settings_schedule_flex"},f:[{t:4,f:[{t:7,e:"p",a:{class:"p -secondary -small g-margin-bottom--5"},f:[{t:2,x:{r:["nls"],s:'_0("scans.scanType")'}}]}," ",{t:7,e:"p",a:{class:" g-margin-bottom--5"},f:[{t:2,x:{r:["nls","scanType.storedValue"],s:'_0("scans.scanType."+_1)'}}]}],n:50,x:{r:["isNewScan","scanType.storedValue"],s:"!_0&&_1"}},{t:4,n:51,f:[{t:7,e:"SettingsSelect",a:{property:[{t:2,r:"scanType"}],labelSmall:0,wrapCssCls:"scn_settings_schedule_inputInRow"}}],x:{r:["isNewScan","scanType.storedValue"],s:"!_0&&_1"}}," ",{t:7,e:"SettingsSelect",a:{property:[{t:2,r:"schedule.frequency"}],labelSmall:0,wrapCssCls:"scn_settings_schedule_inputInRow"}}," ",{t:4,f:[{t:4,f:[{t:7,e:"SettingsTextInput",a:{property:[{t:2,r:"schedule.date"}],labelSmall:0,wrapCssCls:"scn_settings_schedule_inputInRow"}}],n:50,x:{r:["schedule.frequency.storedValue"],s:'_0==="Once"'}}," ",{t:4,f:[{t:7,e:"SettingsSelect",a:{property:[{t:2,r:"schedule.dayOfWeek"}],labelSmall:0,wrapCssCls:"scn_settings_schedule_inputInRow"}}],n:50,x:{r:["schedule.frequency.storedValue"],s:'_0==="Weekly"'}}," ",{t:4,f:[{t:7,e:"SettingsTextInput",a:{property:[{t:2,r:"schedule.dayOfMonth"}],labelSmall:0,wrapCssCls:"scn_settings_schedule_inputInRow"}}],n:50,x:{r:["schedule.frequency.storedValue"],s:'_0==="Monthly"'}}," ",{t:7,e:"SettingsTextInput",a:{property:[{t:2,r:"schedule.time"}],labelSmall:0,wrapCssCls:"scn_settings_schedule_inputInRow"}}],n:50,x:{r:["schedule.frequency.storedValue","schedule.frequency.disabled"],s:"_0&&!_1"}}]}," ",{t:4,f:[{t:7,e:"div",a:{class:"g-margin-top--10"},f:[{t:7,e:"button",a:{class:"btn","data-test":"scn_scan-custom-add-folders",id:"scn_scan-custom-add-folders"},v:{click:"addFolders"},f:[{t:3,x:{r:["nls"],s:'_0("global.chooseFolder")'}}]}]}," ",{t:4,f:[{t:7,e:"table",a:{class:"table -small -fixed g-margin-top--10"},f:[{t:7,e:"colgroup",f:[{t:7,e:"col",a:{width:"90%"}}," ",{t:7,e:"col",a:{width:"10%"}}]}," ",{t:4,f:[{t:7,e:"tr",f:[{t:7,e:"td",f:[{t:7,e:"p",a:{id:["app-path-tooltip-opener-",{t:2,r:"index"}],class:"p -small -secondary g-ellipsis"},f:[{t:2,r:"."}]}," ",{t:7,e:"Tooltip",a:{showOnEllipsis:"true",cssCls:"-link",position:"bottom",alignment:"left"},f:[{t:2,r:"."}]}]}," ",{t:7,e:"td",a:{class:"table__delete"},f:[{t:7,e:"div",f:[{t:7,e:"button",a:{class:"a","data-test":"scans_custom-scan-settings-folder-remove"},v:{click:{n:"removeFolder",d:[{t:2,r:"index"}]}},f:[{t:7,e:"Icon",a:{name:"trash"}}]}," ",{t:7,e:"Tooltip",a:{position:"top",alignment:"center"},f:[{t:3,x:{r:["nls"],s:'_0("global.remove")'}}]}]}]}]}],n:52,i:"index",r:"folders"}]}],n:50,r:"folders.length"},{t:4,n:51,f:[{t:7,e:"p",a:{class:["g-margin-top--10 g-margin-bottom--20 p -small ",{t:2,x:{r:["isFolderError"],s:'_0?"color-critical -text":"-secondary"'}}]},f:[{t:2,x:{r:["nls"],s:'_0("global.noFolderAdded")'}}]}],r:"folders.length"}],n:50,x:{r:["scanType.storedValue"],s:'_0==="folder"'}}," ",{t:4,f:[{t:7,e:"div",a:{class:"scn_settings_info_flex"},f:[{t:7,e:"kin-icon",a:{name:"icon-m-action-info",size:"24"}},{t:7,e:"p",a:{class:"p -small g-margin-left--5"},f:[{t:3,x:{r:["nls"],s:'_0("scans.settings.info")'}}]}]}],n:50,x:{r:["schedule.frequency.storedValue","schedule.frequency.disabled"],s:"_0&&!_1"}}," ",{t:4,f:[{t:7,e:"p",a:{class:"g-margin-top--20 g-margin-bottom--10"},f:[{t:3,x:{r:["nls"],s:'_0("settings.advanced")'}}," ",{t:4,f:[{t:7,e:"kin-loading",a:{size:"small",inline:"true"}}],n:50,r:"advancedSettingsLoading"}]}," ",{t:4,f:[{t:7,e:"ScanSettings",a:{scanId:[{t:2,r:"advancedSettingsScanId"}],scanType:[{t:2,r:"scanType.storedValue"}],isNewScan:[{t:2,r:"isNewScan"}],dontSave:"true"}}],n:50,x:{r:["advancedSettingsScanId","advancedSettingsLoading"],s:"_0&&!_1"}}],n:50,x:{r:["scanType.value"],s:'_0!=="smartscan"'}}],n:50,x:{r:["loading"],s:"!_0"}}]}," ",{t:7,e:"div",a:{slot:"view-actions"},f:[{t:7,e:"div",f:[{t:7,e:"kin-button",a:{"kin-disabled":[{t:2,r:"savingInProgress"}],processing:[{t:2,r:"savingInProgress"}],"data-test":"scans_custom_save"},v:{click:"save"},f:[{t:2,x:{r:["nls"],s:'_0("global.save")'}}]}," ",{t:7,e:"kin-button",a:{type:"secondary","data-test":"scans_custom_cancel"},v:{click:"cancel"},f:[{t:2,x:{r:["nls"],s:'_0("global.cancel")'}}]}]}]}]}]}]},components:{ScanSettings:ge},data:()=>({scanId:null,loading:!0,advancedSettingsLoading:!0,scan:null,isCustomScan:!0,isNewScan:!1,isFolderError:!1,folders:[],label:null,scanType:null,schedule:null,savingInProgress:!1,advancedSettingsScanId:null,regionalSettings:null}),onconstruct(){this._componentsPromise=i.importModule("Settings","ractiveComponents").then((t=>{for(const e in t)this.components[e]=t[e]}))},oninit(){this._propsToSave={},this._scheduleChanged=!1,this.observe("scanId",(t=>{"new"===t?(this.set("label.disabled",!1),this.set("scanType.disabled",!1)):$.isCustomScan(t).then((t=>{this.set("label.disabled",!t),this.set("scanType.disabled",!t)}))})),this.observe("scanType.value",(t=>{t!==this.get("scanType.storedValue")&&this.set("advancedSettingsLoading",!0)})),this.observe("scanType.storedValue",((t,e)=>{null!=t&&this.set("advancedSettingsLoading",!1),t!==T.FOLDER||this._isNewScan||e||this.getScanAreas(!0).then((t=>{this.set("folders",t)}))})),this.on("addFolders",this.addFolders.bind(this)),this.on("removeFolder",(t=>{this.removeFolder(t.context)})),this.on("cancel",(t=>{this.fire("close")})),this.on("ScanSettings.scanPropertyToSave",((t,e)=>{this.addPropToSave(t,e)})),this.on("save",(t=>{if(!this.isLabelValid())return;if(!this.isFolderValid())return;this.set("savingInProgress",!0);const e=[];for(const n in this._propsToSave)e.push({name:n,value:this._propsToSave[n]});e.length?this._isNewScan?this.createNewScan(e):this.saveScan(this.scan,e):this.fire("close")}));let t=this.get("scanId");"new"===t?(this.set("advancedSettingsScanId",S),t=S,this._isNewScan=!0,this.set("isNewScan",this._isNewScan)):this.set("advancedSettingsScanId",t);const e=n("app.utils.GetRegionalSettings").catch((t=>(console.debug("Regional settings not found",t),null)));Promise.all([$.getScan(t),this._componentsPromise,e]).then((([t,,e])=>{this.scan=t,this.set("regionalSettings",e),this.setProperties(),this.set("loading",!1),this._isNewScan&&this.focusLabelInput()})).catch((t=>{be.error("loading scan failed",t)}))},createNewScan(t){this.set("loading",!0),$.createScan().then((e=>{$.getScan(e).then((e=>{this.saveScan(e,t)}))}))},focusLabelInput(){const t=this.get("label");0===t.value.length&&(this._scanNameInput||(this._scanNameInput=this.find("#"+t.id)),this._scanNameInput.focus())},focusAddFolderButton(){const t=this.find("#scn_scan-custom-add-folders");t&&t.focus()},isLabelValid(){const t=this.get("label.value").length;return t||this.focusLabelInput(),t},isFolderValid(){const t=this.get("scanType.storedValue"),e=this.get("folders"),n=t===T.FOLDER&&(!e||"Interactive"===e||Array.isArray(e)&&e.length<1);return this.set("isFolderError",n),n&&this.focusAddFolderButton(),!n},saveScan(t,e){if(t.getId()===S)return console.error("Cannot save default scan as custom",S),void this.fire("close");t.saveProps(e).then((()=>{this._scheduleChanged?this.getScheduleTiming(!0).then(this.saveScheduleTiming.bind(this)).then((()=>n("app.scanViruses.ReloadScheduler"))).then((()=>{this.fire("close")})):this.fire("close")})).catch((t=>{console.error("Failed to save Custom scan settings",t),this.fire("close")}))},addPropToSave(t,e){this._propsToSave[t]=e},removePropsToSave(t){for(const e of t)delete this._propsToSave[e]},setProperties(){const t=[{label:_("scans.scanType.full"),value:T.FULL},{label:_("scans.scanType.folder"),value:T.FOLDER},{label:_("scans.scanType.quick"),value:T.QUICK}];u.smartscan.isSchedulingAllowed()&&t.push({label:_("scans.scanType.smartscan"),value:"smartscan"});const e=this.get("regionalSettings"),n=v.weekdays();null!==e&&n.push(...n.splice(0,e.firstDayOfWeek+1)),this.set({label:{id:"scans-custom-settings-label",label:_("scans.scanName"),load:this.getScanLabel.bind(this),change:this.changeScanProp.bind(this,"Label"),required:!0,testAttr:"scn_scan-custom-scan-name",maxLength:60},scanType:{id:"scans-custom-settings-scanType",label:_("scans.scanType"),load:this.getScanType.bind(this),change:this.changeScanType.bind(this),options:t,testAttr:"scn_scan-custom-scan-type"},schedule:{frequency:{id:"scans-custom-settings-schedule-frequency",label:_("scans.schedule.frequency"),load:this.getScheduleFrequency.bind(this),change:this.changeScheduleFrequency.bind(this),options:[{label:_("scans.schedule.never.label"),value:""},{label:_("scans.schedule.once.label"),value:"Once"},{label:_("scans.schedule.daily.label"),value:"Daily"},{label:_("scans.schedule.weekly.label"),value:"Weekly"},{label:_("scans.schedule.monthly.label"),value:"Monthly"}],testAttr:"scn_scan-custom-scan-frequency"},date:{id:"scans-custom-settings-schedule-date",label:_("scans.schedule.date"),type:"date",load:this.getScheduleDate.bind(this),change:this.changeScheduleDate.bind(this),required:!0,testAttr:"scn_scan-custom-scan-schedule-date"},dayOfWeek:{id:"scans-custom-settings-schedule-dayOfWeek",label:_("scans.schedule.dayOfWeek"),load:this.getScheduleDay.bind(this),change:this.changeScheduleDay.bind(this),options:n.map(((t,e)=>({label:t,value:e+1}))),testAttr:"scn_scan-custom-scan-schedule-day-of-week"},dayOfMonth:{id:"scans-custom-settings-schedule-dayOfMonth",label:_("scans.schedule.dayOfMonth"),load:this.getScheduleDay.bind(this),change:this.changeScheduleDayOfMonth.bind(this),required:!0,testAttr:"scn_scan-custom-scan-schedule-day-of-month"},time:{id:"scans-custom-settings-schedeule-time",label:_("scans.schedule.time"),type:"time",load:this.getScheduleTime.bind(this),change:this.changeScheduleTime.bind(this),required:!0,testAttr:"scn_scan-custom-scan-schedule-time"}}})},getScanLabel(){return this._isNewScan?Promise.resolve({locked:!1,value:""}):this.scan.loadProp("Label")},getScanType(t){return this.scan.loadProp("Job").then((e=>"SmartScan"===e.value?{locked:e.locked,value:"smartscan"}:this.getScanAreas(t).then((t=>{let e;return e=_e.every((e=>t.includes(e)))?T.QUICK:t.includes("AllHarddisks")||t.includes("SystemDisk")?T.FULL:T.FOLDER,{locked:!1,value:e}}))))},changeScanProp(t,e){return this.addPropToSave(t,e),Promise.resolve()},changeScanType(t){this.removePropsToSave(["ScanType","TaskSensitivity","UseCodeEmulation","Job","ScanAreas"]);let e=[];const n={ScanType:"Content",TaskSensitivity:"80",UseCodeEmulation:"1",Job:"Scan"};switch(t){case T.QUICK:e=_e,n.ScanType="Extensions",n.TaskSensitivity="40",n.UseCodeEmulation="0";break;case"smartscan":n.Job="SmartScan"}for(const s in n)this.addPropToSave(s,n[s]);return this.saveScanAreas(e),Promise.resolve()},getScheduleFrequency(){return this.scan.loadProp("SchedulerEnabled").then((t=>"1"==t.value)).then((t=>t?this.scan.loadProp("SchedType"):{locked:!1,value:""}))},changeScheduleFrequency(t){return this.addPropToSave("SchedulerEnabled",t?"1":"0"),t&&(this.addPropToSave("SchedType",t),this.addPropToSave("SchedDays","127"),this.addPropToSave("SchedTime","0")),this.getScheduleTiming(!0).then((t=>{this._scheduleChanged=!0,this.saveScheduleTiming(t)}))},getScheduleDate(t){return this.getScheduleTiming(t).then((t=>({locked:!1,value:t.date})))},changeScheduleDate(t){return this.saveScheduleTiming({date:t}),Promise.resolve()},getScheduleDay(t){return this.getScheduleTiming(t).then((t=>({locked:!1,value:t.day})))},changeScheduleDay(t){return this.saveScheduleTiming({day:t}),Promise.resolve()},changeScheduleDayOfMonth(t){return+t>31?Promise.reject("invalid date "+t):this.changeScheduleDay(t)},getScheduleTime(t){return this.getScheduleTiming(t).then((t=>({locked:!1,value:t.time})))},changeScheduleTime(t){return this.saveScheduleTiming({time:t}),Promise.resolve()},getScheduleTiming(t){return!t&&this.scheduleTimingPromise||(this.scheduleTimingPromise=this.scan.loadProp("SchedTime")),this.scheduleTimingPromise.then((t=>{const e=new Date(1e3*t.value);let n;return e.getTime()?(n={},"Once"===this.get("schedule.frequency.value")?(n.date=e.getFullYear()+"-"+(e.getMonth()+1)+"-"+e.getDate(),n.time=e.getHours()+":"+e.getMinutes()):(n.day=e.getUTCDate(),n.time=e.getUTCHours()+":"+e.getUTCMinutes())):n=this.getDefaultScheduleTiming(),this.addZerosToScheduleTiming(n)}))},saveScheduleTiming(t){const e=this.get("schedule.frequency.value"),n="Once"!==e;let s;switch(t.time=t.time||this.get("schedule.time.value"),e){case"Once":t.date=t.date||this.get("schedule.date.value");break;case"Daily":t.date="1970-01-01";break;case"Weekly":s=t.day||this.get("schedule.dayOfWeek.value"),t.date="1970-01-"+s;break;case"Monthly":s=t.day||this.get("schedule.dayOfMonth.value"),t.date="1970-01-"+s;break;default:return}this.addZerosToScheduleTiming(t);const a=new Date(t.date+"T"+t.time+(n?"Z":""));isNaN(a)&&console.error("invalid date or time: "+JSON.stringify(t)),this.addPropToSave("SchedTime",a/1e3),this._scheduleChanged=!0},getDefaultScheduleTiming(){const t=new Date;return{day:1,date:t.getFullYear()+"-"+(t.getMonth()+1)+"-"+t.getDate(),time:t.getHours()+":"+t.getMinutes()}},addZerosToScheduleTiming:t=>(t.time=t.time.split(":").map((t=>("0"+t).slice(-2))).join(":"),t.date&&(t.date=t.date.split("-").map((t=>1===t.length?"0"+t:t)).join("-")),t),addFolders(){n("app.utils.SelectFolders",{alsoFiles:!1}).then((t=>{if("ok"===t.dialogReturnCode){const e=this.get("folders");t.paths.split(";").forEach((t=>{t=t.replace(we,""),e.includes(t)||e.push(t)})),this.saveScanAreas(e)}}))},removeFolder(t){const e=this.get("folders"),n=e.findIndex((e=>e===t));e.splice(n,1),this.saveScanAreas(e)},getScanAreas(t){return!t&&this.scanAreasPromise||(this.scanAreasPromise=this.scan.loadProp("ScanAreas")),this.scanAreasPromise.then((t=>{let e=[];return t&&t.value&&(e=t.value.split(";").map((t=>t.replace(we,"")))),e}))},saveScanAreas(t){const e=t.map((t=>'"'+t+'"')).join(";");this.addPropToSave("ScanAreas",e)}}),ye=t.extend({template:{v:3,t:[{t:7,e:"Page",a:{heading:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory")'}}],cssCls:"scn",backHash:[{t:2,r:"backHash"}]},f:[{t:7,e:"div",a:{slot:"breadcrumbs"},f:[{t:7,e:"Crumbs",a:{section:"security",moduleId:"scans",customBreadcrumbs:[{t:2,r:"breadcrumbCustomLinks"}]}}]}," ",{t:7,e:"div",a:{slot:"page-content"},f:[{t:4,f:[{t:7,e:"ScanHistoryDetail",a:{scanId:[{t:2,r:"scanId"}],sessionId:[{t:2,r:"sessionId"}]}}],n:50,x:{r:["scanHistoryDetailLoaded","scanId","sessionId"],s:"_0&&_1&&_2"}},{t:4,n:51,f:[{t:7,e:"kin-view",a:{loading:[{t:2,r:"loading"}]},f:[{t:4,f:[{t:7,e:"div",a:{slot:"description"},f:[{t:7,e:"p",a:{class:"kin_description__text"},f:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory.desc")'}}]}]}],n:50,r:"scans.length"},{t:4,n:51,f:[{t:7,e:"div",a:{slot:"description"},f:[{t:7,e:"p",a:{class:"kin_description__text"},f:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory.noScans")'}}]}]}],r:"scans.length"}," ",{t:7,e:"div",a:{slot:"view-content"},f:[{t:7,e:"kin-table",a:{datalength:[{t:2,r:"scans.length"}]},f:[{t:7,e:"div",a:{slot:"table-header",role:"row",class:"scn_history__row"},f:[{t:7,e:"div"}," ",{t:7,e:"div",a:{role:"columnheader"},f:[{t:3,x:{r:["nls"],s:'_0("scans.scanName")'}}]}," ",{t:7,e:"div",a:{role:"columnheader"},f:[{t:3,x:{r:["nls"],s:'_0("scans.scanHistory.dateScanned")'}}]}," ",{t:7,e:"div"}]}," ",{t:7,e:"div",a:{slot:"table-body"},f:[{t:4,f:[{t:7,e:"ScanHistoryRow",a:{scan:[{t:2,r:"."}]}}],n:52,r:"scans"}]}," ",{t:7,e:"div",a:{slot:"table-empty-icon",class:"svg -empty-table"}}]}]}]}],x:{r:["scanHistoryDetailLoaded","scanId","sessionId"],s:"_0&&_1&&_2"}}]}]}]},components:{},data:()=>({loading:!0,scans:null,scanId:null,sessionId:null,scanTitle:null,scanHistoryDetailLoaded:!1}),computed:{backHash:function(){return this.get("scanId")&&this.get("sessionId")?"#Scans/scanHistory":"#Scans"},breadcrumbCustomLinks:function(){const t=[{title:_("scans.scanHistory"),url:"#Scans/scanHistory"}],e=this.get("scanId"),n=this.get("sessionId");return e&&n&&t.push({title:this.get("scanTitle"),url:"#Scans/scanHistory/"+e+"/"+n}),t}},onrender(){this.components.ScanHistoryDetail=$.getBrandedComponent("ScanHistoryDetail"),this.components.ScanHistoryRow=$.getBrandedComponent("ScanHistoryRow"),this.set("scanHistoryDetailLoaded",!0)},oninit(){this._scan=null;const t=this.get("scanId"),e=this.get("sessionId");t&&e?$.getScanHistoryDetail(t,e).then((t=>{this.set("scanTitle",t.label)})).catch((t=>{console.log("getScanHistoryDetail error",t)})):$.getScanHistory().then((t=>{this.set("scans",t),this.set("loading",!1)})).catch((t=>{console.log("getScanHistory error",t)})),this.on("ScanHistoryRow.showThreats",((t,e,n)=>{location.hash="#Scans/scanHistory/"+e+"/"+n,this.set({scanId:e,sessionId:n})})),this.on("ThreatsList.threatsResolved ThreatsList.threatsSkip",(()=>{this.set({scanId:null,sessionId:null}),location.hash="#Scans/scanHistory"}))}}),Se=t.extend({template:{v:3,t:[{t:7,e:"Page",a:{heading:[{t:2,x:{r:["scanStopped","scanState","SCAN_STATES.scanned","nls"],s:'_0||_1===_2?"":_3("tuneup.performanceScan.title")'}}],csscls:"-center-all",backevent:"true"},f:[{t:7,e:"div",a:{slot:"page-content",class:"kin_page-content -scan"},f:[{t:7,e:"div",a:{class:"kin_scan"},f:[{t:7,e:"div",a:{slot:"description"},f:[{t:4,f:[{t:7,e:"p",a:{class:"kin_description__text -center"},f:[{t:2,x:{r:["nls"],s:'_0("tuneup.scanning.desc")'}}]}],n:50,x:{r:["scanState","SCAN_STATES.scanning"],s:"_0===_1"}}]}," ",{t:7,e:"div",a:{id:"performance",emptyCta:"done"}}]}]}]}]},data:()=>({SCAN_STATES:null,scanSate:null,scanStopped:null}),oninit(){i.init().then((()=>{Promise.all([i.importModule("Tuneup","PerformanceScan"),i.importModule("Tuneup","ServiceProxy")]).then((([t,e])=>{this.set({SCAN_STATES:e.SCAN_STATES}),this.performanceScan=g(t,{target:document.getElementById("performance")}),this.performanceScan.set("emptyCta","done"),this.performanceScan.fire("startScan"),this.performanceScan.on("resolve goBack skip",(()=>{location.hash="#Dashboard"})),this.performanceScan.on("update",(t=>{this.set({scanState:t})})),this.performanceScan.on("scanStopped",(t=>{this.set({scanStopped:t})}))}))}))},onteardown(){this.performanceScan&&this.performanceScan.teardown&&this.performanceScan.teardown()}});function xe(){}function Te(t){return t()}function ke(){return Object.create(null)}function Ce(t){t.forEach(Te)}function De(t){return"function"==typeof t}function Ae(t,e){return t!=t?e==e:t!==e||t&&"object"==typeof t||"function"==typeof t}function Pe(t,e,n){t.$$.on_destroy.push(function(t,...e){if(null==t)return xe;const n=t.subscribe(...e);return n.unsubscribe?()=>n.unsubscribe():n}(e,n))}function Ie(t,e,n,s){if(t){const a=Le(t,e,n,s);return t[0](a)}}function Le(t,e,n,s){return t[1]&&s?function(t,e){for(const n in e)t[n]=e[n];return t}(n.ctx.slice(),t[1](s(e))):n.ctx}function Re(t,e,n,s,a,i,o){const c=function(t,e,n,s){if(t[2]&&s){const a=t[2](s(n));if(void 0===e.dirty)return a;if("object"==typeof a){const t=[],n=Math.max(e.dirty.length,a.length);for(let s=0;s<n;s+=1)t[s]=e.dirty[s]|a[s];return t}return e.dirty|a}return e.dirty}(e,s,a,i);if(c){const a=Le(e,n,s,o);t.p(a,c)}}function Ee(t,e){t.appendChild(e)}function Ne(t,e,n){t.insertBefore(e,n||null)}function $e(t){t.parentNode.removeChild(t)}function Fe(t,e){for(let n=0;n<t.length;n+=1)t[n]&&t[n].d(e)}function Oe(t){return document.createElement(t)}function Me(t){return document.createTextNode(t)}function We(){return Me(" ")}function Be(){return Me("")}function Ue(t,e,n,s){return t.addEventListener(e,n,s),()=>t.removeEventListener(e,n,s)}function He(t,e,n){null==n?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function je(t,e,n){e in t?t[e]=n:He(t,e,n)}function Ve(t,e){e=""+e,t.wholeText!==e&&(t.data=e)}function Ge(t,e,n,s){t.style.setProperty(e,n,s?"important":"")}function Ke(t,e,n){t.classList[n?"add":"remove"](e)}let ze;function qe(t){ze=t}function Ze(){if(!ze)throw new Error("Function called outside component initialization");return ze}function Je(t){Ze().$$.on_mount.push(t)}function Xe(t){Ze().$$.on_destroy.push(t)}function Ye(){const t=Ze();return(e,n)=>{const s=t.$$.callbacks[e];if(s){const a=function(t,e){const n=document.createEvent("CustomEvent");return n.initCustomEvent(t,!1,!1,e),n}(e,n);s.slice().forEach((e=>{e.call(t,a)}))}}}const Qe=[],tn=[],en=[],nn=[],sn=Promise.resolve();let an=!1;function on(t){en.push(t)}let cn=!1;const rn=new Set;function ln(){if(!cn){cn=!0;do{for(let t=0;t<Qe.length;t+=1){const e=Qe[t];qe(e),dn(e.$$)}for(qe(null),Qe.length=0;tn.length;)tn.pop()();for(let t=0;t<en.length;t+=1){const e=en[t];rn.has(e)||(rn.add(e),e())}en.length=0}while(Qe.length);for(;nn.length;)nn.pop()();an=!1,cn=!1,rn.clear()}}function dn(t){if(null!==t.fragment){t.update(),Ce(t.before_update);const e=t.dirty;t.dirty=[-1],t.fragment&&t.fragment.p(t.ctx,e),t.after_update.forEach(on)}}const un=new Set;let hn;function pn(){hn={r:0,c:[],p:hn}}function mn(){hn.r||Ce(hn.c),hn=hn.p}function fn(t,e){t&&t.i&&(un.delete(t),t.i(e))}function gn(t,e,n,s){if(t&&t.o){if(un.has(t))return;un.add(t),hn.c.push((()=>{un.delete(t),s&&(n&&t.d(1),s())})),t.o(e)}}const bn="undefined"!=typeof window?window:"undefined"!=typeof globalThis?globalThis:global;function wn(t){t&&t.c()}function _n(t,e,n){const{fragment:s,on_mount:a,on_destroy:i,after_update:o}=t.$$;s&&s.m(e,n),on((()=>{const e=a.map(Te).filter(De);i?i.push(...e):Ce(e),t.$$.on_mount=[]})),o.forEach(on)}function vn(t,e){const n=t.$$;null!==n.fragment&&(Ce(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function yn(t,e){-1===t.$$.dirty[0]&&(Qe.push(t),an||(an=!0,sn.then(ln)),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<<e%31}function Sn(t,e,n,s,a,i,o=[-1]){const c=ze;qe(t);const r=e.props||{},l=t.$$={fragment:null,ctx:null,props:i,update:xe,not_equal:a,bound:ke(),on_mount:[],on_destroy:[],before_update:[],after_update:[],context:new Map(c?c.$$.context:[]),callbacks:ke(),dirty:o,skip_bound:!1};let d=!1;if(l.ctx=n?n(t,r,((e,n,...s)=>{const i=s.length?s[0]:n;return l.ctx&&a(l.ctx[e],l.ctx[e]=i)&&(!l.skip_bound&&l.bound[e]&&l.bound[e](i),d&&yn(t,e)),n})):[],l.update(),d=!0,Ce(l.before_update),l.fragment=!!s&&s(l.ctx),e.target){if(e.hydrate){const t=function(t){return Array.from(t.childNodes)}(e.target);l.fragment&&l.fragment.l(t),t.forEach($e)}else l.fragment&&l.fragment.c();e.intro&&fn(t.$$.fragment),_n(t,e.target,e.anchor),ln()}qe(c)}class xn{$destroy(){vn(this,1),this.$destroy=xe}$on(t,e){const n=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return n.push(e),()=>{const t=n.indexOf(e);-1!==t&&n.splice(t,1)}}$set(t){var e;this.$$set&&(e=t,0!==Object.keys(e).length)&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}}function Tn(t){let e,n,s,a,i,o,c,r;const l=t[15].default,d=Ie(l,t,t[14],null);return{c(){e=Oe("div"),n=Oe("div"),s=Oe("iframe"),o=We(),c=Oe("div"),d&&d.c(),s.src!==(a=t[2])&&He(s,"src",a),He(s,"data-test",i="ipm-elm-"+t[0]),He(s,"title",t[1]),He(n,"class","sve_ipm"),Ge(n,"display",t[4]?"block":"none"),He(c,"data-slot",""),Ge(c,"display",t[4]?"none":"block"),He(e,"class","svelte wrap")},m(a,i){Ne(a,e,i),Ee(e,n),Ee(n,s),t[16](s),Ee(e,o),Ee(e,c),d&&d.m(c,null),r=!0},p(t,e){(!r||4&e[0]&&s.src!==(a=t[2]))&&He(s,"src",a),(!r||1&e[0]&&i!==(i="ipm-elm-"+t[0]))&&He(s,"data-test",i),(!r||2&e[0])&&He(s,"title",t[1]),(!r||16&e[0])&&Ge(n,"display",t[4]?"block":"none"),d&&d.p&&16384&e[0]&&Re(d,l,t,t[14],e,null,null),(!r||16&e[0])&&Ge(c,"display",t[4]?"none":"block")},i(t){r||(fn(d,t),r=!0)},o(t){gn(d,t),r=!1},d(n){n&&$e(e),t[16](null),d&&d.d(n)}}}y();const kn=7e3;function Cn(t,e){if(!t)return t;try{const n=new URL(t);return Object.entries(e).forEach((([t,e])=>n.searchParams.set(t,encodeURIComponent(e)))),n.href}catch(n){return console.log(n),t}}function Dn(t,e,i){let c;Pe(t,o,(t=>i(13,c=t)));let{$$slots:r={},$$scope:l}=e,{id:d}=e,{opmUrl:u}=e,{title:f}=e,{params:g={}}=e,{condition:b=!0}=e,{timeout:w=kn}=e,{route:_}=e;const v=m.createLogger("component.ipm"),y=Ye(),S="true"===localStorage.getItem("automationDisableIpm"),x=[];let T,k,C,D,A,P,I,L,R,E=null;function N(){!C&&E&&n("opm.message_shown",{message_id:E})}function $(t){v.debug({isIframe:T,ipmUrl:k,event:t,id:d,impId:t&&t.data?t.data.elmId:null}),T&&t&&t.data&&("windowLoaded"!==t.data.action||""===t.data.elmId||t.data.elmId!=d&&t.data.placement!=d||(v.info("ipm content loaded"),O(),F(Math.round((performance.now()-P)/1e3)),d==parseInt(d)&&n("app.ipm_tracking.track",{elem_id:parseInt(d),response_time:-1}),y("success",d)))}function F(t){h.getValueCached("avdef://config/GuiCache/TrackIpmLoadTime",!0).then((e=>{var n;e&&a.timing("IPM loading",!1===t?66666:t,d,!1===(n=t)?"timeout":n>=6e4?"> 60s":n>=3e4?"30-60 s":n>=15e3?"15-30 s":n>=1e4?"10-15 s":n>=5e3?"5-10 s":n>=4e3?"4-5 s":n>=3e3?"3-4 s":n>=2e3?"2-3 s":n>=1e3?"1-2 s":"0-1 s")}))}function O(){I&&clearTimeout(I)}function M(){const t=null!=d?D[d]:null;return t?Promise.resolve(t):u?Promise.resolve(u):!d&&0!==d||"object"==typeof d?Promise.resolve("about:blank"):"string"==typeof d?function(){if(Number.isInteger(parseInt(d)))return console.error("IPM Component tried to load OPM component with an integer in a string:",d),p.getUrl(parseInt(d),g);return n("av.opm.GetUrlForPlacement",{id:d}).then((t=>t?(E=t.msg_id||null,Cn(t.url||t,g)):(console.warn("OPM URL empty, for ID:",d),""))).catch((t=>(console.error("Ipm component, av.opm.GetUrlForPlacement failed:",t),B("opmCallFailed"),"")))}():Number.isInteger(d)?p.getUrl(parseInt(d),g):(console.error("IPM component could not recognize id:",d,"of type:",typeof d),B("wrongParam"),Promise.resolve(""))}function W(t=null){v.info("updateFrame",{isIframe:T,ipmUrl:k}),i(11,C=null),t&&t.url&&E!=t.msg_id?(N(),E=t.msg_id):"string"!=typeof d&&i(2,k="about:blank"),T&&(O(),(t&&t.url?Promise.resolve(t.url):M()).then((t=>{t=Cn(t,g),P=performance.now(),v.info("loading ipm url: "+t),k!==t&&(I=setTimeout((()=>{F(!1),B("timeout")}),w),i(2,k=t))})))}function B(t,e=0){i(11,C=t),console.warn("Ipm component error:",C,"for id:",d),y("error",{message:t,code:e,id:d})}return Je((()=>{W()})),Xe((()=>{O(),x.forEach((t=>t())),window.removeEventListener("message",$),window.removeEventListener("beforeunload",N)})),function(){let t;try{t=JSON.parse(localStorage.getItem("IPM_OVERRIDE")),D=t||{},t&&v.info("using override",t)}catch{v.error("Failed to parse localStorage.IPM_OVERRIDE"),D={}}}(),window.addEventListener("beforeunload",N,!1),window.addEventListener("message",$,!1),x.push(s.on("ASW_NOTIF_RELOAD_IPM",(()=>W())),s.on("ipm.reload."+d,(t=>W(t)))),t.$$set=t=>{"id"in t&&i(0,d=t.id),"opmUrl"in t&&i(5,u=t.opmUrl),"title"in t&&i(1,f=t.title),"params"in t&&i(6,g=t.params),"condition"in t&&i(7,b=t.condition),"timeout"in t&&i(8,w=t.timeout),"route"in t&&i(9,_=t.route),"$$scope"in t&&i(14,l=t.$$scope)},t.$$.update=()=>{12288&t.$$.dirty[0]&&null!=c&&(c?!1===L&&(v.debug("went online"),W()):(v.debug("went offline"),O(),B("offline")),i(12,L=c)),2176&t.$$.dirty[0]&&i(10,T=!C&&!S&&b),1544&t.$$.dirty[0]&&null!=_&&T&&(v.debug("change of route: "+_),A.contentWindow&&A.contentWindow.postMessage&&A.contentWindow.postMessage("route:"+_,"*")),1028&t.$$.dirty[0]&&i(4,R=T&&k)},[d,f,k,A,R,u,g,b,w,_,T,C,L,c,l,r,function(t){tn[t?"unshift":"push"]((()=>{A=t,i(3,A)}))}]}class An extends xn{constructor(t){super(),Sn(this,t,Dn,Tn,Ae,{id:0,opmUrl:5,title:1,params:6,condition:7,timeout:8,route:9},[-1,-1])}}const{window:Pn}=bn;function In(t,e,n){const s=t.slice();return s[45]=e[n],s}function Ln(t,e,n){const s=t.slice();return s[48]=e[n],s[50]=n,s}function Rn(t){let e,n,s,a,i,o,c,r;return{c(){e=Oe("div"),n=Oe("kin-icon"),i=We(),o=Oe("kin-icon"),je(n,"class",s="sve_toaster__icon -"+t[0].icon.cssCls),je(n,"name",a=t[0].icon.name),je(n,"size","40"),je(o,"name",c=t[0].icon.bgName),je(o,"size","80"),je(o,"class",r="sve_toaster__icon__bg -"+t[0].icon.bgName+" "+(t[0].icon.color?"color-"+t[0].icon.color:"")+" -text"),He(e,"class","sve_toaster__icon__container")},m(t,s){Ne(t,e,s),Ee(e,n),Ee(e,i),Ee(e,o)},p(t,e){1&e[0]&&s!==(s="sve_toaster__icon -"+t[0].icon.cssCls)&&je(n,"class",s),1&e[0]&&a!==(a=t[0].icon.name)&&je(n,"name",a),1&e[0]&&c!==(c=t[0].icon.bgName)&&je(o,"name",c),1&e[0]&&r!==(r="sve_toaster__icon__bg -"+t[0].icon.bgName+" "+(t[0].icon.color?"color-"+t[0].icon.color:"")+" -text")&&je(o,"class",r)},d(t){t&&$e(e)}}}function En(t){let e,n=t[0].title+"";return{c(){e=Oe("h2"),He(e,"class","sve_toaster__title h2")},m(t,s){Ne(t,e,s),e.innerHTML=n},p(t,s){1&s[0]&&n!==(n=t[0].title+"")&&(e.innerHTML=n)},d(t){t&&$e(e)}}}function Nn(t){let e,n=t[0].text+"";return{c(){e=Oe("p"),He(e,"class","sve_toaster__text p")},m(t,s){Ne(t,e,s),e.innerHTML=n},p(t,s){1&s[0]&&n!==(n=t[0].text+"")&&(e.innerHTML=n)},d(t){t&&$e(e)}}}function $n(t){let e,n,s;return n=new An({props:{params:t[0].ipmParams,id:t[0].ipmAction}}),n.$on("error",t[31]),{c(){e=Oe("div"),wn(n.$$.fragment),He(e,"class","sve_toaster__ipmaction")},m(t,a){Ne(t,e,a),_n(n,e,null),s=!0},p(t,e){const s={};1&e[0]&&(s.params=t[0].ipmParams),1&e[0]&&(s.id=t[0].ipmAction),n.$set(s)},i(t){s||(fn(n.$$.fragment,t),s=!0)},o(t){gn(n.$$.fragment,t),s=!1},d(t){t&&$e(e),vn(n)}}}function Fn(t){let e,n,s,a,i=t[0].actionText&&On(t),o=!t[4]&&t[0].actions&&t[0].actions.length&&Mn(t),c=t[4]&&Gn(t),r=t[0].dontShowAgain&&zn(t);return{c(){i&&i.c(),e=We(),o&&o.c(),n=We(),c&&c.c(),s=We(),r&&r.c(),a=Be()},m(t,l){i&&i.m(t,l),Ne(t,e,l),o&&o.m(t,l),Ne(t,n,l),c&&c.m(t,l),Ne(t,s,l),r&&r.m(t,l),Ne(t,a,l)},p(t,l){t[0].actionText?i?i.p(t,l):(i=On(t),i.c(),i.m(e.parentNode,e)):i&&(i.d(1),i=null),!t[4]&&t[0].actions&&t[0].actions.length?o?o.p(t,l):(o=Mn(t),o.c(),o.m(n.parentNode,n)):o&&(o.d(1),o=null),t[4]?c?c.p(t,l):(c=Gn(t),c.c(),c.m(s.parentNode,s)):c&&(c.d(1),c=null),t[0].dontShowAgain?r?r.p(t,l):(r=zn(t),r.c(),r.m(a.parentNode,a)):r&&(r.d(1),r=null)},i:xe,o:xe,d(t){i&&i.d(t),t&&$e(e),o&&o.d(t),t&&$e(n),c&&c.d(t),t&&$e(s),r&&r.d(t),t&&$e(a)}}}function On(t){let e,n,s=t[0].actionText+"";return{c(){e=Oe("p"),n=Me(s),He(e,"class","sve_toaster__text p -small -secondary")},m(t,s){Ne(t,e,s),Ee(e,n)},p(t,e){1&e[0]&&s!==(s=t[0].actionText+"")&&Ve(n,s)},d(t){t&&$e(e)}}}function Mn(t){let e,n,s,a,i,o,c,r,l,d=t[0].actions[0].label+"",u=null!=t[8]&&Wn(t),h=1===t[0].actions.length&&t[12]>1&&t[13]&&Bn(t);function p(t,e){return 2!==t[0].actions.length||t[0].hideSecondAction?t[0].actions.length>2||t[0].hideSecondAction&&t[0].actions.length>1?Un:void 0:Hn}let m=p(t),f=m&&m(t);return{c(){e=Oe("div"),n=Oe("kin-button"),s=Me(d),a=We(),u&&u.c(),o=We(),h&&h.c(),c=We(),f&&f.c(),je(n,"processing",t[7]),je(n,"data-test",i="dd_primary_"+t[0].actions[0].labelTest||"dd_primary_btn"),He(e,"class","sve_toaster__btns")},m(i,d){Ne(i,e,d),Ee(e,n),Ee(n,s),Ee(n,a),u&&u.m(n,null),Ee(e,o),h&&h.m(e,null),Ee(e,c),f&&f.m(e,null),r||(l=Ue(n,"click",t[27]),r=!0)},p(t,a){1&a[0]&&d!==(d=t[0].actions[0].label+"")&&Ve(s,d),null!=t[8]?u?u.p(t,a):(u=Wn(t),u.c(),u.m(n,null)):u&&(u.d(1),u=null),128&a[0]&&je(n,"processing",t[7]),1&a[0]&&i!==(i="dd_primary_"+t[0].actions[0].labelTest||"dd_primary_btn")&&je(n,"data-test",i),1===t[0].actions.length&&t[12]>1&&t[13]?h?h.p(t,a):(h=Bn(t),h.c(),h.m(e,c)):h&&(h.d(1),h=null),m===(m=p(t))&&f?f.p(t,a):(f&&f.d(1),f=m&&m(t),f&&(f.c(),f.m(e,null)))},d(t){t&&$e(e),u&&u.d(),h&&h.d(),f&&f.d(),r=!1,l()}}}function Wn(t){let e,n,s;return{c(){e=Me("("),n=Me(t[8]),s=Me(")")},m(t,a){Ne(t,e,a),Ne(t,n,a),Ne(t,s,a)},p(t,e){256&e[0]&&Ve(n,t[8])},d(t){t&&$e(e),t&&$e(n),t&&$e(s)}}}function Bn(t){let e,n,s,a,i,o,c,r,l=_("detection.action.closeAll")+"";return{c(){e=Oe("kin-button"),n=Me(l),s=Me("\n\t\t\t\t\t\t\t("),a=Me(t[12]),i=Me(")"),je(e,"class","g-margin-left--10"),je(e,"processing",t[7]),je(e,"data-test",o="closeAll"),je(e,"type","secondary")},m(o,l){Ne(o,e,l),Ee(e,n),Ee(e,s),Ee(e,a),Ee(e,i),c||(r=Ue(e,"click",t[17]),c=!0)},p(t,n){4096&n[0]&&Ve(a,t[12]),128&n[0]&&je(e,"processing",t[7])},d(t){t&&$e(e),c=!1,r()}}}function Un(t){let e,n,s,a,i,o,c,r,l,d=_("global.moreOptions")+"",u=t[0].actions,h=[];for(let p=0;p<u.length;p+=1)h[p]=jn(Ln(t,u,p));return{c(){e=Oe("kin-dropdown"),n=Oe("div"),s=Oe("kin-button"),a=Me(d),i=We(),o=Oe("kin-icon"),r=We(),l=Oe("div");for(let t=0;t<h.length;t+=1)h[t].c();je(o,"name","icon-s-controls-arrow-down"),je(o,"size","16"),je(s,"type","secondary"),je(s,"data-test",c="dd_dropdown_btn"),He(n,"slot","dropdown-activator")},m(t,c){Ne(t,e,c),Ee(e,n),Ee(n,s),Ee(s,a),Ee(s,i),Ee(s,o),Ee(e,r),Ee(e,l);for(let e=0;e<h.length;e+=1)h[e].m(l,null)},p(t,e){if(2097153&e[0]){let n;for(u=t[0].actions,n=0;n<u.length;n+=1){const s=Ln(t,u,n);h[n]?h[n].p(s,e):(h[n]=jn(s),h[n].c(),h[n].m(l,null))}for(;n<h.length;n+=1)h[n].d(1);h.length=u.length}},d(t){t&&$e(e),Fe(h,t)}}}function Hn(t){let e,n,s,a,i,o,c=t[0].actions[1].label+"",r=null!=t[8]&&Vn(t);return{c(){e=Oe("kin-button"),n=Me(c),s=We(),r&&r.c(),je(e,"class","g-margin-left--10"),je(e,"processing",t[7]),je(e,"data-test",a="dd_secondary_"+t[0].actions[1].labelTest||"dd_secondary_btn"),je(e,"type","secondary")},m(a,c){Ne(a,e,c),Ee(e,n),Ee(e,s),r&&r.m(e,null),i||(o=Ue(e,"click",t[28]),i=!0)},p(t,s){1&s[0]&&c!==(c=t[0].actions[1].label+"")&&Ve(n,c),null!=t[8]?r?r.p(t,s):(r=Vn(t),r.c(),r.m(e,null)):r&&(r.d(1),r=null),128&s[0]&&je(e,"processing",t[7]),1&s[0]&&a!==(a="dd_secondary_"+t[0].actions[1].labelTest||"dd_secondary_btn")&&je(e,"data-test",a)},d(t){t&&$e(e),r&&r.d(),i=!1,o()}}}function jn(t){let e,n=0!==t[50]&&function(t){let e,n,s,a,i,o,c=t[48].label+"";function r(){return t[29](t[50])}return{c(){e=Oe("kin-dropdown-item"),n=Me(c),s=We(),je(e,"data-test",a="dd_dropdown_"+t[48].labelTest||"dd_dropdown_"+t[50])},m(t,a){Ne(t,e,a),Ee(e,n),Ee(e,s),i||(o=Ue(e,"click",r),i=!0)},p(s,i){t=s,1&i[0]&&c!==(c=t[48].label+"")&&Ve(n,c),1&i[0]&&a!==(a="dd_dropdown_"+t[48].labelTest||"dd_dropdown_"+t[50])&&je(e,"data-test",a)},d(t){t&&$e(e),i=!1,o()}}}(t);return{c(){n&&n.c(),e=Be()},m(t,s){n&&n.m(t,s),Ne(t,e,s)},p(t,e){0!==t[50]&&n.p(t,e)},d(t){n&&n.d(t),t&&$e(e)}}}function Vn(t){let e,n,s;return{c(){e=Me("("),n=Me(t[8]),s=Me(")")},m(t,a){Ne(t,e,a),Ne(t,n,a),Ne(t,s,a)},p(t,e){256&e[0]&&Ve(n,t[8])},d(t){t&&$e(e),t&&$e(n),t&&$e(s)}}}function Gn(t){let e,n,s,a=t[5]&&t[5].text&&Kn(t);return{c(){e=Oe("div"),n=Oe("kin-progress"),s=We(),a&&a.c(),je(n,"percentage","unknown"),He(e,"class","sve_toaster__progress")},m(t,i){Ne(t,e,i),Ee(e,n),Ee(e,s),a&&a.m(e,null)},p(t,n){t[5]&&t[5].text?a?a.p(t,n):(a=Kn(t),a.c(),a.m(e,null)):a&&(a.d(1),a=null)},d(t){t&&$e(e),a&&a.d()}}}function Kn(t){let e,n,s=t[5].text+"";return{c(){e=Oe("p"),n=Me(s),He(e,"class","g-margin-top--10 p -small -secondary")},m(t,s){Ne(t,e,s),Ee(e,n)},p(t,e){32&e[0]&&s!==(s=t[5].text+"")&&Ve(n,s)},d(t){t&&$e(e)}}}function zn(t){let e,n,s,a,i,o,c,r=t[0].dontShowAgain.label+"";return{c(){e=Oe("p"),n=Oe("input"),s=We(),a=Oe("label"),i=Me(r),He(n,"type","checkbox"),He(n,"id","detection_dontShowAgain"),He(n,"class","checkbox"),He(a,"for","detection_dontShowAgain"),He(a,"class","g-margin-left--5"),He(e,"class","sve_toaster__text p g-margin-top--10")},m(r,l){Ne(r,e,l),Ee(e,n),Ee(e,s),Ee(e,a),Ee(a,i),o||(c=Ue(n,"click",t[30]),o=!0)},p(t,e){1&e[0]&&r!==(r=t[0].dontShowAgain.label+"")&&Ve(i,r)},d(t){t&&$e(e),o=!1,c()}}}function qn(t){let e,n,s,a,i;function o(t,e){return t[2]?Jn:Zn}let c=o(t),r=c(t),l=t[2]&&Xn(t);return{c(){e=Oe("button"),r.c(),n=We(),l&&l.c(),s=Be(),He(e,"class","span -small -secondary g-cursor--pointer"),He(e,"data-test","btn_toggleDetails")},m(o,c){Ne(o,e,c),r.m(e,null),Ne(o,n,c),l&&l.m(o,c),Ne(o,s,c),a||(i=Ue(e,"click",t[18]),a=!0)},p(t,n){c===(c=o(t))&&r?r.p(t,n):(r.d(1),r=c(t),r&&(r.c(),r.m(e,null))),t[2]?l?l.p(t,n):(l=Xn(t),l.c(),l.m(s.parentNode,s)):l&&(l.d(1),l=null)},d(t){t&&$e(e),r.d(),t&&$e(n),l&&l.d(t),t&&$e(s),a=!1,i()}}}function Zn(t){let e,n,s,a=_("global.showDetails")+"";return{c(){e=Me(a),n=We(),s=Oe("kin-icon"),je(s,"name","icon-s-controls-arrow-down"),je(s,"size","16")},m(t,a){Ne(t,e,a),Ne(t,n,a),Ne(t,s,a)},p:xe,d(t){t&&$e(e),t&&$e(n),t&&$e(s)}}}function Jn(t){let e,n,s,a=_("global.hideDetails")+"";return{c(){e=Me(a),n=We(),s=Oe("kin-icon"),je(s,"name","icon-s-controls-arrow-up"),je(s,"size","16")},m(t,a){Ne(t,e,a),Ne(t,n,a),Ne(t,s,a)},p:xe,d(t){t&&$e(e),t&&$e(n),t&&$e(s)}}}function Xn(t){let e,n,s,a,i=t[0].details,o=[];for(let l=0;l<i.length;l+=1)o[l]=es(In(t,i,l));let c=t[5]&&ns(t),r=t[6]&&as(t);return{c(){e=Oe("div"),n=Oe("dl");for(let t=0;t<o.length;t+=1)o[t].c();s=Be(),c&&c.c(),a=Be(),r&&r.c(),He(n,"class","desclist -short"),He(e,"class","sve_toaster__details")},m(t,i){Ne(t,e,i),Ee(e,n);for(let e=0;e<o.length;e+=1)o[e].m(n,null);Ee(n,s),c&&c.m(n,null),Ee(n,a),r&&r.m(n,null)},p(t,e){if(1&e[0]){let a;for(i=t[0].details,a=0;a<i.length;a+=1){const c=In(t,i,a);o[a]?o[a].p(c,e):(o[a]=es(c),o[a].c(),o[a].m(n,s))}for(;a<o.length;a+=1)o[a].d(1);o.length=i.length}t[5]?c?c.p(t,e):(c=ns(t),c.c(),c.m(n,a)):c&&(c.d(1),c=null),t[6]?r?r.p(t,e):(r=as(t),r.c(),r.m(n,null)):r&&(r.d(1),r=null)},d(t){t&&$e(e),Fe(o,t),c&&c.d(),r&&r.d()}}}function Yn(t){let e,n,s,a=t[45].title+"";function i(t,e){return"scoreMeter"===t[45].type&&4>t[45].value?ts:Qn}let o=i(t),c=o(t);return{c(){e=Oe("dt"),n=Me(a),c.c(),s=Be()},m(t,a){Ne(t,e,a),Ee(e,n),c.m(t,a),Ne(t,s,a)},p(t,e){1&e[0]&&a!==(a=t[45].title+"")&&Ve(n,a),o===(o=i(t))&&c?c.p(t,e):(c.d(1),c=o(t),c&&(c.c(),c.m(s.parentNode,s)))},d(t){t&&$e(e),c.d(t),t&&$e(s)}}}function Qn(t){let e,n,s,a=t[45].value+"";return{c(){e=Oe("dd"),n=Me(a),He(e,"data-test",s=t[45].testValue)},m(t,s){Ne(t,e,s),Ee(e,n)},p(t,i){1&i[0]&&a!==(a=t[45].value+"")&&Ve(n,a),1&i[0]&&s!==(s=t[45].testValue)&&He(e,"data-test",s)},d(t){t&&$e(e)}}}function ts(t){let e,n,s,a,i,o,c,r,l;return{c(){e=Oe("dd"),n=Oe("div"),s=Oe("div"),a=We(),i=Oe("div"),o=We(),c=Oe("div"),l=We(),He(n,"class",r="scoremeter -val-"+t[45].value)},m(t,r){Ne(t,e,r),Ee(e,n),Ee(n,s),Ee(n,a),Ee(n,i),Ee(n,o),Ee(n,c),Ee(e,l)},p(t,e){1&e[0]&&r!==(r="scoremeter -val-"+t[45].value)&&He(n,"class",r)},d(t){t&&$e(e)}}}function es(t){let e,n=t[45].value&&Yn(t);return{c(){n&&n.c(),e=Be()},m(t,s){n&&n.m(t,s),Ne(t,e,s)},p(t,s){t[45].value?n?n.p(t,s):(n=Yn(t),n.c(),n.m(e.parentNode,e)):n&&(n.d(1),n=null)},d(t){n&&n.d(t),t&&$e(e)}}}function ns(t){let e,n,s,a,i,o=t[5].text+"",c=t[5].action&&ss(t);return{c(){e=Oe("dt"),e.textContent=`${_("global.status")}`,n=Oe("dd"),s=Me(o),a=We(),c&&c.c(),i=We(),He(n,"data-test","status")},m(t,o){Ne(t,e,o),Ne(t,n,o),Ee(n,s),Ee(n,a),c&&c.m(n,null),Ee(n,i)},p(t,e){32&e[0]&&o!==(o=t[5].text+"")&&Ve(s,o),t[5].action?c?c.p(t,e):(c=ss(t),c.c(),c.m(n,i)):c&&(c.d(1),c=null)},d(t){t&&$e(e),t&&$e(n),c&&c.d()}}}function ss(t){let e,n,s,a,i,o,c=t[5].actionLabel+"";return{c(){e=Me("| "),n=Oe("button"),s=Me(c),He(n,"class","a"),He(n,"data-test",a="scn_"+t[5].actionLabelGa)},m(a,c){Ne(a,e,c),Ne(a,n,c),Ee(n,s),i||(o=Ue(n,"click",t[19]),i=!0)},p(t,e){32&e[0]&&c!==(c=t[5].actionLabel+"")&&Ve(s,c),32&e[0]&&a!==(a="scn_"+t[5].actionLabelGa)&&He(n,"data-test",a)},d(t){t&&$e(e),t&&$e(n),i=!1,o()}}}function as(t){let e,n,s,a,i,o,c,r=t[6].text+"";return{c(){e=Oe("dt"),e.textContent=`${_("global.option")}`,n=Oe("dd"),s=Oe("button"),a=Me(r),He(s,"class","a"),He(s,"data-test",i="scn_"+t[6].actionLabelGa),He(n,"data-test","option")},m(i,r){Ne(i,e,r),Ne(i,n,r),Ee(n,s),Ee(s,a),o||(c=Ue(s,"click",t[20]),o=!0)},p(t,e){64&e[0]&&r!==(r=t[6].text+"")&&Ve(a,r),64&e[0]&&i!==(i="scn_"+t[6].actionLabelGa)&&He(s,"data-test",i)},d(t){t&&$e(e),t&&$e(n),o=!1,c()}}}function is(t){let e,n,s,a,i=t[10]&&os(t),o=t[12]>1&&cs(t);return{c(){e=Oe("div"),n=Oe("div"),i&&i.c(),s=We(),a=Oe("div"),o&&o.c(),He(e,"class","sve_toaster__footer")},m(t,c){Ne(t,e,c),Ee(e,n),i&&i.m(n,null),Ee(e,s),Ee(e,a),o&&o.m(a,null)},p(t,e){t[10]?i?i.p(t,e):(i=os(t),i.c(),i.m(n,null)):i&&(i.d(1),i=null),t[12]>1?o?o.p(t,e):(o=cs(t),o.c(),o.m(a,null)):o&&(o.d(1),o=null)},d(t){t&&$e(e),i&&i.d(),o&&o.d()}}}function os(t){let e,n,s,a,i,o,c,r,l,d,u;return{c(){e=Oe("span"),n=Me(t[10]),s=We(),a=Oe("kin-tooltip"),i=Oe("span"),i.innerHTML='<kin-icon name="icon-m-action-info" size="20"></kin-icon>',o=We(),c=Oe("div"),r=Oe("p"),r.textContent=`${_("detection.alertid.title")}`,l=We(),d=Oe("p"),d.textContent=`${_("detection.alertid.desc")}`,u=Oe("p"),He(e,"class","span -small -secondary"),He(i,"slot","tooltip-activator"),He(r,"class","p strong"),He(d,"class","p -secondary -small"),He(c,"slot","tooltip")},m(t,h){Ne(t,e,h),Ee(e,n),Ne(t,s,h),Ne(t,a,h),Ee(a,i),Ee(a,o),Ee(a,c),Ee(c,r),Ee(c,l),Ee(c,d),Ee(c,u)},p(t,e){1024&e[0]&&Ve(n,t[10])},d(t){t&&$e(e),t&&$e(s),t&&$e(a)}}}function cs(t){let e,n,s,a,i,o,c,r,l,d,u,h,p,m=t[11]+1+"";return{c(){e=Oe("span"),e.textContent=`${_("detection.more.detections")}`,n=We(),s=Oe("kin-button"),a=Oe("kin-icon"),i=We(),o=Me(m),c=Me("\n\t\t\t\t\t/\n\t\t\t\t\t"),r=Oe("kin-button"),l=Me(t[12]),d=We(),u=Oe("kin-icon"),He(e,"class","span -small -secondary"),je(a,"name","icon-s-controls-arrow-left"),je(a,"size","16"),je(a,"rtlflip","true"),je(s,"type","blank"),je(s,"size","small"),je(s,"class","sve_toaster__paginator g-margin-left--5"),je(u,"name","icon-s-controls-arrow-right"),je(u,"size","16"),je(u,"rtlflip","true"),je(r,"type","blank"),je(r,"size","small"),je(r,"class","sve_toaster__paginator")},m(m,f){Ne(m,e,f),Ne(m,n,f),Ne(m,s,f),Ee(s,a),Ee(s,i),Ee(s,o),Ne(m,c,f),Ne(m,r,f),Ee(r,l),Ee(r,d),Ee(r,u),h||(p=[Ue(s,"click",t[15]),Ue(r,"click",t[16])],h=!0)},p(t,e){2048&e[0]&&m!==(m=t[11]+1+"")&&Ve(o,m),4096&e[0]&&Ve(l,t[12])},d(t){t&&$e(e),t&&$e(n),t&&$e(s),t&&$e(c),t&&$e(r),h=!1,Ce(p)}}}function rs(t){let e,n,s,a,i,o,c,r,l,d,u,h,p,m,f,g,b,w,v,y,S,x,T=t[0].icon&&Rn(t),k=t[0].title&&En(t);const C=t[26].default,D=Ie(C,t,t[25],null);let A=t[0].text&&Nn(t);const P=[Fn,$n],I=[];function L(t,e){return null==t[0].ipmAction||t[3]?0:1}m=L(t),f=I[m]=P[m](t);let R=t[0].details&&t[0].details.length&&qn(t),E=(t[10]||t[12]>1)&&is(t);return{c(){e=Oe("div"),n=Oe("div"),s=Oe("h1"),s.innerHTML='<span class="logo -white -width-70"></span>',a=We(),i=Oe("div"),o=Oe("button"),r=We(),l=Oe("div"),T&&T.c(),d=We(),k&&k.c(),u=We(),D&&D.c(),h=We(),A&&A.c(),p=We(),f.c(),g=We(),R&&R.c(),w=We(),E&&E.c(),He(s,"class","nui_logo"),He(o,"class","nui_controls__item -close nui_caption_client g-cursor--pointer"),He(o,"title",c=_("global.closeModalWindow")),He(i,"class","nui_controls"),He(n,"class","nui_titlebar -toaster nui_caption"),He(l,"class",b="sve_toaster__main "+(t[0].color?"-"+t[0].color:"")),Ke(l,"-auto-v-scroll",t[9]),He(e,"class","sve_toaster -detection"),Ge(e,"width",t[1]+"px")},m(c,f){var b;Ne(c,e,f),Ee(e,n),Ee(n,s),Ee(n,a),Ee(n,i),Ee(i,o),Ee(e,r),Ee(e,l),T&&T.m(l,null),Ee(l,d),k&&k.m(l,null),Ee(l,u),D&&D.m(l,null),Ee(l,h),A&&A.m(l,null),Ee(l,p),I[m].m(l,null),Ee(l,g),R&&R.m(l,null),Ee(e,w),E&&E.m(e,null),y=!0,S||(x=[Ue(Pn,"keydown",t[14]),Ue(o,"click",t[17]),(b=v=t[22].call(null,e),b&&De(b.destroy)?b.destroy:xe)],S=!0)},p(t,n){t[0].icon?T?T.p(t,n):(T=Rn(t),T.c(),T.m(l,d)):T&&(T.d(1),T=null),t[0].title?k?k.p(t,n):(k=En(t),k.c(),k.m(l,u)):k&&(k.d(1),k=null),D&&D.p&&33554432&n[0]&&Re(D,C,t,t[25],n,null,null),t[0].text?A?A.p(t,n):(A=Nn(t),A.c(),A.m(l,p)):A&&(A.d(1),A=null);let s=m;m=L(t),m===s?I[m].p(t,n):(pn(),gn(I[s],1,1,(()=>{I[s]=null})),mn(),f=I[m],f?f.p(t,n):(f=I[m]=P[m](t),f.c()),fn(f,1),f.m(l,g)),t[0].details&&t[0].details.length?R?R.p(t,n):(R=qn(t),R.c(),R.m(l,null)):R&&(R.d(1),R=null),(!y||1&n[0]&&b!==(b="sve_toaster__main "+(t[0].color?"-"+t[0].color:"")))&&He(l,"class",b),513&n[0]&&Ke(l,"-auto-v-scroll",t[9]),t[10]||t[12]>1?E?E.p(t,n):(E=is(t),E.c(),E.m(e,null)):E&&(E.d(1),E=null),(!y||2&n[0])&&Ge(e,"width",t[1]+"px")},i(t){y||(fn(D,t),fn(f),y=!0)},o(t){gn(D,t),gn(f),y=!1},d(t){t&&$e(e),T&&T.d(),k&&k.d(),D&&D.d(t),A&&A.d(),I[m].d(),R&&R.d(),E&&E.d(),S=!1,Ce(x)}}}function ls(t,e,n){let{$$slots:s={},$$scope:i}=e;const o=Ye();let r,d,u,h,{windowWidth:p=600}=e,{config:m=null}=e,{windowClose:f=null}=e,g=!1,b=null,w=null,_=!1,v=!1,y=!1,S=!1,x=!1;function T(t=!1){const e=m&&m.closeResponse;f?f(e):(o("close",e),(t||E<=1)&&c.close())}function k(t){C(m.actions[t],t)}function C(t,e){const s=t.action&&t.action(),i=Date.now();if(w&&w(),null==s)D(t.nextConfig,i,t.minDuration);else{const a=1===e&&2===m.actions.length&&!m.hideSecondAction;t.status||0!==e&&!a?(n(5,d=t.status),n(6,u=t.option),n(4,v=!0)):n(7,y=!0),s.then((e=>{D(e,i,t.minDuration)})).catch((e=>{D(e,i,t.minDuration)}))}t.labelGa&&a.event("DetectionDialog","Click",t.labelGa)}function D(t,e,s){const a=Math.max(s-(Date.now()-e),0);if(b&&b(),a>0){const e=window.setTimeout((()=>{!t&&E>0?T():n(0,m=t),b&&b()}),a);b=()=>{window.clearTimeout(e),b=null}}else!t&&E>0?T():n(0,m=t)}function A(t){t?(n(4,v=m.progress),n(5,d=m.status),n(6,u=m.option),n(7,y=!1),function(){if(w&&w(),m.actions&&m.actions.length&&m.actions[0].countdown){n(8,h=m.actions[0].countdown);const t=window.setInterval((function(){h?n(8,h--,h):C(m.actions[0],0)}),1e3);w=function(){window.clearInterval(t),n(8,h=null),w=null}}}(),m.icon?(r="object"!=typeof m.icon?{name:m.icon}:Object.assign({},m.icon),r.name||(r.name="red"===m.color?"icon-s-controls-close":"icon-s-status-check"),r.bgName=r.bgName||"circle",!r.color&&m.color&&(r.color="red"===m.color?"critical":"ok")):r=null):T()}function P(t){x&&(x=!1,n(9,S=t.scrollHeight>window.screen.availHeight)),c.resize(p,Math.min(t.scrollHeight,window.screen.availHeight))}Je((()=>{l.play("threat")})),Xe((()=>{b&&b(),w&&w()}));let I,L,R,E,N;return t.$$set=t=>{"windowWidth"in t&&n(1,p=t.windowWidth),"config"in t&&n(0,m=t.config),"windowClose"in t&&n(23,f=t.windowClose),"$$scope"in t&&n(25,i=t.$$scope)},t.$$.update=()=>{1&t.$$.dirty[0]&&A(m),1&t.$$.dirty[0]&&function(t){const e=c.getUrlParams();null!=t&&a.view(e.module+"_"+e.view+(t?"_"+t:""))}(m&&m.trackerTitle),1&t.$$.dirty[0]&&n(24,I=m&&m.detectionInfo||{}),16777216&t.$$.dirty[0]&&n(10,L=I.id||""),16777216&t.$$.dirty[0]&&n(11,R=I.index||0),16777216&t.$$.dirty[0]&&n(12,E=I.total||0),16777216&t.$$.dirty[0]&&n(13,N=I.showCloseAllBtn||!1)},[m,p,g,_,v,d,u,y,h,S,L,R,E,N,function(t){const e=m.actions;e&&e.length&&e.some(((e,n)=>{if(e.shortcut&&e.shortcut.code===t.code&&!!e.shortcut.ctrlKey===t.ctrlKey&&!!e.shortcut.shiftKey===t.shiftKey&&!!e.shortcut.altKey===t.altKey&&!!e.shortcut.metaKey===t.metaKey)return C(e,n),!0}))},function(){o("prev")},function(){o("next")},function(){!function(t=!1){a.event("DetectionDialog","Close"),o("ignore"),T(t)}(!0)},function(){n(2,g=!g),x=!0},function(){const t=d.actionLabelGa,e=d.action;t&&a.event("DetectionDialog","Click",t),"function"==typeof e?e():console.error("[SvelteComponents] {DetectionDialog} StatusAction is not function")},function(){const t=u.actionLabelGa,e=u.action;t&&a.event("DetectionDialog","Click",t),"function"==typeof e?e():console.error("[SvelteComponents] {DetectionDialog} OptionAction is not function")},k,function(t){P(t);const e=new MutationObserver(P.bind(this,t));return e.observe(t,{attributes:!0,childList:!0,characterData:!0,subtree:!0}),{destroy:e.disconnect.bind(e)}},f,I,i,s,()=>k(0),()=>k(1),t=>k(t),t=>m.dontShowAgain.action(t.target.checked),()=>n(3,_=!0)]}class ds extends xn{constructor(t){super(),Sn(this,t,ls,rs,Ae,{windowWidth:1,config:0,windowClose:23},[-1,-1])}}var us="object"==typeof W&&W&&W.Object===Object&&W,hs="object"==typeof self&&self&&self.Object===Object&&self;us||hs||Function("return this")();const ps={FileSystemShield:{ask:{color:"red",title:"detection.threat.blocked",text:"detection.ask.text.FileSystemShield",actionText:"detection.whatToDo",actionButton:{action:"chest",label:"detection.action.chest",shortcut:{code:"KeyM",ctrlKey:!0},progressText:"detection.action.chest.progress",labelTest:"btn_chest"},anotherButton:[{action:"block",label:"detection.action.keepBlocking",shortcut:{code:"KeyB",ctrlKey:!0},labelTest:"btn_keepBlocking"},{action:"ignore",label:"detection.action.exception",shortcut:{code:"KeyE",ctrlKey:!0},progressText:"detection.action.exception.progress",labelTest:"btn_ignore"}],statusText:"detection.status.block"},auto:{color:"green",title:"detection.threat.secured",text:"detection.auto.text.FileSystemShield",actionText:"detection.scanPromo",actionButton:{action:"scan",shortcut:{code:"KeyS",ctrlKey:!0},label:"detection.action.scan",labelTest:"btn_scan"},statusText:"detection.status.chest"},exception:{color:"green",title:"detection.threat.exception",text:"detection.exception.text",actionText:"detection.noScan",actionButton:{action:"close",shortcut:{code:"KeyG",ctrlKey:!0},label:"detection.action.gotIt",labelTest:"btn_close"},statusText:"detection.status.exception"}},WebShield:{ask:{color:"red",title:"detection.threat.blocked",text:"detection.ask.text.WebShield",actionText:"detection.whatToDo",actionButton:{action:"abort",label:"detection.action.abortConnection",shortcut:{code:"KeyA",ctrlKey:!0},progressText:"detection.action.abortConnection.progress",labelTest:"btn_abort"},anotherButton:[{action:"ignore",label:"detection.action.exception",shortcut:{code:"KeyE",ctrlKey:!0},progressText:"detection.action.exception.progress",labelTest:"btn_ignore"}],statusText:"detection.status.connectionBlocked"},auto:{color:"green",title:"detection.threat.secured",text:"detection.auto.text.WebShield",actionText:"detection.scanPromo",actionButton:{action:"scan",shortcut:{code:"KeyS",ctrlKey:!0},label:"detection.action.scan",labelTest:"btn_scan"},statusText:"detection.status.abort"},exception:{color:"green",title:"detection.threat.exception",text:"detection.exception.text",actionText:"detection.noScan",actionButton:{action:"close",shortcut:{code:"KeyG",ctrlKey:!0},label:"detection.action.gotIt",labelTest:"btn_close"},statusText:"detection.status.exception"}},BehaviorShield:{ask:{color:"red",title:"detection.threat.blocked",text:"detection.ask.text.BehaviorShield",actionText:"detection.whatToDo",actionButton:{action:"chest",shortcut:{code:"KeyM",ctrlKey:!0},label:"detection.action.chest",labelTest:"btn_chest"},anotherButton:[{action:"ignore",shortcut:{code:"KeyE",ctrlKey:!0},label:"detection.action.exception",progressText:"detection.action.exception.progress",labelTest:"btn_ignore"}],statusText:"detection.status.block"},auto:{color:"green",title:"detection.threat.secured",text:"detection.auto.text.BehaviorShield",actionText:"detection.scanPromo",actionButton:{action:"scan",shortcut:{code:"KeyS",ctrlKey:!0},label:"detection.action.scan",labelTest:"btn_scan"},statusText:"detection.status.chest"},exception:{color:"green",title:"detection.threat.exception",text:"detection.exception.text",actionText:"detection.noScan",actionButton:{action:"close",shortcut:{code:"KeyG",ctrlKey:!0},label:"detection.action.gotIt",labelTest:"btn_close"},statusText:"detection.status.exception"}},EmailShield:{ask:{color:"red",title:"detection.threat.blocked",text:"detection.ask.text.EmailShield",actionText:"detection.whatToDo",actionButton:{action:"chest",label:"detection.action.chest",shortcut:{code:"KeyM",ctrlKey:!0},progressText:"detection.action.chest.progress",labelTest:"btn_chest"},anotherButton:[{action:"block",label:"detection.action.keepBlocking",shortcut:{code:"KeyB",ctrlKey:!0},labelTest:"btn_block"},{action:"ignore",label:"detection.action.allowDownload",shortcut:{code:"KeyE",ctrlKey:!0},labelTest:"btn_ignore"}],statusText:"detection.status.block"},auto:{color:"green",title:"detection.threat.secured",text:"detection.auto.text.EmailShield",actionText:"detection.scanPromo",actionButton:{action:"scan",shortcut:{code:"KeyS",ctrlKey:!0},label:"detection.action.scan",labelTest:"btn_scan"},statusText:"detection.status.chest"}}};const ms={FileSystemShield:{error:{name:"icon-m-scan-file",bgName:"shield",color:"critical"},ok:{name:"icon-s-status-check",bgName:"shield",color:"ok"}},WebShield:{error:{name:"icon-s-web",bgName:"shield",color:"critical"},ok:{name:"icon-s-status-check",bgName:"shield",color:"ok"}},BehaviorShield:{error:{name:"icon-m-behaviorshield",bgName:"shield",color:"critical"},ok:{name:"icon-s-status-check",bgName:"shield",color:"ok"}},EmailShield:{error:{name:"icon-m-email",bgName:"shield",color:"critical"},ok:{name:"icon-s-status-check",bgName:"shield",color:"ok"}}};const fs={detectionDialogActions:{"1B":{action:"detection.abtest.1b.action",text:"detection.abtest.1b.text",openElement:95},"1C":{action:"detection.abtest.1c.action",text:"detection.abtest.1c.text",openElement:95},"1D":{action:"detection.abtest.1d.action",text:"detection.abtest.1d.text",openElement:95},"1B2":{action:"detection.abtest.1b.action",text:"detection.abtest.1b.text",openElement:160,target:"overlay"},"1C2":{action:"detection.abtest.1c.action",text:"detection.abtest.1c.text",openElement:160,target:"overlay"},"1D2":{action:"detection.abtest.1d.action",text:"detection.abtest.1d.text",openElement:160,target:"overlay"}}};function gs(t){let e,n;return e=new ds({props:{config:t[0]}}),e.$on("prev",t[1]),e.$on("next",t[2]),e.$on("close",t[3]),{c(){wn(e.$$.fragment)},m(t,s){_n(e,t,s),n=!0},p(t,n){const s={};1&n&&(s.config=t[0]),e.$set(s)},i(t){n||(fn(e.$$.fragment,t),n=!0)},o(t){gn(e.$$.fragment,t),n=!1},d(t){vn(e,t)}}}function bs(t){let e,n,s=t[0]&&gs(t);return{c(){s&&s.c(),e=Be()},m(t,a){s&&s.m(t,a),Ne(t,e,a),n=!0},p(t,[n]){t[0]?s?(s.p(t,n),1&n&&fn(s,1)):(s=gs(t),s.c(),fn(s,1),s.m(e.parentNode,e)):s&&(pn(),gn(s,1,1,(()=>{s=null})),mn())},i(t){n||(fn(s),n=!0)},o(t){gn(s),n=!1},d(t){s&&s.d(t),t&&$e(e)}}}const ws=/[/|\\]/g,_s=/\|>|\|>|\|>/g;function vs(t,e){let n;if("WebShield"===e){const e=document.createElement("a");e.href=t,n=e.hostname||t.substring(0,60)}else n="EmailShield"===e?t.split(_s).pop():t.split(ws).pop();return n}function ys(t,e,i){const o=m.createLogger("scans.virusDetectionDialog"),r=c.getUrlParams(),l={FileSystemShield:_("shields.file"),WebShield:_("shields.web"),EmailShield:_("shields.email"),BehaviorShield:_("shields.behavior")};let d,u,h,f="",g={},b=[],w=0,v=null,y=!1;function S(t={}){return t.abTest?"fn"===t.type?function(){return"overlay"===t.abTest.target?n("app.utils.SendMainWindowEvent",{event:"nui.mainLayout.ipmOverlay",args:{id:t.abTest.openElement,params:t.params}}):p.openWindow(t.abTest.openElement,t.params)}:_(t.abTest[t.type]):t.original}function x(t){if(t.windowId!==r.windowId)return;const e=b.findIndex((e=>e.id===t.id));e>-1?(Object.assign(b[e],t),w===e&&D(t)):b.push(t),i(0,v=T())}function T(t=u.userAction){let e,n;if(o.info("getConfig"),e=g.askForAction?Object.assign({},ps[g.shield].ask):Object.assign({},ps[g.shield].auto),t&&"ignore"===t&&(e=Object.assign({},ps[g.shield].exception)),0===Object.keys(e).length)return;y&&"scan"===e.actionButton.action&&(e.actionText="detection.noScan",e.actionButton={action:"close",shortcut:{code:"KeyG",ctrlKey:!0},label:"detection.action.gotIt",labelTest:"btn_close"}),e.title=[`${e.title}.${g.severity}`,e.title],e.text=[`${e.text}.${g.severity}`,e.text],n="WebShield"===g.shield?t&&"ignore"===t?_(e.text,g.fileName):_(e.text,g.threatName,g.fileName):g.actionFailed?_("detection.auto.text.FileSystemShield.block",g.fileName,g.threatName):_(e.text,g.fileName,g.threatName);const s={color:e.color,icon:"red"===e.icon?ms[g.shield].error:ms[g.shield].ok,title:_(e.title),text:n,actionText:S({type:"text",abTest:g.abTest,original:e.actionText?_(e.actionText):""}),actions:[],hideSecondAction:!0,details:A(),abTest:g.abTest,ipmParams:g.ipmParams,status:{text:P(e)},detectionInfo:{id:(b[w]||{}).alertId||"",index:w,total:b.length,showCloseAllBtn:!b.some((t=>t.ask&&!t.userAction))}};return s.icon.color={green:"ok",ok:"ok",red:"critical",critical:"critical"}[e.color]||s.icon.color,t&&"ignore"===t&&(s.status.actionLabel=_("detection.threat.exception.openList"),s.status.action=k),e.actionButton&&("scan"===e.actionButton.action?s.actions.push({label:S({type:"action",abTest:g.abTest,original:_(e.actionButton.label)}),labelTest:e.actionButton.labelTest,labelGa:e.actionButton.action,action:S({type:"fn",abTest:g.abTest,original:L,params:g.ipmParams})}):"close"===e.actionButton.action?s.actions.push({label:_(e.actionButton.label),labelTest:e.actionButton.labelTest,labelGa:e.actionButton.action}):s.actions.push({label:_(e.actionButton.label),labelTest:e.actionButton.labelTest,action:()=>C(e.actionButton.action),status:{text:e.actionButton.progressText?_(e.actionButton.progressText):""},minDuration:1e3,labelGa:e.actionButton.action})),e.anotherButton&&e.anotherButton.forEach((t=>{s.actions.push({label:_(t.label),labelTest:t.labelTest,action:()=>C(t.action),status:{text:t.progressText?_(t.progressText):""},minDuration:1e3,labelGa:t.action})})),"chest"!==g.action||"WebShield"===g.shield||g.actionFailed||(s.status.actionLabel=_("scans.detection.openVirusChest"),s.status.action=I,s.status.actionLabelGa="openVirusChest"),"FileSystemShield"===g.shield&&(s.option={text:_("detection.option.reportFalsePositive"),action:R,actionLabelGa:"FalsePositive"}),s}function k(){return n("app.windowManager.ShowMainWindow",{route:"#Settings/exceptions"}).catch((t=>{o.error("[Virus Detection] show exceptions failed,",JSON.stringify(t))}))}function C(t){o.info("doAction: action = "+t),"scan"===t&&(y=!0);const e={id:h,data:{showAgain:!0,sendForAnalysis:!0}};return"ignore"===t&&(e.data.showAgain=!1),n("app.av.detections.Set",e).then((()=>n("app.av.detections.UserChoice",{id:h,userChoice:t}))).then((()=>{if("ignore"===t){let t="avcfg://exclusions/Global/ExcludeFiles";return"WebShield"===g.shield&&(t="avcfg://exclusions/Global/ExcludeUrls"),n("app.utils.AddExclusion",{property:t,exclusion:g.filePath})}})).catch((()=>n("virusDetection.SetFormValues",{action:t,submitForAnalysis:!0}))).then((()=>"block"===t?null:(g.action=t,g.askForAction=!1,i(7,u.action=t,u),i(7,u.userAction=t,u),i(7,u.ask=!1,u),T(t)))).catch((t=>{o.error("setting form values failed",t)}))}function D(t){const e={p_vir:t.name};o.info("data loaded");const n=_(["",`detection.threat.type.${t.severityID}.${t.typeID}`]);g={chestId:t.chestId,threatName:t.name,filePath:t.path,fileName:vs(t.path,t.shield),processPath:t.process,action:t.ask?"block":"chest",actionFailed:!t.action,actions:[],type:t.type,severity:t.severity,threatType:n||void 0,shield:t.shield,askForAction:t.ask,statusText:t.localizedAction,abTest:navigator.onLine?fs.detectionDialogActions[f]:null,ipmParams:e}}function A(){return o.info("getting details"),[{title:_("scans.threatName"),value:g.threatName,testValue:"threatName"},{title:_("global.threatType"),value:g.threatType,testValue:"threatType"},{title:"WebShield"===g.shield?_("global.url"):_("global.filePath"),value:g.filePath,testValue:"file"},{title:_("scans.detectionProcess"),value:g.processPath,testValue:"process"},{title:_("global.detectedBy"),value:l[g.shield],testValue:"detectedBy_"+g.shield}]}function P(t){return g.actionFailed?_("detection.status.block"):t.statusText?_(t.statusText):g.statusText}function I(){return n("app.settings.Get","avdef://config/GuiCache/MenuItemsDisabled").then((t=>t&&-1!=t.indexOf("viruschest")?n("av.command","show_chest"):n("app.windowManager.ShowMainWindow",{route:"#VirusChest"})))}function L(){return y=!0,n("app.windowManager.ShowMainWindow",{route:"#SmartScan"})}function R(){n("app.virusChest.GetStatus").then((t=>t.Items.find((t=>t.itemUID===g.chestId)))).then((t=>{let e;e=t?JSON.stringify([t]):JSON.stringify([{filePath:g.filePath}]),c.open({url:"https://"+location.host+"/MainWindow.html/?module=Feedback&view=analysis&threats="+encodeURIComponent(e)+"&analysisType=1",showTitlebar:!1})}))}function E(){i(6,w=Math.max(w-1,0)),D(b[w]),i(0,v=T())}return Je((()=>{o.info("oninit"),d=s.on("app.av.detections.onStatusChanged",x),n("app.smartScan.SendBurgerEvent",{event:"1.1.15.6"}),(o.info("loading data"),n("app.settings.Get","avdef://config/multidetections/enable").then((t=>{const e=[t,n("app.settings.Get","avdef://config/GuiCache/ABTest_DetectionDialog")];return t?e.push(n("app.av.detections.GetEntireStatus",{windowId:r.windowId}).catch((()=>n("virusDetection.GetFormValues")))):e.push(n("app.av.detections.GetStatus",{id:r.id}).catch((()=>n("virusDetection.GetFormValues")))),Promise.all(e)})).then((([t,e,n])=>{f=e;const s=t?n.detections[0]:n;t?i(5,b=n.detections):b.push(n),D(s)})).catch((t=>{o.error("getting status failed",t)}))).then((()=>{i(0,v=T()),c.init({width:600,height:420}),a.view("Scans_detection_"+g.shield)}))})),Xe((()=>{d&&d()})),t.$$.update=()=>{96&t.$$.dirty&&i(7,u=b&&b[w]||{}),128&t.$$.dirty&&(h=u.id||r.id)},[v,E,function(){i(6,w=Math.min(w+1,b.length-1)),D(b[w]),i(0,v=T())},function(){if(b.splice(w,1),0==b.length)return c.close();E()},!0,b,w,u]}class Ss extends xn{constructor(t){super(),Sn(this,t,ys,bs,Ae,{handlesWindowInit:4})}get handlesWindowInit(){return this.$$.ctx[4]}}const xs=m.createLogger("idp.detectionDialog");const Ts=m.createLogger("antirootkit.detectionDialog");const ks={error:{name:"icon-m-behaviorshield",bgName:"shield",color:"critical"},ok:{name:"icon-s-status-check",bgName:"shield",color:"ok"}},Cs=m.createLogger("scans.toasters.scanProgress"),Ds=t.components.Toaster.extend({windowClose:c.close,asyncLoad:!0,gaTrack:a,data:()=>({scanLabel:null,scanProgress:null,scanRunning:null,scanProblemsCount:null,buttonLabel:_("scans.toasters.scanProgress.buttonLabel"),buttonLabelGA:"Details",windowHeight:250}),computed:{text:function(){let t=null;const e=this.get("scanProblemsCount"),n=this.get("scanRunning");return n?t="<br/>"+_("scans.toasters.scanProgress.title.running",this.get("scanLabel")):!n&&e?t=_("scans.toasters.scanProgress.title.finished",this.get("scanLabel"))+"<br/>"+_("scans.toasters.scanProgress.text.issues",e):n||e||(t=_("scans.toasters.scanProgress.title.finished",this.get("scanLabel"))+"<br/>"+_("scans.toasters.scanProgress.text.noIssues")),t},severity:function(){let t=null;return this.get("scanProblemsCount")?t="danger":this.get("scanRunning")||(t="ok"),t},icon:function(){let t=null;return this.get("scanRunning")?t=null:this.get("scanProblemsCount")?t="circle-critical":this.get("scanProblemsCount")||(t="circle-ok"),t},progress:function(){return this.get("scanRunning")?this.get("scanProgress"):null}},oninit(){this._super(),this.trackedOnce=!1,this.scanId=this.get("params.scanId"),this.sessionId=this.get("params.sessionId"),Cs.info("oninit; scanId: "+this.scanId),this.on("doAction",this.openScanDetail.bind(this)),this.on("doAreaAction",this.openScanDetail.bind(this)),this.initScan().then((()=>{this.ready()})).catch((t=>{Cs.error("initializing scan ("+this.scanId+") failed",t),c.close({reason:c.CLOSE_REASONS.error})}))},initScan(){return n("app.scans.GetScanProps",{id:this.scanId}).then((t=>(Cs.info("scan data ("+this.scanId+") received"),Cs.debug("scan data: "+JSON.stringify(t)),this.scan=new E({id:this.scanId,type:t.scanType}),this.set("scanLabel",t.label),this.scan.getStatus(this.sessionId).then((t=>{this.updateData(t),this.scan.on("change",this.updateData.bind(this)),this.scan.startPolling(this.sessionId)})))))},updateData(t){Cs.debug("data: "+JSON.stringify(t));const e=t.status,n=this.scan.getData().type;if(!this.trackedOnce&&e!==C){const s=e===I?"done":"stopped";a.view("Scans/scan/"+n+"/"+s),a.event("Virus Scan","Number of Issues",n+"-"+t.problemsCount,"Scans/scan/"+n+"/"+s),this.trackedOnce=!0}this.set({scanRunning:e===C,scanProgress:t.progress,scanProblemsCount:t.problemsCount}),this.adjustWindowHeight&&setTimeout((()=>{this.adjustWindowHeight()}),10)},openScanDetail(){Cs.info("opening details"),n("app.windowManager.ShowMainWindow",{route:"Scans/scan/"+this.scanId+(null==this.sessionId?"":"/"+this.sessionId)}).then((function(){c.close({reason:c.CLOSE_REASONS.navigateToOtherWindow})})).catch((function(t){Cs.error("opening details failed",t)}))}});const As="avcfg://settings/Common/BootTimeScanAreas",Ps="avcfg://settings/Common/BootTimeScanPUP",Is=null==localStorage.newPup?d.isVersionSupported("21.1"):1==localStorage.newPup;function Ls(){const t={sensitivity:{id:"settings-scans-boottime-sensitivity",desc:_(he.sensitivity),path:"avcfg://settings/Common/BootTimeScanSensitivity",options:[{value:"40",label:_("settings.sensitivity.low")},{value:"80",label:_("settings.sensitivity.medium")},{value:"100",label:_("settings.sensitivity.high")}],track:{subject:"Sensitivity",valueMap:{40:"Low",80:"Medium",100:"High"}},search:he.sensitivity},scanPup:{id:"settings-scans-boottime-scanPup",label:_(he.scanPup),desc:_(he.scanPupDesc),path:Ps,load:null,change:null,changeEvent:"scan.boottime.scanPup",track:{subject:"Scan PUP"},search:{title:he.scanPup,desc:he.scanPupDesc}},scanPackers:{label:_(he.unpackArchives),path:"avcfg://settings/Common/BootTimeScanPackers",track:{subject:"Unpack archives"},search:he.unpackArchives},scanAreas:{id:"settings-scans-boottime-scanAreas",label:_(he.scanAreas.label),path:As,options:[{label:_(he.scanAreas.allHardDisks),value:"AllHarddisks"},{label:_(he.scanAreas.systemDisk),value:"SystemDisk",recommended:!0}],load:null,change:null,track:{subject:"Scan areas"},search:{title:he.scanAreas.label,others:[he.scanAreas.allHardDisks,he.scanAreas.systemDisk,he.scanAreas.startup]}},scanStartup:{id:"settings-scans-boottime-scanStartup",label:_(he.scanAreas.startup),load:null,change:null,track:{subject:"Scan auto start programs"},testAttr:null},useAutomaticActions:{id:"settings-scans-boottime-useAutomaticActions",label:_(he.useAutomaticActions),path:"avcfg://settings/Common/BootTimeScanDefaultAction",load:null,change:null,track:{subject:"Use automatic actions"},search:{title:he.useAutomaticActions,others:[he.actions.fix,he.actions.fixDesc,he.actions.chest,he.actions.delete]}},automaticActions:{id:"settings-scans-boottime-automaticActions",path:"avcfg://settings/Common/BootTimeScanDefaultAction",options:[{label:_(he.actions.fix),desc:_(he.actions.fixDesc),value:"fix",recommended:!0},{label:_(he.actions.chest),value:"chest"},{label:_(he.actions.delete),value:"delete"}],track:{subject:"Automatic action"}}};return Is&&Object.assign(t,{scanTools:{id:"settings-scans-boottime-scanTools",label:_(he.scanTools),desc:_(he.scanToolsDesc),load:null,change:null,updateOnEvent:"settings.change.scan.boottime.scanPup",track:{subject:"Scan Tools"},search:{title:he.scanTools,desc:he.scanToolsDesc}}}),t}const Rs=t.extend({template:{v:3,t:[{t:7,e:"div",f:[{t:7,e:"SettingsRange",a:{property:[{t:2,r:"properties.sensitivity"}]}}]}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanPup"}]},f:[{t:4,f:[{t:7,e:"div",a:{class:"settings__indent"},f:[{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanTools"}]},f:[]}]}],n:50,r:"scanToolsSupported"}]}," ",{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanPackers"}]}}," ",{t:7,e:"div",a:{class:"g-margin-top--20",id:[{t:2,r:"properties.scanAreas.id"},"__container"]},f:[{t:7,e:"SettingsRadio",a:{property:[{t:2,r:"properties.scanAreas"}]}}," ",{t:7,e:"div",a:{class:"g-margin-top--20"},f:[{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.scanStartup"}]}}]}]}," ",{t:7,e:"div",a:{class:"g-margin-top--20"},f:[{t:7,e:"SettingsCheckbox",a:{property:[{t:2,r:"properties.useAutomaticActions"}]},f:[{t:7,e:"div",a:{class:"settings__indent"},f:[{t:7,e:"SettingsRadio",a:{property:[{t:2,r:"properties.automaticActions"}]}}]}]}]}]},data:()=>({properties:null,scanToolsSupported:Is}),oninit(){this.observe("properties.scanPup.value",(t=>{this.set("properties.scanTools.disabled",!t)})),this.observe("properties.useAutomaticActions.value",(t=>{this.set("properties.automaticActions.disabled",!t)})),this.scan=new E({id:"{CC13CA7D-229B-4D0A-8D27-E26129CDDF10}",type:"boottime"});const t=Ls();t.scanPup.load=this.loadScanPup.bind(this),t.scanPup.change=this.changeScanPup.bind(this),t.scanTools&&(t.scanTools.load=this.loadScanTools.bind(this),t.scanTools.change=this.changeScanTools.bind(this)),t.scanAreas.load=this.loadScanArea.bind(this,["AllHarddisks","SystemDisk"]),t.scanAreas.change=this.changeScanArea.bind(this,["AllHarddisks","SystemDisk"]),t.scanStartup.load=this.loadScanArea.bind(this,"Startup"),t.scanStartup.change=this.changeScanArea.bind(this,"Startup"),t.scanStartup.testAttr=this.scan.getPropTestAttr("ScanAreas","Startup"),t.useAutomaticActions.load=this.loadUseAutomaticActions.bind(this),t.useAutomaticActions.change=this.changeUseAutomaticActions.bind(this),this.set("properties",t)},loadScanPup:()=>h.get(Ps).then((t=>({locked:t.locked,value:t.value>0}))),changeScanPup:t=>h.set(Ps,t?1:0),loadScanTools:()=>h.get(Ps).then((t=>({locked:t.locked,value:2==t.value}))),changeScanTools:t=>h.set(Ps,t?2:1),loadScanAreas(t){return this.loadScanAreasPromise&&!t||(this.loadScanAreasPromise=h.get(As).then((t=>(this.scanAreas={locked:t.locked,areas:{}},t.value.replace(/"/g,"").split(";").forEach((t=>{this.scanAreas.areas[t]=!0})),delete this.loadScanAreasPromise,this.scanAreas)))),this.loadScanAreasPromise},changeScanAreas(){const t=Object.keys(this.scanAreas.areas).map((t=>'"'+t+'"')).join(";");return h.set(As,t)},loadScanArea(t,e){return this.loadScanAreas(e).then((e=>{let n;return n=Array.isArray(t)?t.find((t=>e.areas[t])):Boolean(e.areas[t]),{locked:e.locked,value:n}}))},changeScanArea(t,e){return Array.isArray(t)?t.forEach((t=>{t===e?this.scanAreas.areas[t]=!0:delete this.scanAreas.areas[t]})):e?this.scanAreas.areas[t]=!0:delete this.scanAreas.areas[t],this.changeScanAreas()},loadUseAutomaticActions(){const t=this.get("properties.automaticActions");return h.get(t.path).then((t=>({locked:t.locked,value:"ask"!==t.value})))},changeUseAutomaticActions(t){return h.set(this.get("properties.useAutomaticActions.path"),t?"fix":"ask")}}),Es={fullScan:{id:"settings-scans-full",type:"tab",title:_(he.scans.full),hash:"Settings/Scans/full",compo:ge,compoParams:{scanId:"{7C4966F0-D502-412D-A636-ACCC39A24BB2}",scanType:"full"},testAttr:"full",search:{title:he.scans.full,subroute:"full",items:fe("full")}},folderScan:{id:"settings-scans-folder",type:"tab",title:_(he.scans.folder),hash:"Settings/Scans/folder",compo:ge,compoParams:{scanId:"{C6156735-F7A2-4387-94A7-0479004A7310}",scanType:"folder"},testAttr:"folder",search:{title:he.scans.folder,subroute:"folder",items:fe("folder")}},explorerScan:{id:"settings-scans-explorer",type:"tab",title:_(he.scans.explorer),hash:"Settings/Scans/explorer",compo:ge,compoParams:{scanId:"{2243A056-84B3-4327-8E46-5FE41F72EE91}",scanType:"explorer"},testAttr:"explorer",search:{title:he.scans.explorer,subroute:"explorer",items:fe("explorer")}},boottimeScan:{id:"settings-scans-boottime",type:"tab",title:_(he.scans.boottime),hash:"Settings/Scans/boottime",compo:Rs,testAttr:"boottime",search:{title:he.scans.boottime,subroute:"boottime",items:Ls()}}},Ns={title:he.title,desc:he.desc,subpages:[Es.fullScan,Es.folderScan,Es.explorerScan,Es.boottimeScan]},$s=t.extend({template:{v:3,t:[{t:7,e:"SettingsContainer",a:{noInstall:"true",noEnable:"true",title:[{t:3,x:{r:["nls","STRINGS.title"],s:"_0(_1)"}}],desc:[{t:3,x:{r:["nls","STRINGS.desc"],s:"_0(_1)"}}]},f:[{t:7,e:"SettingsTabs",a:{tabs:[{t:2,r:"tabs"}],selectedTabId:[{t:2,r:"selectedTabId"}]}}]}]},router:new b,data:()=>({STRINGS:he,selectedTabId:null,tabs:[Es.fullScan,Es.folderScan,Es.explorerScan,Es.boottimeScan]}),oninit(){this.router.on("/",this.handleRoute.bind(this)),this.router.on("/:scan",this.handleRoute.bind(this))},onteardown(){this.router.removeAllListeners()},handleRoute(t){t&&t.scan?this.set("selectedTabId","settings-scans-"+t.scan):window.location.hash=this.get("tabs.0.hash")}}),Fs=[{label:_("geek.scan.full"),id:"{7C4966F0-D502-412D-A636-ACCC39A24BB2}"},{label:_("geek.scan.targeted"),id:"{C6156735-F7A2-4387-94A7-0479004A7310}"},{label:"Explorer Scan",id:"{2243A056-84B3-4327-8E46-5FE41F72EE91}"},{label:_("geek.scan.quick"),id:"{EC4ECEDA-3E3B-4027-ABFE-29A5122D64D6}"}],Os=[{label:"Automatic action to be performed during the scan",path:{name:"avcfg://settings/***TaskGUID***/VirusAction"},type:"select",options:[{label:"Fix automatically",value:"fix"},{label:_("geek.move.to.chest"),value:"trezor"},{label:"Repair",value:"repair"},{label:"Abort connection",value:"abort"},{label:"Ask",value:"interactive"},{label:"Delete",value:"delete"},{label:"Nothing",value:""}]},{label:"Processing of infected archives",path:{name:"avcfg://settings/***TaskGUID***/ActionOnPackedFile"},type:"select",options:[{label:"Try to remove only the packed file from the archive; if it fails, do nothing",value:"onlyfile"},{label:"Try to remove only the packed file; if it fails, remove the whole containing archive",value:"filearchive"},{label:"Always remove the whole archive",value:"wholearchive"}]},{label:"Speed up scanning by using persistent cache",desc:"This option will increase the scan speed by consulting the persistent cache before scanning each file.",path:{name:"avcfg://settings/***TaskGUID***/ConsultUsn"},type:"checkbox"},{label:"Store data about scanned files in the persistent cache",desc:"This option tells the engine to populate the persistent cache during the scan. Turning this option on will slow down the scan.",path:{name:"avcfg://settings/***TaskGUID***/PopulateUsn"},type:"checkbox"},{label:"Speed up scanning by reading files in the order they are stored on the disk",desc:"This option will tell the engine to scan files in the order they are actually stored on the disk. This minimizes the number of seek operations the drive has to make which usually speeds up the whole scan. This option is only effective on NTFS volumes.",path:{name:"avcfg://settings/***TaskGUID***/ScanFilesOrdered"},type:"checkbox"},{label:"Report file name",path:{name:"avcfg://settings/***TaskGUID***/ReportName"},type:"text"},{label:"Report file type",path:{name:"avcfg://settings/***TaskGUID***/Report"},type:"select",options:[{label:"Plain text (ANSI)",value:"TXT"},{label:"Plain text (Unicode)",value:"UTXT"},{label:"XML",value:"XML"}]},{label:"If report file exists",path:{name:"avcfg://settings/***TaskGUID***/OverwriteReport"},type:"select",options:[{label:"Append",value:"0"},{label:"Overwrite",value:"1"}]},{label:"Reported items",desc:"Possible values: Infected, HardErrors, SoftErrors, OK, Skipped. Values are separated by semicolon (e.g. OK;Skipped). There may be also values Start and Stop but they have no effect.",path:{name:"avcfg://settings/***TaskGUID***/ReportRecords"},type:"text"}],Ms=[{label:"Do not start the scan if running on batteries",path:{name:"avcfg://settings/***TaskGUID***/DoNotStartOnBatteries"},type:"checkbox"},{label:"Pause the scan if batteries mode begins",path:{name:"avcfg://settings/***TaskGUID***/PauseOnBatteries"},type:"checkbox"}],Ws=[{label:"Boot-Time Scan: Automatic action to be performed during the scan",path:"avcfg://settings/Common/BootTimeScanDefaultAction",type:"select",options:[{label:"Auto",value:"fix"},{label:_("geek.move.to.chest"),value:"chest"},{label:"Repair",value:"repair"},{label:"Ask",value:"ask"},{label:"Delete",value:"delete"},{label:"Nothing",value:"ignore"}]},{path:"avcfg://settings/Scanner/RawBootTimeScan",label:_("geek.scan.raw.boottime.label"),desc:"Without the raw disk access, the Boot-Time Scan will not be able to detect some rootkits.",type:"checkbox"},{path:"avcfg://settings/Scanner/SkipSignatureChecks",label:"Skip checking of digital signatures of infected files",desc:"The information from digital signatures can be used to prevent false alarms.",type:"checkbox"},{path:"avcfg://settings/Common/CleanUpScanLogs",label:"Delete scan logs",type:"checkbox"},{path:"avcfg://settings/UserInterface/AutoDelete",label:"Delete scan logs older than",type:"number",minValue:0,unit:"days"},{path:"avcfg://settings/Common/CleanUpScanLogsTemp",label:"Delete temporary scan logs",type:"checkbox"},{path:"avcfg://settings/Common/AutoDeleteSessions",label:"Delete temporary scan logs older than",type:"number",minValue:0,unit:"days"},{id:"scans_cleanHistory",label:"Clean scan history",type:"button",action:n.bind(null,"app.scans.CleanHistory")}];function Bs(){return n("app.scanViruses.GetScans").then((t=>{const e=t.filter((t=>"custom"===t.type)),n=Fs.concat(e),s=[];return n.forEach((t=>{let e;e="custom"===t.type?Os.concat(Ms):Os,e.forEach((e=>{const n=w({},e);n.label=t.label+": "+n.label,n.path.objectId=t.id,s.push(n)}))})),s.concat(Ws)})).catch((t=>(console.error("loading scans to get all scan geek properties failed",t),Ws)))}const Us=function(e){return t.extend({router:new b,template:Yt,css:".scn {\n text-align: var(--page-header-align);\n}\n.scn .scn_nowrap {\n white-space: nowrap;\n}\n.scn.-overlay {\n text-align: initial;\n}\n.scn_icon {\n font-size: 80px;\n margin-bottom: 4vh;\n margin-top: 1vh;\n}\n.scn_cta {\n margin-top: 4vh;\n height: 50px;\n}\n.scn_cta__progress {\n max-width: 300px;\n margin: 5px auto 8px;\n}\n.scn_cta__finished {\n position: relative;\n top: -5px;\n}\n.scn_header__border {\n width: 1px;\n background-color: rgba(255,255,255,0.3);\n display: inline-block;\n height: 15px;\n vertical-align: middle;\n}\n.scn .scn_count {\n margin: 5px 5px 0 0;\n background: rgba(255,255,255,0.7);\n color: #353f59;\n position: absolute;\n top: 3px;\n right: 3px;\n}\n.scn .scn_settings {\n margin-top: 8px;\n}\n.scn .scn_settings__btn {\n margin: 0 16px;\n}\n.scn .scn_settings_schedule_flex {\n display: flex;\n justify-content: flex-start;\n}\n.scn .scn_settings_schedule_inputInRow {\n display: flex;\n flex-direction: column;\n padding-right: 1rem;\n justify-content: flex-end;\n}\n.scn_settings_info_flex {\n display: flex;\n flex-flow: row nowrap;\n align-items: center;\n}\n.scn_scheduled {\n position: absolute;\n margin-left: -8px;\n opacity: 0.5;\n}\n.scn_table__name {\n width: 40%;\n}\n.scn_table__name.-pane {\n width: auto;\n padding-top: 10px;\n padding-bottom: 18px;\n}\n.scn_table__name.-pane dd {\n margin: 0;\n padding-left: 4px;\n}\n.scn_custom__row {\n grid-template-columns: 30% 45% 20% 5%;\n}\n.scn_history__row {\n grid-template-columns: 6% 30% 49% 15%;\n}\n.scn_history__row .scn_history__report {\n position: absolute;\n right: 0.5rem;\n bottom: 1rem;\n}\n.scn_boot-time__cta {\n min-height: 6rem;\n display: flex;\n flex-flow: column;\n justify-content: flex-end;\n}\n.scn_boot-time__desc {\n width: 46rem;\n}\n.scn_install {\n background-color: rgba(255,255,255,0.05);\n padding: 1rem 4rem;\n margin: 5rem 0;\n box-shadow: 0 0 90px -10px rgba(0,0,0,0.2);\n border-radius: 1.2rem;\n display: flex;\n width: 80%;\n flex-flow: column;\n justify-content: center;\n align-items: center;\n min-height: 16rem;\n}\n.stg__tooltip {\n max-width: 500px;\n}\n.stg_language__row {\n text-align: start;\n padding: 8px;\n margin: 0 20px;\n border-top: 1px solid rgba(255,255,255,0.15);\n}\n.stg_update__row {\n min-height: 6.5rem;\n border-bottom: solid 1px transparent;\n}\n.stg_update__form {\n margin-top: 1rem;\n}\n.stg_update__form .input__label.-inline {\n width: 20%;\n}\n.stg_update__form .input {\n width: 79%;\n}\n.stg_geek__field {\n position: relative;\n}\n.stg_geek__field input[type='text'],\n.stg_geek__field input[type='number'],\n.stg_geek__field select {\n width: 100%;\n}\n.stg_item__disabled {\n pointer-events: none;\n opacity: 0.5;\n}\n.-disabled {\n pointer-events: none;\n opacity: 0.3;\n}\n[dir=rtl] .scn .scn_settings_schedule_inputInRow {\n padding-right: 0;\n padding-left: 1rem;\n}\n[dir=rtl] .scn_history__row .scn_history__report {\n left: 0.5rem;\n right: initial;\n}\n.kin_table__header.-threatslist,\n.kin_table__row.-threatslist {\n grid-template-columns: 6% 25% 44% 25%;\n}\n.scn_sub-icon {\n position: absolute;\n top: 2.2rem;\n left: 2.2rem;\n}\n",components:{Main:ae,Scan:ie,CustomScans:ue,CustomScanSettings:ve,ScanHistory:ye,Performance:Se},partials:{Main:"<Main />",CustomScans:"<CustomScans />",ScanHistory:"<ScanHistory />",Performance:"<Performance />"},data:()=>({initialized:!1,page:null,overlay:null,getPage:function(){return this.get("page")},getOverlay:function(){return this.get("overlay")}}),oninit(){$.setBrandedComponents(e),this.components.BoottimeScan=$.getBrandedComponent("BoottimeScan"),this.router.on("/",this._handleRoute.bind(this)),this.router.on("/:level1",this._handleRoute.bind(this)),this.router.on("/:level1/:level2",this._handleRoute.bind(this)),this.router.on("/:level1/:level2/:level3",this._handleRoute.bind(this)),this.router.on("/:level1/:level2/path/:path",this._handleRoute.bind(this)),this.router.on("/:level1/:level2/:level3/path/:path",this._handleRoute.bind(this)),this.on("Overlay.close CustomScanSettings.close",(()=>{window.location.hash=this.lastPageHash||"#Scans/customScans"}))},onteardown(){this.router.removeAllListeners()},_handleRoute(t){let e,n,s;switch(t&&t.level1&&t.level1.toLowerCase()){case"scan":s="Scan"+t.level2+(t.level3?"-"+t.level3:"")+(t.path?"-"+t.path:""),e=this._makePartial(s,"<Scan scanId="+t.level2+" sessionId="+t.level3+" path="+t.path+" />");break;case"boottimescan":e=this._makePartial("BoottimeScan","<BoottimeScan scanId="+(t.level2||"boottime")+" />");break;case"customscans":t.level2&&"settings"===t.level3?n=this._makePartial("CustomScanSettings"+t.level2,"<CustomScanSettings scanId="+t.level2+" />"):e="CustomScans";break;case"scanhistory":e=t.level2&&t.level3?this._makePartial("ScanHistory"+t.level2+t.level3,"<ScanHistory scanId="+t.level2+" sessionId="+t.level3+" />"):"ScanHistory";break;case"performance":e="Performance";break;default:e="Main"}e&&(this.lastPageHash=window.location.hash,this.set("page",e)),this.set("overlay",n),this.set("initialized",!0)},_makePartial(t,e){return this.partials[t]||(this.partials[t]=e),t}})}(Xt),Hs=function(e){return t.components.DetectionDialog.extend({windowClose:function(){c.close()},asyncLoad:!0,gaTrack:a,oninit(){this._super(),xs.info("oninit"),this._data={},this.loadData().then((t=>{void 0!==t.errorCode?this.set("config",this.getDoneConfig("block",t)):this.set("config",this.getConfig()),setTimeout(this.ready.bind(this),0)}))},_setData(t){this._data.processName=t.processName,this._data.targetFile=t.targetFile,this._data.infectionTranslated=this._getInfectionTranslated(t.infection),this._data.showAction=t.showAction,this._data.restoreAvailable=t.restoreAvailable},loadData(){return xs.info("loadData"),n("app.av.detections.GetStatus",{id:this.get("params.id")}).catch((()=>n("app.idpDetection.GetStatus",{id:this.get("params.id")}))).then((t=>(this._setData(t),t)))},getConfig(){xs.info("getConfig");const t={hideTitlebarClose:this._data.showAction,color:this._data.showAction?"red":"green",icon:this._data.showAction?e.error:e.ok,actions:[],hideSecondAction:!0,details:this.getDetails()};return this._data.showAction?(t.title=_("scans.detection.action.block.title"),t.text=_("scans.idp.detection.text",this._fileName(),this._data.infectionTranslated),t.actionText=_("scans.detection.whatWouldYouLikeToDo"),t.actions=[{label:_("scans.detection.action.chest.label"),labelTest:"btn_chest",action:this.doUserAction.bind(this,"block"),status:{text:_("scans.detection.action.chest.progressText")},shortcut:{code:"KeyM",ctrlKey:!0},minDuration:2e3},{label:_("scans.idp.action.allow.label"),labelTest:"btn_ignore",action:this.doUserAction.bind(this,"allow"),status:{text:_("scans.detection.action.ignore.progressText")},cssCls:"-critical",shortcut:{code:"KeyE",ctrlKey:!0},minDuration:2e3}]):(t.title=_("scans.detection.action.chest.title"),this._data.restoreAvailable?t.text=_("scans.detection.action.chest.resultText",this._fileName(),this._data.infectionTranslated):t.text=_("detection.auto.text.FileSystemShield.block",this._fileName(),this._data.infectionTranslated),t.actionText=_("scans.detection.scanPromo"),t.actions=[{label:_("scans.detection.action.scan.label"),labelTest:"btn_scan",shortcut:{code:"KeyS",ctrlKey:!0},action:function(){return n("app.smartScan.GetStatus").then((t=>{if("scanning"!==t.statusPrimary)return n("app.windowManager.ShowMainWindow",{route:"#SmartScan"}).then((()=>{c.close()}))}))}}],this._data.restoreAvailable?t.status={text:_("detection.status.chest"),actionLabel:_("scans.detection.openVirusChest"),action:this.openVirusChest.bind(this)}:t.status={text:_("detection.status.block")}),t},openVirusChest:()=>c.openMainWindow({route:"#VirusChest"}).then((()=>{c.close()})),openExceptionList:()=>n("app.windowManager.ShowMainWindow",{route:"#Settings/exceptions"}).then((()=>c.close())).catch((t=>{xs.error("[BehaviorShield Detection] show exceptions failed,",JSON.stringify(t))})),getDetails(){return[{title:_("scans.threatName"),value:this._data.infectionTranslated,testValue:"threatName"},{title:_("global.filePath"),value:this._data.targetFile,testValue:"filePath"},{title:_("scans.detectionProcess"),value:this._data.processName,testValue:"process"},{title:_("global.detectedBy"),value:_("shields.behavior"),testValue:"detectedBy_BehaviorShield"}]},getDoneConfig(t,s){xs.info("getDoneConfig");const a=this.getConfig();return a.hideTitlebarClose=!1,!0===s.restartRequired?(a.color="red",a.icon=e.error,a.title=_("scans.detection.restart.title"),a.text=_("scans.detection.restart.text",this._fileName()),a.actionText=_("scans.detection.restart.actionText"),a.actions=[{label:_("scans.detection.restart.actionLabel"),labelTest:"btn_restart",shortcut:{code:"KeyR",ctrlKey:!0},action:function(){return n("app.system.Restart",{rebootType:"RebootFromUI"}).then((()=>{c.close()}))}}]):0!==s.errorCode?(a.color="red",a.icon=e.error,a.title=_("scans.detection.not.removed.title"),a.text=_("scans.detection.not.removed.text",this._fileName()),a.actionText=_("scans.detection.not.removed.actionText"),a.actions=[{label:_("scans.detection.action.scan.label"),labelTest:"btn_scan",shortcut:{code:"KeyS",ctrlKey:!0},action:function(){return n("app.windowManager.ShowMainWindow",{route:"Scans/scan/{7C4966F0-D502-412D-A636-ACCC39A24BB2}"}).then((()=>{c.close()}))}}]):"allow"===t?(a.title=_("scans.detection.action.ignore.title"),a.text=_("scans.detection.action.ignore.text",this._fileName()),a.actionText=_("scans.detection.action.ignore.actionText"),a.color="green",a.icon=e.ok,a.actions=[{label:_("global.gotIt"),labelTest:"global.gotIt",cssCls:"",shortcut:{code:"KeyG",ctrlKey:!0},minDuration:500}],a.status={text:_("detection.threat.exception.moved"),actionLabel:_("detection.threat.exception.openList"),action:this.openExceptionList.bind(this)}):(a.color="green",a.icon=e.ok,a.title=_("scans.detection.action.chest.title"),this._data.restoreAvailable?a.text=_("scans.detection.action.chest.resultText",this._fileName(),this._data.infectionTranslated):a.text=_("detection.auto.text.FileSystemShield.block",this._fileName(),this._data.infectionTranslated),a.actionText=_("scans.detection.scanPromo"),a.actions=[{label:_("scans.detection.action.scan.label"),labelTest:"btn_scan",shortcut:{code:"KeyS",ctrlKey:!0},action:function(){return n("app.smartScan.GetStatus").then((t=>{if("scanning"!==t.statusPrimary)return n("app.windowManager.ShowMainWindow",{route:"#SmartScan"}).then((()=>{c.close()}))}))}}],this._data.restoreAvailable?a.status={text:_("detection.status.chest"),actionLabel:_("scans.detection.openVirusChest"),action:this.openVirusChest.bind(this)}:a.status={text:_("detection.status.block")}),a},doUserAction(t){return new Promise(((e,a)=>{this._cancelListener1=function(){},this._cancelListener2=function(){};this._cancelListener1=s.on("app.av.detections.onStatusChanged",(n=>{this.get("params.id")!==n.id||"resolved"!==n.state&&"removed"!==n.state||(this._cancelListener1(),this._cancelListener2(),this._setData(n),e(this.getDoneConfig(t,n)))})),this._cancelListener2=s.on("app.idpDetection.onStatusChanged",(n=>{(this.get("params.id")===n.id&&"resolved"===n.state||n.removedDetection===+this.get("params.id"))&&(this._cancelListener1(),this._cancelListener2(),"resolved"===n.state?this._setData(n):((n=this._data).errorCode=0,n.restartRequired=!1,n.state="resolved",n.id=n.removedDetection),e(this.getDoneConfig(t,n)))})),n("app.av.detections.UserChoice",{id:this.get("params.id"),userChoice:t}).catch((()=>{n("app.idpDetection.UserChoice",{id:this.get("params.id"),userChoice:t}).catch((t=>{xs.error("app.av.detections.UserChoice failed with error"+t),a(t)}))}))}))},_trimLongText:t=>t.slice(0,30)+(t.length>30?"...":""),_getInfectionTranslated(t){const e="%s_cmd";return t.includes(e)&&(t=t.replace(e,""),t=_("scans.idp.detection.commandLineDetection",t)),t},_fileName(){const t=this._data.targetFile||this._data.processName;return t?f.escapeHtml(this._trimLongText(t.split(/[/|\\]/g).pop())):""}})}(ks),js=function(e){return t.components.DetectionDialog.extend({windowClose:function(){this._actionTriggered?c.close():this._windowCloseSendIgnoreAction()},asyncLoad:!0,gaTrack:a,oninit(){this._super(),Ts.info("oninit"),this._cancelListener1=function(){},this._cancelListener2=function(){},this._status={},this._dialogType="",this._actionTriggered=!1,n("app.av.detections.GetStatus",{id:this.get("params.id")}).catch((()=>n("app.rootkitDetection.GetStatus",{id:this.get("params.id")}))).then((t=>{"show"===t.state?(this._setStatus(t),this._setDialogType(t),this.set("config",this.getConfig())):c.close(),Ts.debug("config set",this.get("config")),setTimeout(this.ready.bind(this),0)})).catch((t=>{Ts.error("Loading status failed",t)}))},_setStatus(t){this._status=t},_setDialogType(t){this._dialogType=t.data[0].type},_getRootkitConfig(){const t=this._status.data.length,n=_("scans.antiRootkit"),s=[],a=this._getFileName(this._status.data[0].file);let i="";Array.isArray(this._status.data)&&this._status.data.length&&(i=this._status.data.map((t=>t.file)));const o=[{title:_("scans.threatName"),value:this._status.data[0].virus},{title:_("global.filePath"),value:i},{title:_("global.detectedBy"),value:n}];let c;return this._status.showSendForAnalysis&&(s.push({type:"checkbox",title:_("global.options"),label:_("scans.detection.action.sendToAnalyse"),valueName:"sendForAnalysis"}),this.set({sendForAnalysis:!0})),c=t>1?this._getBoldValue(a)+" "+_("scans.antirootkit.detection.rootkit.moreFiles.desc",t-1):_("scans.antirootkit.detection.rootkit.desc",a),{icon:e.error,color:"red",title:_("scans.antirootkit.detection.rootkit.title",t),text:c,actionText:_("scans.detection.whatWouldYouLikeToDo"),actions:[{label:_("global.delete"),action:this.doAction.bind(this,"delete"),minDuration:2e3,status:{text:_("detection.action.exception.deleting")},labelTest:"btn_delete"},{label:_("detection.action.ignoreForNow"),action:this.doAction.bind(this,"ignore"),labelTest:"btn_ignoreForNow"},{label:_("scans.detection.action.ignore.label"),action:this.doAction.bind(this,"createException"),minDuration:2e3,status:{text:_("detection.action.exception.progress")},labelTest:"btn_createException"}],details:o,status:{text:_("global.detected")},formItems:s}},_getArpotConfig(){const t=this._getOriginPaths(this._status.data[0].origin),n=this._status.data[0].virus,s=this._getFileName(this._status.data[0].file),a=[{title:_("scans.threatName"),value:n,testValue:"threatName"},{title:_("global.filePath"),value:this._status.data[0].file,testValue:"file"},{title:_("scans.antirootkit.detection.origin"),value:t},{title:_("global.detectedBy"),value:_("scans.antiExploit"),testValue:"detectedBy_AntiExploitShield"}];return{icon:e.ok,color:"green",title:_("detection.threat.secured"),text:n?_("scans.antirootkit.detection.arpot.desc",s,n):_("scans.antirootkit.detection.arpot.noVirus.desc",s),actionText:_("scans.detection.whatWouldYouLikeToDo"),actions:[{label:_("scans.detection.action.scan.label"),action:()=>{this.runSmartScan()},labelTest:"btn_scan"}],details:a,status:{text:_("global.detected")}}},getConfig(){switch(Ts.info("getConfig: status",this._status),this._dialogType){case"rootkit":case"susp":return this._getRootkitConfig();case"arpot":return this._getArpotConfig()}},_getBoldValue:t=>"<strong>"+t+"</strong>",_getOriginPaths(t){const e=[];for(let n of t.split("\n"))n=this._trimLongText(n,256),e.push(n);return e.join("<br>")},_trimLongText:(t,e)=>t.slice(0,e)+(t.length>e?"...":""),_getFileName:t=>t.split(/[/|\\]/g).pop(),getDoneConfig(t,n){Ts.info("getDoneConfig: status",this._status);const s=this._getFileName(this._status.data[0].file),a=this._status.data.length,i="rootkit"===this._dialogType,o={icon:e.ok,color:"green",formItems:null};if(0!==n)o.color="red",o.title=_("scans.detection.not.removed.title"),o.text=_("scans.detection.not.removed.text.short",s),o.actionText=_("scans.detection.not.removed.actionText"),o.actions=[{label:_("scans.detection.action.scan.label"),action:()=>{i?this.runBoottimeScan():this.runSmartScan()},labelTest:"btn_scan"}];else switch(t){case"createException":o.title=_("scans.detection.action.ignore.title"),o.text=a>1?_("scans.antirootkit.detection.rootkit.moreFiles.movedToExceptionList1",s)+_("scans.antirootkit.detection.rootkit.moreFiles.movedToExceptionList2",a-1):_("scans.antirootkit.detection.rootkit.movedToExceptionList",s),o.status={text:_("scans.detection.action.ignore.title")},o.actionText=_("scans.antirootkit.detection.rootkit.movedToExceptionList.actionText",a),o.actions=[{label:_("global.gotIt"),labelTest:"btn_close"}];break;case"delete":o.title=_("scans.antirootkit.detection.rootkit.title.deleted",a),o.text=a>1?_("scans.antirootkit.detection.rootkit.moreFiles.deleted1",s)+" "+_("scans.antirootkit.detection.rootkit.moreFiles.deleted2",a-1):_("scans.antirootkit.detection.rootkit.deleted",s),o.status={text:_("global.deleted")},o.actionText=_("scans.detection.scanPromo"),o.actions=[{label:_("scans.detection.action.scan.label"),action:()=>{i?this.runBoottimeScan():this.runSmartScan()},labelTest:"btn_scan"}]}if(this.get("sendForAnalysis")){const t=[];t.push({type:"label",title:_("global.options"),label:_("scans.antirootkit.detection.sentForAnalysis"),valueName:"sendForAnalysis"}),o.formItems=t}return o},_windowCloseSendIgnoreAction(){this.doAction("ignore").then((()=>{c.close()})).catch((()=>{c.close()}))},runSmartScan(){return n("app.windowManager.ShowMainWindow",{route:"#SmartScan"}).then((()=>{this._windowCloseSendIgnoreAction()}))},runBoottimeScan(){return n("app.windowManager.ShowMainWindow",{route:"Scans/boottimeScan"}).then((()=>{this._windowCloseSendIgnoreAction()}))},doAction(t){return new Promise(((e,a)=>{const i=t,o={id:this.get("params.id"),data:{showAgain:!0}};"createException"===t&&(t="ignore",o.data.showAgain=!1),this._status.showSendForAnalysis&&(o.data.sendForAnalysis=this.get("sendForAnalysis")),n("app.av.detections.Set",o).catch((()=>n("app.rootkitDetection.Set",o))).then((()=>{n("app.av.detections.UserChoice",{id:this.get("params.id"),userChoice:t}).catch((()=>n("app.rootkitDetection.UserChoice",{id:this.get("params.id"),userChoice:t}))).then((()=>{this._actionTriggered=!0}))})).catch((t=>{Ts.error("doAction Failed, error:",t),a(t)}));const c=t=>{this._cancelListener1(),this._cancelListener2(),"resolved"===t.state&&"ignore"!==i?e(this.getDoneConfig(i,t.errorCode)):a()};this._cancelListener1=s.on("app.av.detections.onStatusChanged",c),this._cancelListener2=s.on("app.rootkitDetection.onStatusChanged",c)}))}})}(ks),Vs=function(e,s){return t.extend({template:e,components:{ThreatsList:s},css:"[slot='table-header'],\n.kin_table__row {\n grid-template-columns: 5% 30% 35% 30%;\n}\n.scn_sub-icon {\n position: absolute;\n top: 2.2rem;\n left: 2.5rem;\n}\n[dir='rtl'] .scn_sub-icon {\n right: 2.5rem;\n left: auto;\n}\n",twoway:!1,scannerId:void 0,data:()=>({stripHtml:f.stripHtml,scannerData:{progress:void 0,status:void 0,issuesCount:void 0},loading:!0,lastScanned:"",scanId:"{D93EF81A-B92F-27FE-AF54-9278EA8BF910}",showThreats:!1,allResolved:null,threatsCount:null,threatsCountTotal:null}),lastScannedBuffer:[],_intervalLastScanned:void 0,_intervalScanViruses:void 0,_lastScannedCounter:0,oninit(){a.view("SmartScan/Resolve/Scans"),this._startPollingForPath(),this.on("stop",(()=>{this.fire("stopScan")})),this.on("updateScannerData",(t=>{this.set("scannerData",{progress:t.progress,status:t.status,issuesCount:t.issuesCount}),"done"===t.status&&t.issuesCount>0&&(this._clearPollingForPath(),this.set("showThreats",!0))})),this.on("ThreatsList.threatsResolved",(()=>{this.fire("nextScanner")})),this.on("ThreatsList.threatsSkip",(()=>{this.fire("skipScanner",this.scannerId)})),this.on("ThreatsList.data",(t=>{this.set({loading:t.loading,threatsCount:t.threatsCount,threatsCountTotal:t.threatsCountTotal,allResolved:t.allResolved})})),this.observe("allResolved",(t=>{t&&this.fire("allIssuesResolved",this.scannerId)}),{init:!1})},_startPollingForPath(){this._intervalScanViruses=setInterval((()=>{n("app.scanViruses.GetStatus",{id:"{D93EF81A-B92F-27FE-AF54-9278EA8BF910}"}).then((t=>{if("done"===t.status)return clearInterval(this._intervalScanViruses),void this._clearIntervalLastScanned();this._pushLastScanned(t.lastScanned),this._startIntervalLastScanned()}))}),400)},_pushLastScanned(t){if(!t)return this._clearIntervalLastScanned(),this.lastScannedBuffer=[],void this.set("lastScanned","");t=this.normalizePath(t),this.lastScannedBuffer.indexOf(t)>-1?this._clearIntervalLastScanned():(6===this.lastScannedBuffer.length?this.lastScannedBuffer.shift():this.set("lastScanned",t),this.lastScannedBuffer.push(t))},_startIntervalLastScanned(){this._intervalLastScanned||6!==this.lastScannedBuffer.length||(this._intervalLastScanned=setInterval((()=>{this.set("lastScanned",this.lastScannedBuffer[this._lastScannedCounter++%6])}),400/6))},_clearIntervalLastScanned(){clearInterval(this._intervalLastScanned),this._intervalLastScanned=void 0},normalizePath:t=>"string"!=typeof t?"":t=(t=t.replace(/\\+/g,"\\")).replace(/([a-z]:)?(\\)/g,(function(t){return t.charAt(0).toUpperCase()+t.slice(1)})),_clearPollingForPath(){clearInterval(this._intervalScanViruses),this._clearIntervalLastScanned()},onteardown(){this._clearPollingForPath()}})}({v:3,t:[{t:4,f:[{t:7,e:"div",a:{class:"kin_scan__result"},f:[{t:7,e:"h1",a:{class:"h1 smr_progress__title","data-test":"ss_scanViruses_progress"},f:[{t:3,x:{r:["nls","scannerData.progress"],s:'_0("scans.ss2.progress.title",_1)'}}]}," ",{t:7,e:"p",a:{class:"kin_scan__subtitle"},f:[{t:7,e:"SmartTextTrim",a:{text:[{t:2,r:"lastScanned"}],ellipsisInMiddle:"true",width:"75%"}}]}]}," ",{t:7,e:"div",a:{class:"kin_scan__actions"},f:[{t:7,e:"button",a:{class:"btn -secondary -medium -submit","data-test":"ss_scanViruses_stop"},v:{click:"stop"},f:[{t:3,x:{r:["nls"],s:'_0("global.stopScan")'}}]}]}],n:50,x:{r:["scannerData.status"],s:'_0!=="done"'}},{t:4,n:51,f:[{t:4,n:50,x:{r:["scannerData.issuesCount"],s:"_0===0"},f:[{t:7,e:"div",a:{class:"kin_scan__result"},f:[{t:7,e:"h1",a:{class:"h1 kin_scan__title","data-test":"ss_scanViruses_titleEmpty"},f:[{t:3,x:{r:["nls"],s:'_0("scans.ss2.noIssues.title")'}}]}," ",{t:7,e:"p",a:{class:"kin_scan__subtitle"},f:[{t:3,x:{r:["nls"],s:'_0("scans.ss2.noIssues.subtitle")'}}]}]}," ",{t:7,e:"div",a:{class:"kin_scan__actions"},f:[{t:7,e:"button",a:{class:"btn -medium -submit","data-test":"ss_scanViruses_next"},v:{click:"nextScanner"},f:[{t:3,x:{r:["nls"],s:'_0("global.next")'}}]}]}]},{t:4,n:50,x:{r:["scannerData.issuesCount"],s:"!(_0===0)"},f:[" ",{t:7,e:"kin-view",a:{csscls:"-center",loading:[{t:2,r:"loading"}]},f:[{t:7,e:"div",a:{slot:"description"},f:[{t:4,f:[{t:7,e:"h1",a:{class:"h1 kin_scan__title"},f:[{t:7,e:"span",a:{class:"color-ok -text","data-test":"ss_scanViruses_titleResolved"},f:[{t:3,x:{r:["nls"],s:'_0("scans.ss2.allResolved.title")'}}]}]}," ",{t:7,e:"p",a:{class:"kin_scan__subtitle"},f:[{t:3,x:{r:["nls"],s:'_0("scans.ss2.allResolved.subtitle")'}}]}],n:50,r:"allResolved"},{t:4,n:51,f:[{t:7,e:"h1",a:{class:"h1 kin_scan__title","data-test":"ss_scanViruses_title"},f:[{t:3,x:{r:["nls","threatsCount"],s:'_0("scans.ss2.results.title",_1)'}}]}," ",{t:7,e:"p",a:{class:"kin_scan__subtitle"},f:[{t:3,x:{r:["nls"],s:'_0("scans.ss2.results.subtitle")'}}]}],r:"allResolved"}]}," ",{t:4,f:[{t:7,e:"ThreatsList",a:{scanId:[{t:2,r:"scanId"}],sessionId:[{t:2,r:"sessionId"}],showSkipOnSelected:"true",preselectAll:"true"}}],n:50,r:"showThreats"}]}]}],x:{r:["scannerData.status"],s:'_0!=="done"'}}]},Xt.ThreatsList);export default Us;export{Vs as SmartScanV2,js as antirootkitDetectionDialog,Ss as detection,Hs as idpDetectionDialog,Ds as scanProgressToaster,$ as serviceProxy,$s as settings,Bs as settingsGeek,Ns as settingsSearchStrings,re as utils};const Gs={name:"Scans",version:"1.2.578",created:"2021-03-09T09:14:59.577Z"};export{Gs as metadata};